Attempt to fix #33

Trying to create an encrypted install, from an encrypted Manjaro ARM install, will mess up some stuff as mentioned in issue #33.

Put in a check to see if the host system has /dev/mapper/ROOT_MNJRO and abort installation if encryption is chosen in the installer.

Signed-off-by: Dan Johansen <strit@manjaro.org>
This commit is contained in:
Dan Johansen 2021-05-07 15:42:22 +02:00
parent b8233d03ba
commit 810cee1f9e
No known key found for this signature in database
GPG Key ID: 084A7FC0035B1D49
1 changed files with 7 additions and 1 deletions

View File

@ -1,7 +1,7 @@
#! /bin/bash
# *****************************
# Version 1.4.0
# Version 1.4.1
# *****************************
# Set globals
@ -621,6 +621,11 @@ if [[ "$DEVICE" = "pbpro" ]] && [[ "$FSTYPE" != "btrfs" ]]; then
3>&1 1>&2 2>&3 3>&-)
fi
if [[ -d /dev/mapper/ROOT_MNJRO ]] && [[ "$CRYPT" = "yes" ]]; then
clear
exit 2
fi
if [ ! -z "$FSTYPE" ]; then
let i=0
W=()
@ -726,6 +731,7 @@ response=$?
case $response in
0) clear; msg "Proceeding....";;
1) clear; msg "Installation aborted...."; exit 1;;
2) clear; msg "Installation not possible from an encrypted system..."; exit 1;;
255) clear; msg "Installation aborted..."; exit 1;;
esac