diff --git a/easy-arch.sh b/easy-arch.sh index 042756e..7a8e457 100755 --- a/easy-arch.sh +++ b/easy-arch.sh @@ -262,13 +262,14 @@ done # Mounting the newly created subvolumes. umount /mnt print "Mounting the newly created subvolumes." -mount -o ssd,noatime,compress-force=zstd:3,discard=async,subvol=@ $BTRFS /mnt +mountopts="ssd,noatime,compress-force=zstd:3,discard=async" +mount -o $mountopts,subvol=@ $BTRFS /mnt mkdir -p /mnt/{home,root,srv,.snapshots,var/{log,cache/pacman/pkg},boot} for subvol in ${subvols[@]:2}; do # ":2" excludes first two subvols (@snapshots and @var_pkgs) from loop -mount -o ssd,noatime,compress-force=zstd:3,discard=async,subvol=@$subvol $BTRFS /mnt/$(sed 's,_,/,g' <<< $subvol) +mount -o $mountopts,subvol=@$subvol $BTRFS /mnt/$(sed 's,_,/,g' <<< $subvol) done -mount -o ssd,noatime,compress-force=zstd:3,discard=async,subvol=@snapshots $BTRFS /mnt/.snapshots -mount -o ssd,noatime,compress-force=zstd:3,discard=async,subvol=@var_pkgs $BTRFS /mnt/var/cache/pacman/pkg +mount -o $mountopts,subvol=@snapshots $BTRFS /mnt/.snapshots +mount -o $mountopts,subvol=@var_pkgs $BTRFS /mnt/var/cache/pacman/pkg chattr +C /mnt/var/log mount $ESP /mnt/boot/