index : archinstall32 | |
Archlinux32 installer | gitolite user |
summaryrefslogtreecommitdiff |
author | Dylan Taylor <dylan@dylanmtaylor.com> | 2021-05-15 15:24:34 -0400 |
---|---|---|
committer | Dylan Taylor <dylan@dylanmtaylor.com> | 2021-05-15 15:24:34 -0400 |
commit | 96a48664e2d69d138f58967fdd75c605ad21478e (patch) | |
tree | 0429b25ba97ea4457b1a1f52b0875859509696b8 /archinstall/lib/installer.py | |
parent | f7642786c9e169245fae52d8754b9d68f2507cb7 (diff) |
-rw-r--r-- | archinstall/lib/installer.py | 10 |
diff --git a/archinstall/lib/installer.py b/archinstall/lib/installer.py index cdf69273..9ddb8825 100644 --- a/archinstall/lib/installer.py +++ b/archinstall/lib/installer.py @@ -34,7 +34,11 @@ class Installer: """ - def __init__(self, target, *, base_packages=__packages__[:3], kernels=['linux']): + def __init__(self, target, *, base_packages=None, kernels=None): + if base_packages is None: + base_packages = __packages__[:3] + if kernels is None: + kernels = ['linux'] self.target = target self.init_time = time.strftime('%Y-%m-%d_%H-%M-%S') self.milliseconds = int(str(time.time()).split('.')[1]) @@ -476,7 +480,9 @@ class Installer: sudoers.write(f'{"%" if group else ""}{entity} ALL=(ALL) ALL\n') return True - def user_create(self, user: str, password=None, groups=[], sudo=False): + def user_create(self, user: str, password=None, groups=None, sudo=False): + if groups is None: + groups = [] self.log(f'Creating user {user}', level=logging.INFO) o = b''.join(sys_command(f'/usr/bin/arch-chroot {self.target} useradd -m -G wheel {user}')) if password: |