From d526ed1d5669f95ed534fd1d779766f6fa022dc6 Mon Sep 17 00:00:00 2001 From: Cameron Ball Date: Fri, 27 Mar 2015 07:54:05 +0000 Subject: [PATCH] Make scripts and binary executable after updating --- README.md | 1 + update.sh | 2 ++ 2 files changed, 3 insertions(+) diff --git a/README.md b/README.md index c2cacb9..46701d5 100644 --- a/README.md +++ b/README.md @@ -24,5 +24,6 @@ In addition, it will update the software on the Pi. Unlike when config.ini and v If you want to run the script on boot, you should use start.sh. start.sh runs the usb-update script, and then starts playing video.mp4 on a loop. It uses omxplayer (make sure whatever version you use has the --loop option). I would suggest simply adding the following to /etc/init.d/rc.local: ``` +cd /home/pi/hdmi-switcher /home/pi/hdmi-switcher/start.sh ``` diff --git a/update.sh b/update.sh index ecd5fd2..1ade7ea 100755 --- a/update.sh +++ b/update.sh @@ -28,6 +28,8 @@ if [[ -e "/mnt/usb-update/update.zip" ]] && [[ -e "/mnt/usb-update/update.sig" ] openssl dgst -sha256 -verify public.pem -signature /mnt/usb-update/update.sig /mnt/usb-update/update.zip > /dev/null 2>&1 if [[ $? = 0 ]]; then (unzip -o /mnt/usb-update/update.zip -d /home/pi > /dev/null 2>&1 && printf "\tOK\n") || printf "\tExtract failure\n" + chmod +x start.sh + chmod +x update.sh else printf "\tSignature failure\n" fi -- 2.11.0