CLI options functional.

Former-commit-id: d855f8a752
Former-commit-id: 5651fe34d260b125ca58f2683648ea62a9a9e453
This commit is contained in:
Kaj Forney 2018-09-29 16:42:16 -06:00
parent 6b31cbf0cc
commit 9ede0f6f13

View file

@ -11,23 +11,24 @@ then
exit 1
fi
#Argument check!
#Arguments
while getopts ud:r: option
do
case "${option}" in
u) UNATTEND=true;;
d) DESKTOP=${OPTARG};;
r) REPO=${OPTARG};;
u) UNATTEND="true" && echo "UNATTEND";;
d) DESKTOP=${OPTARG} && echo $DESKTOP;;
r) REPO=${OPTARG} && echo $REPO;;
esac
done
DISTRO=$(lsb_release -i -s)
if [ $UNATTEND != "true" ];
then
whiptail --backtitle "Pentest Build Script" --title "Welcome" --msgbox "This script will help you build a custom pentesting distribution." 7 70
DISTRO=$(lsb_release -i -s)
DESKTOP=$(whiptail --backtitle "Pentest Build Script" --title "Desktop Environment" --menu "Choose a desktop:" 15 50 6 \
"gnome" "GNOME Desktop Environment" \
"mate" "MATE Advanced Traditional Environment" \