From c9081d6d91c6ebd4a21c944e019578481749c6ed Mon Sep 17 00:00:00 2001 From: David Beniamine <david.beniamine@tetras-libre.fr> Date: Fri, 6 Oct 2017 14:56:58 +0200 Subject: [PATCH] Fix timeout not shutting down the computer --- simple_backup.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simple_backup.sh b/simple_backup.sh index 7e2efc5..4c4c6a2 100755 --- a/simple_backup.sh +++ b/simple_backup.sh @@ -11,7 +11,7 @@ export DISPLAY=:0 zenity --timeout $TIMEOUT --question --title "Sauvegarde terminée." \ --text "Voulez vous procéder à l'extinction automatique de l'ordinateur ?" ans=$? -if [ $ans == 0 ] +if [ $ans != 1 ] then sudo shutdown -h now fi -- GitLab