Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/examples/guided.py
diff options
context:
space:
mode:
authorDaniel Girtler <blackrabbit256@gmail.com>2022-05-27 05:48:29 +1000
committerGitHub <noreply@github.com>2022-05-26 21:48:29 +0200
commit870da403e79ab50350803b45f200e0b272334989 (patch)
tree9b203a054bd10cbc73a81b4fd5fe24ef8e6f141a /examples/guided.py
parent353c05318ce80b8eec32031c9e14b8471b458548 (diff)
Rework user management (#1220)
* Rework users * Update user installation * Fix config serialization * Update * Update schemas and documentation * Update * Fix flake8 * Make users mypy compatible * Fix minor copy Co-authored-by: Daniel Girtler <girtler.daniel@gmail.com> Co-authored-by: Anton Hvornum <anton@hvornum.se>
Diffstat (limited to 'examples/guided.py')
-rw-r--r--examples/guided.py10
1 files changed, 2 insertions, 8 deletions
diff --git a/examples/guided.py b/examples/guided.py
index 3b762a8b..19b0d638 100644
--- a/examples/guided.py
+++ b/examples/guided.py
@@ -72,7 +72,6 @@ def ask_user_questions():
# Ask for a root password (optional, but triggers requirement for super-user if skipped)
global_menu.enable('!root-password')
- global_menu.enable('!superusers')
global_menu.enable('!users')
# Ask for archinstall-specific profiles (such as desktop environments etc)
@@ -220,13 +219,8 @@ def perform_installation(mountpoint):
if archinstall.arguments.get('profile', None):
installation.install_profile(archinstall.arguments.get('profile', None))
- if archinstall.arguments.get('!users',{}):
- for user, user_info in archinstall.arguments.get('!users', {}).items():
- installation.user_create(user, user_info["!password"], sudo=False)
-
- 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 users := archinstall.arguments.get('!users', None):
+ installation.create_users(users)
if timezone := archinstall.arguments.get('timezone', None):
installation.set_timezone(timezone)