personal_scripts

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README

commit 69b239273fd0469d3dd70139b0aa24aa13a99f9a
parent 145309c5ef7081079ed9161114b60140bb73ad91
Author: mrgrouse <bdmfegys@duck.com>
Date:   Tue, 12 Nov 2024 19:25:58 -0500

artix-install.sh: remove networkmanager dependency, fix broken directories, tell user what script is doing when run, and add some comments

Diffstat:
Martix-install.sh | 20+++++++++++++++-----
1 file changed, 15 insertions(+), 5 deletions(-)

diff --git a/artix-install.sh b/artix-install.sh @@ -1,5 +1,5 @@ #!/bin/sh -# FOR UEFI SYSTEMS ONLY # +###! FOR UEFI SYSTEMS ONLY !### #TODO: implement other mountpoints/partitions ### FUNCTIONS ### test_drive () { @@ -43,13 +43,18 @@ get_var "Which init system (options: dinit, s6, runit, openrc):" init ### FORMATTING DRIVES ### # clear drive +echo "Wiping $root_drive ..." wipe_drive urandom $root_drive && sync # encrypt drive +echo "Encrypting $root_drive ..." cryptsetup luksFormat $root_drive && sync # formatting boot drive +echo "Wiping $boot_drive ..." wipe_drive urandom $boot_drive # clear drive + +echo "Formatting and Labelling $boot_drive ..." mkfs.fat -F 32 $boot_drive && sync # format drive fatlabel $boot_drive ESP && sync # label drive @@ -69,26 +74,31 @@ mount $boot_drive $rtmnt/boot # mount unencrypted boot drive in /boot of install get_var "Which kernel would you like to install:" kernel # strap main system w packages -basestrap /mnt base base-devel $kernel $kernel-headers networkmanager-$init +basestrap /mnt base base-devel $kernel $kernel-headers iwd-$init # generate fstab fstabgen -U $rtmnt >> $rtmnt/etc/fstab -artix-chroot $rtmnt # FIX THIS PLEASE FIXME TODO BIG TIME # set timezome -ln -sf /usr/share/zoneinfo/$country/$timezone /etc/localtime +ln -sf $rtmnt/usr/share/zoneinfo/$country/$timezone $rtmnt/etc/localtime ### GRUB ### grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=Artix + # TODO: set up configuration of /etc/default/grub +# Mostly done :D root_basename=$(echo $root_drive | awk -F '/' '{print $2}') root_uuid=$(lsblk -f | grep root_basename) grubcmdline="GRUB_CMDLINE_LINUX=\"cryptdevice=UUID=$root_uuid:$cryptname rootfstype=ext4\"" -sed -i "1s/$grubcmdline^/GRUB_/" /etc/default/grub +sed -i "1s/$grubcmdline^/GRUB_/" $rtmnt/etc/default/grub # build config grub-mkconfig -o /boot/grub/grub.cfg +## FIXME ### +# Possible solution: `artix-chroot $rtmnt ./chroot_script.sh` +artix-chroot $rtmnt # FIX THIS PLEASE FIXME TODO BIG TIME + # build & compress initramfs initramfs_checker () { which $1 && initramfsgen=$1