From 493814d8bd9a89089c6bedf82f9c85ca7075edfb Mon Sep 17 00:00:00 2001 From: SecondThundeR Date: Thu, 6 May 2021 21:38:20 +0300 Subject: Add default graphics card driver option --- archinstall/lib/user_interaction.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'archinstall/lib') diff --git a/archinstall/lib/user_interaction.py b/archinstall/lib/user_interaction.py index 81f04db4..aea708c8 100644 --- a/archinstall/lib/user_interaction.py +++ b/archinstall/lib/user_interaction.py @@ -673,6 +673,7 @@ def select_driver(options=AVAILABLE_GFX_DRIVERS): """ drivers = sorted(list(options)) + default_option = options["All open-source (default)"] if drivers: lspci = sys_command(f'/usr/bin/lspci') @@ -683,7 +684,11 @@ 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: ", allow_empty_input=False) + initial_option = generic_select(drivers, input_text="Select your graphics card driver: ") + + if not initial_option: + return default_option + selected_driver = options[initial_option] if type(selected_driver) == dict: -- cgit v1.2.3-70-g09d2