Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #! /bin/bash
- BACKTITLE="Raspberry Jamboree 2014"
- TITLE="@Cymplecy's Wonderful Menu of Jamboree Goodies"
- whiptail --backtitle "$BACKTITLE" --title "$TITLE" --msgbox "On the next screen you will will a menu with oodles of good things to install on your Raspberry Pi. use the arrow and tab keys to move around the menu and highlight the various items or buttons then press the return key to select that item. You must hit OK to continue." 10 78
- status="0"
- while [ "$status" -eq 0 ]
- do
- choice=$(whiptail --cancel-button Exit --backtitle "$BACKTITLE" --title "$TITLE" --menu "Make a choice" 16 78 5 \
- "Application 1" "Description of Application 1" \
- "Application 2" "Description of Application 2" \
- "Application 3" "Description of Application 3" 3>&2 2>&1 1>&3)
- option=$(echo $choice | tr '[:upper:]' '[:lower:]' | sed 's/ //g')
- case "${option}" in
- application1)
- #fill in execution command for app 1
- ;;
- application2)
- #fill in execution details for app 2
- ;;
- application3)
- #fill in execution details for app 3 and wash,rinse, repeat
- ;;
- *)
- printf "Byeeeeeeeeeeeee!!!\n"
- status=1
- exit
- ;;
- esac
- done
- ~
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement