mirror of
https://github.com/classy-giraffe/easy-arch.git
synced 2025-11-17 11:30:55 +00:00
Fixing + welcome screen.
This commit is contained in:
parent
91e57fe2c9
commit
9f0f140f04
1 changed files with 11 additions and 3 deletions
14
easy-arch.sh
14
easy-arch.sh
|
|
@ -110,7 +110,8 @@ print "Setting up the system clock."
|
|||
timedatectl set-ntp true &>/dev/null
|
||||
|
||||
# Selecting the target for the installation.
|
||||
PS3="Select the disk where Arch Linux is going to be installed: "
|
||||
print "Welcome to easy-arch, a script made in order to simplify the process of installing Arch Linux."
|
||||
PS3="Please select the disk where Arch Linux is going to be installed: "
|
||||
select ENTRY in $(lsblk -dpnoNAME|grep -P "/dev/sd|nvme|vd");
|
||||
do
|
||||
DISK=$ENTRY
|
||||
|
|
@ -308,15 +309,22 @@ arch-chroot /mnt /bin/bash -e <<EOF
|
|||
echo "Adding $username with root privilege."
|
||||
useradd -m "$username"
|
||||
usermod -aG wheel "$username"
|
||||
echo "Setting user password for $username."
|
||||
passwd $username
|
||||
echo "$username ALL=(ALL) ALL" >> /etc/sudoers.d/"$username"
|
||||
fi
|
||||
|
||||
EOF
|
||||
|
||||
# Setting root password.
|
||||
print "Setting root password."
|
||||
arch-chroot /mnt /bin/passwd
|
||||
if [ -n "$username" ]; then
|
||||
print "Setting user password for $username."
|
||||
arch-chroot /mnt /bin/passwd "$username"
|
||||
fi
|
||||
|
||||
# Boot backup hook.
|
||||
print "Configuring /boot backup when pacman transactions are made."
|
||||
mkdir /mnt/etc/pacman.d/hooks
|
||||
cat > /mnt/etc/pacman.d/hooks/50-bootbackup.hook <<EOF
|
||||
[Trigger]
|
||||
Operation = Upgrade
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue