diff --git a/archinstall.sh b/archinstall.sh index 43b70d3..9fa30df 100755 --- a/archinstall.sh +++ b/archinstall.sh @@ -19,6 +19,11 @@ MACADDRS=( 1c:69:7a:63:ad:46 ) +DISK="/dev/vda" +USER="CLC" +PASSWD="$1$8nWcCPFE$SMC36PPfImzmQ9E3WEPvy1" +ROOTPASSWD="$1$8g0M2I8t$GNnx5EkVhu1Ykw7NuKZos." + #Echo text with a color passed as the second arguement echoc () { echo -e "$2$1${ENDCOLOR}" #Color, Text, Reset color @@ -58,7 +63,7 @@ prechecks () { } partition () { - DISK="/dev/vda" + echo " - Formatting disk..." @@ -84,6 +89,15 @@ sysinstall () { pacstrap /mnt arch-chroot /mnt bootctl install + + genfstab -t PARTUUID /mnt >> /mnt/etc/fstab + echo "HOSTNAME" > /mnt/etc/HOSTNAME + + arch-chroot /mnt useradd -mU -s /usr/bin/zsh -G wheel,uucp,video,audio,storage,games,input $USER + arch-chroot /mnt chsh -s /usr/bin/zsh + + echo "$USER:$PASSWD" | chpasswd -e --root /mnt + echo "root:$ROOTPASSWD" | chpasswd -e --root /mnt } ###################################################################################### @@ -100,6 +114,7 @@ prechecks if [ $? -eq 1 ]; then echo "Prechecks passed!" partition + sysinstall else echoc "Prechecks failed!" $RED fi \ No newline at end of file