mirror of
https://github.com/rustdesk/rustdesk.git
synced 2025-05-11 18:36:11 +02:00
fix(debian): makes postinst/prerm scripts idempotent (#10541)
* fix(debian): makes `postinst` script idempotent * fix(debian): makes `prerm` script idempotent
This commit is contained in:
parent
dd004f1a2d
commit
4b066b1fba
2 changed files with 2 additions and 2 deletions
|
@ -5,7 +5,7 @@ set -e
|
||||||
if [ "$1" = configure ]; then
|
if [ "$1" = configure ]; then
|
||||||
|
|
||||||
INITSYS=$(ls -al /proc/1/exe | awk -F' ' '{print $NF}' | awk -F'/' '{print $NF}')
|
INITSYS=$(ls -al /proc/1/exe | awk -F' ' '{print $NF}' | awk -F'/' '{print $NF}')
|
||||||
ln -s /usr/share/rustdesk/rustdesk /usr/bin/rustdesk
|
ln -f -s /usr/share/rustdesk/rustdesk /usr/bin/rustdesk
|
||||||
|
|
||||||
if [ "systemd" == "$INITSYS" ]; then
|
if [ "systemd" == "$INITSYS" ]; then
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@ set -e
|
||||||
case $1 in
|
case $1 in
|
||||||
remove|upgrade)
|
remove|upgrade)
|
||||||
INITSYS=$(ls -al /proc/1/exe | awk -F' ' '{print $NF}' | awk -F'/' '{print $NF}')
|
INITSYS=$(ls -al /proc/1/exe | awk -F' ' '{print $NF}' | awk -F'/' '{print $NF}')
|
||||||
rm /usr/bin/rustdesk
|
rm -f /usr/bin/rustdesk
|
||||||
|
|
||||||
if [ "systemd" == "${INITSYS}" ]; then
|
if [ "systemd" == "${INITSYS}" ]; then
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue