From 79c0a64143b9e6ab5a793acc9abfd7867e1318ed Mon Sep 17 00:00:00 2001 From: Kaj Forney Date: Fri, 7 Sep 2018 15:28:03 -0600 Subject: [PATCH] Automatically detect distro. Former-commit-id: 90665d0e30bd0feba3e6c239bfc556c11291e135 --- runme.sh | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/runme.sh b/runme.sh index 41bd564d..ff81db3a 100755 --- a/runme.sh +++ b/runme.sh @@ -13,9 +13,7 @@ fi whiptail --backtitle "Pentest Build Script" --title "Welcome" --msgbox "This script will help you build a custom pentesting distribution." 7 70 -DISTRO=$(whiptail --backtitle "Pentest Build Script" --title "Distribution" --menu "Choose a distribution:" 10 40 2 \ -"KALI" "Kali Linux" \ -"PARROT" "Parrot Security OS" 3>&1 1>&2 2>&3) +DISTRO=$(lsb_release -i -s) DESKTOP=$(whiptail --backtitle "Pentest Build Script" --title "Desktop Environment" --menu "Choose a desktop environment:" 10 40 4 \ "gnome" "GNOME" \ @@ -41,7 +39,7 @@ mkdir build apt install git build-essential cdebootstrap live-build curl wget case $DISTRO in -KALI) +Kali) cp -rv ./modules/live-build-config ./build/ mkdir ./build/live-build-config/kali-config/variant-$DESKTOP/packages.chroot cp ./debs/*.deb build/live-build-config/kali-config/variant-$DESKTOP/packages.chroot/ @@ -55,7 +53,7 @@ KALI) whiptail --backtitle "Pentest Build Script" --title "Finished" --msgbox "Fingers crossed there were no errors... Your image should be done!" 7 70 exit 0 ;; -PARROT) +Parrot) cp -rv ./modules/parrot-build ./build/ mkdir ./build/parrot-build/templates/parrot-variant-$DESKTOP/packages.chroot cp ./debs/*.deb build/parrot-build/templates/parrot-variant-$DESKTOP/packages.chroot/