Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/archinstall
diff options
context:
space:
mode:
authorSecondThundeR <awayfromgalaxy@gmail.com>2021-04-29 01:30:35 +0300
committerSecondThundeR <awayfromgalaxy@gmail.com>2021-04-29 19:49:08 +0300
commit5f1156f80e4038a52719f4ba01c87eae4f0a8660 (patch)
tree03bd9b23eee81f2a57556de9dfc302939bb8f746 /archinstall
parent5c8748dbb5f663f579b6a462d317162de163fa84 (diff)
Fix multi select and video card driver selection
Changes: - Rephrased input text for kernel selection - Fixed crash with empty video card driver selection - Removed log info for default option
Diffstat (limited to 'archinstall')
-rw-r--r--archinstall/lib/user_interaction.py11
1 files changed, 5 insertions, 6 deletions
diff --git a/archinstall/lib/user_interaction.py b/archinstall/lib/user_interaction.py
index 437ca68f..10d74b63 100644
--- a/archinstall/lib/user_interaction.py
+++ b/archinstall/lib/user_interaction.py
@@ -118,10 +118,10 @@ def generic_multi_select(options, text="Select one or more of the options above
selected_options = []
- while True:
- if not selected_options and default in options:
- selected_options.append(default)
+ if not selected_options and default in options:
+ selected_options.append(default)
+ while True:
printed_options = []
for option in options:
if option in selected_options:
@@ -148,7 +148,6 @@ def generic_multi_select(options, text="Select one or more of the options above
# Since it still breaks the loop
if not selected_options and default:
selected_options = [default]
- log(f'Default option selected: "{default}"', fg='yellow')
break
elif selected_options or allow_empty:
break
@@ -687,7 +686,7 @@ def select_driver(options=AVAILABLE_GFX_DRIVERS):
elif b'amd' in line.lower():
print(' ** AMD card detected, suggested driver: AMD / ATI **')
- initial_option = generic_select(drivers, input_text="Select your graphics card driver: ")
+ initial_option = generic_select(drivers, input_text="Select your graphics card driver: ", allow_empty_input=False)
selected_driver = options[initial_option]
if type(selected_driver) == dict:
@@ -719,6 +718,6 @@ def select_kernel(options):
kernels = sorted(list(options))
if kernels:
- return generic_multi_select(kernels, f"Choose which kernel to use (leave blank for default: {DEFAULT_KERNEL}): ", default=DEFAULT_KERNEL)
+ return generic_multi_select(kernels, f"Choose which kernels to use (Default value for empty selection: {DEFAULT_KERNEL}): ", default=DEFAULT_KERNEL)
raise RequirementError("Selecting kernels require a least one kernel to be given as an option.")