fix: track whether partitioning is disallowed
This commit is contained in:
parent
1dbb0b29d6
commit
4949293ac1
|
@ -27,6 +27,8 @@ USED_ZFS=false
|
|||
USED_BTRFS=false
|
||||
# Flag to track usage of encryption
|
||||
USED_ENCRYPTION=false
|
||||
# Flag to track whether partitioning or formatting is forbidden
|
||||
NO_PARTITIONING_OR_FORMATTING=false
|
||||
|
||||
# An array of disk related actions to perform
|
||||
DISK_ACTIONS=()
|
||||
|
@ -355,6 +357,8 @@ function create_single_disk_layout() {
|
|||
# boot=<device> Use the given device as the bios/efi partition.
|
||||
# type=[efi|bios] Selects the boot type. Defaults to efi if not given.
|
||||
function create_existing_partitions_layout() {
|
||||
NO_PARTITIONING_OR_FORMATTING=true
|
||||
|
||||
local known_arguments=('+swap' '+boot' '?type')
|
||||
local extra_arguments=()
|
||||
declare -A arguments; parse_arguments "$@"
|
||||
|
|
|
@ -707,7 +707,7 @@ function summarize_disk_actions() {
|
|||
function apply_disk_configuration() {
|
||||
summarize_disk_actions
|
||||
|
||||
if [[ ]]; then
|
||||
if [[ $NO_PARTITIONING_OR_FORMATTING == true ]]; then
|
||||
elog "You have chosen an existing disk configuration. No devices will"
|
||||
elog "actually be re-partitioned or formatted. Please make sure that all"
|
||||
elog "devices are already formatted."
|
||||
|
|
Loading…
Reference in New Issue