diff --git a/config/accounts/menu b/config/accounts/menu new file mode 100644 index 0000000..47d1fbd --- /dev/null +++ b/config/accounts/menu @@ -0,0 +1,22 @@ +#!/bin/bash +. ./lib + +options=() +options+=("Users" "") +options+=("Sudoers" "") + +defaultitem="" +sel=$(whiptail --backtitle "$apptitle" --title "Accounts Menu :" --menu "" --default-item "$defaultitem" --cancel-button "Back" 0 0 0 \ + "${options[@]}" \ + 3>&1 1>&2 2>&3) +if [ ! "$?" = "0" ]; then + exit 1 +fi +sed -i "/^defaultitem=/c\defaultitem=\"$sel\"" $0 + +case $sel in + 'Users') menu config/accounts/users/menu;; + 'Sudoers') menu config/accounts/sudoers/menu;; +esac + +exit 0 diff --git a/config/sudoers/menu b/config/accounts/sudoers/menu similarity index 100% rename from config/sudoers/menu rename to config/accounts/sudoers/menu diff --git a/config/users/menu b/config/accounts/users/menu similarity index 100% rename from config/users/menu rename to config/accounts/users/menu diff --git a/config/menu b/config/menu index 96415bb..1f7b7f2 100644 --- a/config/menu +++ b/config/menu @@ -4,8 +4,7 @@ options=() options+=("Bash" "") options+=("Firewall" "") -options+=("Users" "") -options+=("Sudoers" "") +options+=("Accounts" "") options+=("Systemd" "") if [ -f /usr/bin/Xorg ]; then options+=("XOrg" "") @@ -24,8 +23,7 @@ sed -i "/^defaultitem=/c\defaultitem=\"$sel\"" $0 case $sel in 'Bash') menu config/bash/menu;; 'Firewall') menu config/firewall/menu;; - 'Users') menu config/users/menu;; - 'Sudoers') menu config/sudoers/menu;; + 'Accounts') menu config/accounts/menu;; 'Systemd') menu config/systemd/menu;; 'XOrg') menu config/xorg/menu;; 'Boot') menu config/boot/menu;;