From 8173e91a84802fed6f6f167ba1c2d50f75f6db4d Mon Sep 17 00:00:00 2001 From: Your Name Date: Sat, 17 Feb 2024 16:20:27 -0700 Subject: [PATCH] d --- gentoo-kde.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/gentoo-kde.sh b/gentoo-kde.sh index 510c888..49ade1c 100644 --- a/gentoo-kde.sh +++ b/gentoo-kde.sh @@ -32,6 +32,7 @@ mkdir $TARGET ###################################### echo HARD_DISK=$2 +SWAP="" ###################################### USER="verita84" USER_PASSWORD="123456" @@ -67,6 +68,7 @@ partitionDetection() { #This is used for the installer to do script-based actions EFI=$(blkid | grep $HARD_DISK | sort | cut -d ":" -f1 | head -1 | tail -1) BTRFS=$(blkid | grep $HARD_DISK | sort | cut -d ":" -f1 | head -2 | tail -1) + SWAP=$(blkid | grep $HARD_DISK | sort | cut -d ":" -f1 | head -3 | tail -1) } partitionDetection create-os-snapshots() { @@ -396,6 +398,7 @@ locale() { fstab() { mkdir $TARGET/etc echo "UUID=$(/sbin/blkid -s UUID -o value ${EFI}) /efi vfat umask=0077 0 1" >>$TARGET/etc/fstab + echo "UUID=$(/sbin/blkid -s UUID -o value ${SWAP}) none swap 0 1" >>$TARGET/etc/fstab echo "$BTRFS / btrfs noatime,nodiratime,autodefrag,$COMPRESSION,subvol=@$ROOT_NAME 0 1" >>$TARGET/etc/fstab echo "$BTRFS /.snapshots btrfs noatime,nodiratime,autodefrag,$COMPRESSION,subvol=@.snapshots 0 1" >>$TARGET/etc/fstab echo "$BTRFS /var/lib/libvirt btrfs noatime,nodiratime,autodefrag,$COMPRESSION,subvol=@libvirt 0 1" >>$TARGET/etc/fstab @@ -441,8 +444,12 @@ initialize-disk() { sleep 10 partitionDetection echo - echo "Formatting....." + echo "Formatting Root....." echo y | mkfs.btrfs $BTRFS --force + + echo "Formatting Swap" + mkswap -f $SWAP + echo "Formatting $EFI" echo echo y | mkfs.vfat $EFI