aboutsummaryrefslogtreecommitdiffstats
path: root/arch-installer.sh
diff options
context:
space:
mode:
authorRudy Bousset <rbousset@z2r5p6.le-101.fr>2019-11-29 19:27:02 +0100
committerRudy Bousset <rbousset@z2r5p6.le-101.fr>2019-11-29 19:27:02 +0100
commitb4d45e8eac97ad73ea0a678f5baecc4d0be297e9 (patch)
treec7f8532bc75d629ad2d285d642414e2da1d2d550 /arch-installer.sh
parentBetter indent (diff)
downloadarch-installer-b4d45e8eac97ad73ea0a678f5baecc4d0be297e9.tar.gz
arch-installer-b4d45e8eac97ad73ea0a678f5baecc4d0be297e9.tar.bz2
arch-installer-b4d45e8eac97ad73ea0a678f5baecc4d0be297e9.tar.xz
arch-installer-b4d45e8eac97ad73ea0a678f5baecc4d0be297e9.tar.zst
arch-installer-b4d45e8eac97ad73ea0a678f5baecc4d0be297e9.zip
Re test
Diffstat (limited to 'arch-installer.sh')
-rwxr-xr-xarch-installer.sh17
1 files changed, 16 insertions, 1 deletions
diff --git a/arch-installer.sh b/arch-installer.sh
index ab47112..d688376 100755
--- a/arch-installer.sh
+++ b/arch-installer.sh
@@ -536,10 +536,25 @@ $rtpwd
$rtpwd
systemctl enable NetworkManager
sed -i 's/#ForwardToSyslog=no/ForwardToSyslog=yes/' /etc/systemd/journald.conf
-if [ "$isusr" = true ]; then if [ "$isusrsudo" = true ]; then useradd -m -g wheel -s /bin/$usrshell $usr; sed -i 's/# %wheel ALL=(ALL) ALL/%wheel ALL=(ALL) ALL/' /etc/sudoers; else useradd -m -s /bin/$usrshell $usr; fi; passwd $usr
+ARCH_CHROOT_CMDS
+if [ "$isusr" = true ]; then
+ if [ "$isusrsudo" = true ]; then
+ arch-chroot /mnt/arch << ARCH_CHROOT_CMDS
+useradd -m -g wheel -s /bin/$usrshell $usr
+sed -i 's/# %wheel ALL=(ALL) ALL/%wheel ALL=(ALL) ALL/' /etc/sudoers
+ARCH_CHROOT_CMDS
+ else
+ arch-chroot /mnt/arch << ARCH_CHROOT_CMDS
+ useradd -m -s /bin/$usrshell $usr
+ARCH_CHROOT_CMDS
+ fi
+ arch-chroot /mnt/arch << ARCH_CHROOT_CMDS
+ passwd $usr
$usrpwd
$usrpwd
+ARCH_CHROOT_CMDS
fi
+arch-chroot /mnt/arch << ARCH_CHROOT_CMDS
if [ "$ltskern" = false ]; then mkinitcpio -p linux; else mkinitcpio -p linux-lts; fi
if [ "$efimode" = true ]; then; grub-install --target=x86_64-efi --bootloader-id=GRUB --efi-directory=/boot/efi --recheck; mkdir -p /boot/grub; grub-mkconfig -o /boot/grub/grub.cfg; mkdir -p /boot/efi/EFI/BOOT; cp /boot/efi/EFI/GRUB/grubx64.efi /boot/efi/EFI/BOOT/BOOTX64.EFI; echo "bcf boot add 1 fs0:\\EFI\\GRUB\\grubx64.efi \"GRUB bootloader\"" > /boot/efi/startup.nsh; echo "exit" >> /boot/efi/startup.nsh; else grub-install --target=i386-pc $drv; grub-mkconfig -o /boot/grub/grub.cfg
ARCH_CHROOT_CMDS