From a854c3c47977f254dadc392b4edf1f28b6032ae2 Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sun, 20 Feb 2022 21:00:44 -0600 Subject: [PATCH] Add -p to mkdir commands --- scripts/0-preinstall.sh | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/scripts/0-preinstall.sh b/scripts/0-preinstall.sh index 39471a9..6633878 100755 --- a/scripts/0-preinstall.sh +++ b/scripts/0-preinstall.sh @@ -127,8 +127,7 @@ elif [[ "${FS}" == "luks" ]]; then fi # mount target -mkdir /mnt/boot -mkdir /mnt/boot/efi +mkdir -p /mnt/boot/efi mount -t vfat -L EFIBOOT /mnt/boot/ if ! grep -qs '/mnt' /proc/mounts; then @@ -169,7 +168,7 @@ echo -ne " TOTAL_MEM=$(cat /proc/meminfo | grep -i 'memtotal' | grep -o '[[:digit:]]*') if [[ $TOTAL_MEM -lt 8000000 ]]; then # Put swap into the actual system, not into RAM disk, otherwise there is no point in it, it'll cache RAM into RAM. So, /mnt/ everything. - mkdir /mnt/opt/swap # make a dir that we can apply NOCOW to to make it btrfs-friendly. + mkdir -p /mnt/opt/swap # make a dir that we can apply NOCOW to to make it btrfs-friendly. chattr +C /mnt/opt/swap # apply NOCOW, btrfs needs that. dd if=/dev/zero of=/mnt/opt/swap/swapfile bs=1M count=2048 status=progress chmod 600 /mnt/opt/swap/swapfile # set permissions.