Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/archinstall
diff options
context:
space:
mode:
authorcodefiles <11915375+codefiles@users.noreply.github.com>2022-10-03 10:42:10 -0400
committerGitHub <noreply@github.com>2022-10-03 16:42:10 +0200
commit977976f88e761ced7d5bc9f39b32e2296ee91806 (patch)
treeee4b47ed02a3d4a1ff1fddd584a16d5bb9241f45 /archinstall
parent40e4046633d857929b8fd1bfa121b38937add81c (diff)
Add hostname and locales as parameters to `minimal_installation()` (#1458)
Diffstat (limited to 'archinstall')
-rw-r--r--archinstall/lib/installer.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/archinstall/lib/installer.py b/archinstall/lib/installer.py
index 1270959e..49ce4d7f 100644
--- a/archinstall/lib/installer.py
+++ b/archinstall/lib/installer.py
@@ -662,7 +662,9 @@ class Installer:
return SysCommand(f'/usr/bin/arch-chroot {self.target} mkinitcpio {" ".join(flags)}').exit_code == 0
- def minimal_installation(self, testing=False, multilib=False) -> bool:
+ def minimal_installation(
+ self, testing: bool = False, multilib: bool = False,
+ hostname: str = 'archinstall', locales: List[str] = ['en_US.UTF-8 UTF-8']) -> bool:
# Add necessary packages if encrypting the drive
# (encrypted partitions default to btrfs for now, so we need btrfs-progs)
# TODO: Perhaps this should be living in the function which dictates
@@ -750,8 +752,8 @@ class Installer:
# os.remove(f'{self.target}/etc/localtime')
# sys_command(f'/usr/bin/arch-chroot {self.target} ln -s /usr/share/zoneinfo/{localtime} /etc/localtime')
# sys_command('/usr/bin/arch-chroot /mnt hwclock --hctosys --localtime')
- self.set_hostname('archinstall')
- self.set_locale('en_US')
+ self.set_hostname(hostname)
+ self.set_locale(*locales[0].split())
# TODO: Use python functions for this
SysCommand(f'/usr/bin/arch-chroot {self.target} chmod 700 /root')