Browse Source

Don't prompt to create a user in the middle of the install

master
jcmdln 2 years ago
parent
commit
cd2533346a
1 changed files with 14 additions and 8 deletions
  1. 14
    8
      install.sh

+ 14
- 8
install.sh View File

@@ -277,14 +277,6 @@ MINIMAL() {
echo "gein: Setting root password..."
[ -x $(command -v chpasswd) ] && \
echo root:$Hostname | chpasswd

read -ep "gein: Setup a standard user? [Y/N]: " SetupUser
if echo $SetupUser | grep -iq "^y"; then
read -ep "Username: " Username
read -ep "Password: " Password
useradd -m -G wheel,audio,video -s /bin/bash $Username
echo $Username:$Password | chpasswd
fi
}


@@ -340,6 +332,18 @@ DESKTOP() {
done
}

# This section is for completing tasks after the installation is
# complete. The user will have a complete system already installed and
# may skip these steps if desired.
POSTINSTALL() {
read -ep "gein: Setup a standard user? [Y/N]: " SetupUser
if echo $SetupUser | grep -iq "^y"; then
read -ep "Username: " Username
read -ep "Password: " Password
useradd -m -G wheel,audio,video -s /bin/bash $Username
echo $Username:$Password | chpasswd
fi
}

# This is the CLI that controls what will be run. Keep in mind that the
# BOOTSTRAP() needs to be run to completion before running the MINIMAL()
@@ -353,11 +357,13 @@ case $1 in

-m|minimal)
MINIMAL
POSTINSTALL
;;

-d|desktop)
MINIMAL
DESKTOP
POSTINSTALL
;;

*)

Loading…
Cancel
Save