Added a abort message
This commit is contained in:
parent
dd66aeda9a
commit
775a26f738
|
|
@ -90,10 +90,11 @@ def ask_to_configure_network():
|
|||
def ask_for_disk_layout():
|
||||
options = {
|
||||
'keep-existing' : 'Keep existing partition layout and select which ones to use where.',
|
||||
'format-all' : 'Format entire drive and setup a basic partition scheme.'
|
||||
'format-all' : 'Format entire drive and setup a basic partition scheme.',
|
||||
'abort' : 'abort'
|
||||
}
|
||||
|
||||
return generic_select(options.values(), "Found partitions on the selected drive, (select by number) what do you want to do: ")
|
||||
return generic_select(options.values(), "Found partitions on the selected drive, (select by number) what you want to do: ")
|
||||
|
||||
def generic_select(options, input_text="Select one of the above by index or absolute value: ", sort=True):
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -114,7 +114,10 @@ if archinstall.arguments['harddrive'].has_partitions():
|
|||
archinstall.log(f" {partition} (Filesystem not supported)", fg='red')
|
||||
|
||||
# We then ask what to do with the paritions.
|
||||
if (option := archinstall.ask_for_disk_layout()) == 'keep-existing':
|
||||
if (option := archinstall.ask_for_disk_layout()) == 'abort':
|
||||
archinstall.log(f"Safely aborting the installation. No changes to the disk or system has been made.")
|
||||
exit(1)
|
||||
elif option == 'keep-existing':
|
||||
archinstall.arguments['harddrive'].keep_partitions = True
|
||||
|
||||
archinstall.log(f" ** You will now select which partitions to use by selecting mount points (inside the installation). **")
|
||||
|
|
|
|||
Loading…
Reference in New Issue