start.sh hinzugefügt
This commit is contained in:
1 parent
4c9980bbee
commit
f8d0dc43c5
1 file changed
+32
@@ -0,0 +1,32 @@
|
||||
#!/usr/bin/env bash
|
||||
# Startscript für den Roboter
|
||||
# + Updatefunktion
|
||||
|
||||
#GITDIR=~/git/robotSoSe2022
|
||||
GITDIR=~/git/robotik-wise23
|
||||
|
||||
Choice=$( whiptail --title "Hausaufgabenrobo Start und Update" --radiolist \
|
||||
"Bitte wählen" 20 78 4 \
|
||||
"START" "Hausaufgabenrobo starten" ON \
|
||||
"UPDATE" "Roboter Software aktualisieren" OFF 3>&1 1>&2 2>&3 )
|
||||
ExitVAL=$?
|
||||
if [ $ExitVAL = 0 ] ;then # OK
|
||||
case $Choice in
|
||||
"START")
|
||||
echo starte nun robot
|
||||
cd $GITDIR
|
||||
./robostart.sh
|
||||
;;
|
||||
"UPDATE")
|
||||
cd $GITDIR
|
||||
git pull
|
||||
;;
|
||||
else)
|
||||
echo "hier war was komisch"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
else # abbrechen gedrückt
|
||||
exit 1
|
||||
|
||||
fi
|
||||
Reference in new issue
Block a user