123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114 |
- #!/bin/bash
- # fail if any commands fails
- set -e
- # debug log
- #set -x
- # Set superuser privileges command if not set
- if [[ -z $su ]]; then
- export su="sudo"
- fi
- options=(Y y N n)
- # Section: games
- read -rp "install games?: (y|n)" option
- while [[ " "${options[@]}" " != *" $option "* ]]; do
- echo "$option: not recognized. Valid options are:"
- echo "${options[@]/%/,}"
- read -rp "?: (y|N)" option
- done
- if [[ "$option" == "y" || "$option" == "Y" ]]; then
- ./install_repo_games.sh
- fi
- # Section: angband
- read -rp "install angband?: (y|n)" option
- while [[ " "${options[@]}" " != *" $option "* ]]; do
- echo "$option: not recognized. Valid options are:"
- echo "${options[@]/%/,}"
- read -rp "?: (y|N)" option
- done
- if [[ "$option" == "y" || "$option" == "Y" ]]; then
- ./install_angband.sh
- fi
- # Section: frogcomposband
- read -rp "install frogcomposband?: (y|n)" option
- while [[ " "${options[@]}" " != *" $option "* ]]; do
- echo "$option: not recognized. Valid options are:"
- echo "${options[@]/%/,}"
- read -rp "?: (y|N)" option
- done
- if [[ "$option" == "y" || "$option" == "Y" ]]; then
- ./install_frogcomposband.sh
- fi
- # Section: quakeinjector
- read -rp "install quakeinjector?: (y|n)" option
- while [[ " "${options[@]}" " != *" $option "* ]]; do
- echo "$option: not recognized. Valid options are:"
- echo "${options[@]/%/,}"
- read -rp "?: (y|N)" option
- done
- if [[ "$option" == "y" || "$option" == "Y" ]]; then
- ./install_quakeinjector.sh
- fi
- # Section: prboom-plus
- read -rp "install prboom-plus?: (y|n)" option
- while [[ " "${options[@]}" " != *" $option "* ]]; do
- echo "$option: not recognized. Valid options are:"
- echo "${options[@]/%/,}"
- read -rp "?: (y|N)" option
- done
- if [[ "$option" == "y" || "$option" == "Y" ]]; then
- ./install_prboom-plus.sh
- fi
- # Section: gzdoom
- read -rp "install gzdoom?: (y|n)" option
- while [[ " "${options[@]}" " != *" $option "* ]]; do
- echo "$option: not recognized. Valid options are:"
- echo "${options[@]/%/,}"
- read -rp "?: (y|N)" option
- done
- if [[ "$option" == "y" || "$option" == "Y" ]]; then
- ./install_gzdoom.sh
- fi
- # Section: build engine games
- read -rp "install build engine games?: (y|n)" option
- while [[ " "${options[@]}" " != *" $option "* ]]; do
- echo "$option: not recognized. Valid options are:"
- echo "${options[@]/%/,}"
- read -rp "?: (y|N)" option
- done
- if [[ "$option" == "y" || "$option" == "Y" ]]; then
- ./install_eduke32.sh
- ./install_nblood.sh
- fi
- # Section: alephone
- read -rp "install alephone?: (y|n)" option
- while [[ " "${options[@]}" " != *" $option "* ]]; do
- echo "$option: not recognized. Valid options are:"
- echo "${options[@]/%/,}"
- read -rp "?: (y|N)" option
- done
- if [[ "$option" == "y" || "$option" == "Y" ]]; then
- ./install_alephone.sh
- fi
- # Section: Add user to games group
- read -rp "Add user to games group?: (Y|n)" option
- while [[ " "${options[@]}" " != *" $option "* ]]; do
- echo "$option: not recognized. Valid options are:"
- echo "${options[@]/%/,}"
- read -rp "?: (y|N)" option
- done
- if [[ "$option" == "y" || "$option" == "Y" ]]; then
- ./add_user_to_games_group.sh
- fi
|