Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorYash Tripathi <tripathiyash97@gmail.com>2021-05-23 10:54:06 +0530
committerYash Tripathi <tripathiyash97@gmail.com>2021-05-23 10:54:06 +0530
commit4a691b6dbf506e638592418c85934eaabdad7fdc (patch)
tree42a6d38d24edbbbe2c0398aa7930e1327c497935 /examples
parent1d984625c8b18180ad9e62332d32b20c9e2d4c7e (diff)
parent86b415e25c8b2616f0850964f504e1ae1c6e0edb (diff)
Merge branch 'archlinux:master' into master
Diffstat (limited to 'examples')
-rw-r--r--examples/guided.py14
1 files changed, 13 insertions, 1 deletions
diff --git a/examples/guided.py b/examples/guided.py
index e60cd0f8..cbf30eb3 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()
+ archinstall.log("Keep in mind that if you want multiple locales, post configuration is required.", fg="yellow")
+
+ if not archinstall.arguments.get('sys-language', None):
+ archinstall.arguments['sys-language'] = 'en_US'
+ if not archinstall.arguments.get('sys-encoding', None):
+ archinstall.arguments['sys-encoding'] = 'utf-8'
+
+
# Ask which harddrive/block-device we will install to
if archinstall.arguments.get('harddrive', None):
archinstall.arguments['harddrive'] = archinstall.BlockDevice(archinstall.arguments['harddrive'])
@@ -182,7 +193,7 @@ def ask_user_questions():
# Ask for archinstall-specific profiles (such as desktop environments etc)
if not archinstall.arguments.get('profile', None):
- archinstall.arguments['profile'] = archinstall.select_profile(archinstall.list_profiles(filter_top_level_profiles=True))
+ archinstall.arguments['profile'] = archinstall.select_profile()
else:
archinstall.arguments['profile'] = Profile(installer=None, path=archinstall.arguments['profile'])
@@ -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