index : archinstall32 | |
Archlinux32 installer | gitolite user |
summaryrefslogtreecommitdiff |
author | Anton Hvornum <anton@hvornum.se> | 2021-05-22 20:40:20 +0200 |
---|---|---|
committer | Anton Hvornum <anton@hvornum.se> | 2021-05-22 20:40:20 +0200 |
commit | d7e23c847f4901b039b5a78c92e63ffa20b31268 (patch) | |
tree | dd40b4c40fb9ab9b87f3a9ae2f5e7712b12f1af6 /examples/guided.py | |
parent | 35974e662459066db6e2ad8538bb83a7dee56028 (diff) |
-rw-r--r-- | examples/guided.py | 12 |
diff --git a/examples/guided.py b/examples/guided.py index e60cd0f8..122f0804 100644 --- a/examples/guided.py +++ b/examples/guided.py @@ -51,6 +51,17 @@ def ask_user_questions(): selected_region = archinstall.arguments['mirror-region'] archinstall.arguments['mirror-region'] = {selected_region: archinstall.list_mirrors()[selected_region]} + if not archinstall.arguments.get('sys-language', None) and archinstall.arguments.get('advanced', False): + archinstall.arguments['sys-language'] = input("Enter a valid locale (language) for your OS, (Default: en_US): ").strip() + archinstall.arguments['sys-encoding'] = input("Enter a valid system default encoding for your OS, (Default: utf-8): ").strip() + + if not archinstall.arguments['sys-language']: + archinstall.arguments['sys-language'] = 'en_US' + if not archinstall.arguments['sys-encoding']: + archinstall.arguments['sys-encoding'] = 'utf-8' + + archinstall.log("Keep in mind that if you want multiple locales, post configuration is required.", fg="yellow") + # Ask which harddrive/block-device we will install to if archinstall.arguments.get('harddrive', None): archinstall.arguments['harddrive'] = archinstall.BlockDevice(archinstall.arguments['harddrive']) @@ -328,6 +339,7 @@ def perform_installation(mountpoint): if archinstall.arguments.get('mirror-region', None): archinstall.use_mirrors(archinstall.arguments['mirror-region']) # Set the mirrors for the live medium if installation.minimal_installation(): + installation.set_locale(archinstall.arguments['sys-language'], archinstall.arguments['sys-encoding'].upper()) installation.set_hostname(archinstall.arguments['hostname']) if archinstall.arguments['mirror-region'].get("mirrors", None) is not None: installation.set_mirrors(archinstall.arguments['mirror-region']) # Set the mirrors in the installation medium |