diff --git a/debian.sh b/debian.sh index c5f1fe1..821a8d4 100755 --- a/debian.sh +++ b/debian.sh @@ -208,7 +208,6 @@ make-image() { locale custom_service_files cp -f debian.sh $TARGET/usr/bin/ - cp -f debian.tar $TARGET/etc/default/ echo 'bash /usr/bin/debian.sh kernel-packages' >>$TARGET/setup.sh echo "bash /usr/bin/debian.sh bootloader $1 $ROOT_NAME $ROOT_MAPPER_NAME" >>$TARGET/setup.sh echo 'bash /usr/bin/debian.sh grub-snapshots' >>$TARGET/setup.sh @@ -239,7 +238,6 @@ install() { cp -f /etc/resolv.conf $TARGET/etc/ echo "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" >$TARGET/setup.sh configure-repository - cp -f debian.tar $TARGET/etc/default/ locale auto_login custom_service_files @@ -294,22 +292,6 @@ kernel-packages() { /usr/bin/apt install --reinstall -y linux-image-amd64 grub-efi efibootmgr plymouth plymouth-themes btrfs-progs cryptsetup-initramfs linux-image-amd64 linux-headers-amd64 firmware-iwlwifi firmware-linux firmware-linux-nonfree } -secure-boot() { - if [ -z "$1" ]; then - clear - echo - echo "Error: No Disk specified!" - echo - else - clear - echo - echo "Disabling Automatic Password Decryption for Hard Disk....." - echo - AUTO_DECRYPT='False' - bootloader "$1" "$ROOT_NAME" "$ROOT_MAPPER_NAME" - fi -} - bootloader() { if [ -z "$1" ]; then echo @@ -318,10 +300,7 @@ bootloader() { else ROOT_MAPPER_NAME="$3" ROOT_NAME="$2" - rm -rf /boot/grub/themes - mkdir -p /boot/grub/themes - tar xf /etc/default/debian.tar -C /boot/grub/themes/ - plymouth-set-default-theme -R spacefun + plymouth-set-default-theme -r echo "$ROOT_MAPPER_NAME UUID=$(/sbin/blkid | grep $BTRFS | cut -d '"' -f2) none luks" >/etc/crypttab if [ "$AUTO_DECRYPT" == "True" ]; then decryptBoot "${BTRFS}" @@ -582,9 +561,11 @@ menu() { set-devices read -p 'Unlock Disk without password at boot time? ' -e -i "y" root_name if [[ $pass_change = *n* ]]; then + AUTO_DECRYPT="False" bootloader "$HARD_DISK" "$ROOT_NAME" "$ROOT_MAPPER_NAME" else - secure-boot "$HARD_DISK" + AUTO_DECRYPT="True" + bootloader "$HARD_DISK" "$ROOT_NAME" "$ROOT_MAPPER_NAME" fi elif [[ $choice = 6 ]]; then clear