From e85c9b65315498ab4701ea31c079d198eba8d9ac Mon Sep 17 00:00:00 2001 From: Werner Llácer Date: Mon, 28 Mar 2022 13:44:10 +0200 Subject: Issues with Network Management and user management in menu (#1036) * A problem with default values treatment at superusers (and users) on the main menu * Solving issues when changing the selection of nic, ask_to_configure_network failed in several places. Solved, temporarily with the creation of __getitem__ and get methods at NetworkManager * Accept old style definitions for nic * flake8 complains * log string corrected (issue 1039) * Correct exit when no disk is selected and we don't wish to continue --- examples/swiss.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'examples/swiss.py') diff --git a/examples/swiss.py b/examples/swiss.py index cf864ed5..6f524103 100644 --- a/examples/swiss.py +++ b/examples/swiss.py @@ -415,11 +415,13 @@ def os_setup(installation): if archinstall.arguments.get('profile', None): installation.install_profile(archinstall.arguments.get('profile', None)) - for user, user_info in archinstall.arguments.get('!users', {}).items(): - installation.user_create(user, user_info["!password"], sudo=False) + if archinstall.arguments.get('!users',{}): + for user, user_info in archinstall.arguments.get('!users', {}).items(): + installation.user_create(user, user_info["!password"], sudo=False) - for superuser, user_info in archinstall.arguments.get('!superusers', {}).items(): - installation.user_create(superuser, user_info["!password"], sudo=True) + if archinstall.arguments.get('!superusers',{}): + for superuser, user_info in archinstall.arguments.get('!superusers', {}).items(): + installation.user_create(superuser, user_info["!password"], sudo=True) if timezone := archinstall.arguments.get('timezone', None): installation.set_timezone(timezone) -- cgit v1.2.3-70-g09d2