OSDN Git Service

zenity check
authorpaperbenni <paperbenni@gmail.com>
Mon, 22 Jun 2020 21:13:38 +0000 (23:13 +0200)
committerpaperbenni <paperbenni@gmail.com>
Mon, 22 Jun 2020 21:13:38 +0000 (23:13 +0200)
archinstall.sh

index 304e500..aea61e5 100755 (executable)
@@ -80,7 +80,9 @@ sleep 2
 
 # ask to reboot, upload error data if install failed
 if ! [ -e /opt/installfailed ] || ! [ -e /opt/installsuccess ]; then
-    zenity --question --text="installation finished. reboot?" && touch /tmp/instantosreboot
+    if command -v zenity; then
+        zenity --question --text="installation finished. reboot?" && touch /tmp/instantosreboot
+    fi
 else
     echo "installaion failed"
     echo "uploading error data"