Skip the repeat language screen in the CJK console; show the keyboard by its label
This commit is contained in:
3 files changed
+12
-12
No files matched your search
@@ -26,7 +26,7 @@ For local development, build the ISO from sibling checkouts:
|
||||
|
||||
Despite the local folder name, the first argument is the Omarchy source checkout (runtime commands, configs, setup scripts, themes, shell, migrations). The installer itself lives in this ISO repo.
|
||||
|
||||
The configurator asks for the language on its first screen: English or Simplified Chinese. Chinese reruns the installer in cage + foot, a console that draws Chinese, with Noto Sans Mono CJK unpacked from the offline mirror's `noto-fonts-cjk`. It opens on a bilingual language screen, offers only keyboards with a US keymap (cage keeps a US layout) and preselects Chinese (Simplified, Pinyin); every later screen and the install progress read in Chinese. Choosing English there returns to the VT, which applies the chosen keymap. Without a working display or the font, Chinese continues in English on the VT. Either way a Chinese install sets the target's `LANG` to `zh_CN.UTF-8` through archinstall's `locale_config`. The language never decides the region: that follows the timezone. The Chinese text lives in `OMARCHY_ZH` tables beside the English it replaces.
|
||||
The configurator asks for the language on its first screen: English or Simplified Chinese. Chinese reruns the installer in cage + foot, a console that draws Chinese, with Noto Sans Mono CJK unpacked from the offline mirror's `noto-fonts-cjk`. It opens on the keyboard screen, offers only keyboards with a US keymap (cage keeps a US layout) and preselects Chinese (Simplified, Pinyin); every later screen and the install progress read in Chinese. Esc there goes back to a bilingual language screen, where English returns to the VT, which applies the chosen keymap. Without a working display or the font, Chinese continues in English on the VT. Either way a Chinese install sets the target's `LANG` to `zh_CN.UTF-8` through archinstall's `locale_config`. The language never decides the region: that follows the timezone. The Chinese text lives in `OMARCHY_ZH` tables beside the English it replaces.
|
||||
|
||||
Use `--dev` or `--rc` to build against those package channels. Both `--dev` and `--edge` select the dev packages from the edge mirror.
|
||||
|
||||
|
||||
@@ -696,14 +696,7 @@ drive_configurator() {
|
||||
if [[ $INSTALL_LANGUAGE == "zh" ]]; then press end; else press home; fi
|
||||
press ret
|
||||
|
||||
# Chinese reruns in cage + foot on a bilingual language screen, Chinese preselected.
|
||||
if [[ $INSTALL_LANGUAGE == "zh" ]]; then
|
||||
wait_for_screen "选择语言" 300
|
||||
capture_console "success-installer-01-language-cjk"
|
||||
press ret
|
||||
fi
|
||||
|
||||
# The keyboard follows; Ctrl+C there defers provisioning.
|
||||
# The keyboard follows, for Chinese in cage + foot; Ctrl+C there defers provisioning.
|
||||
wait_for_screen "$(lang_text "keyboard layout" "键盘布局")" 300
|
||||
capture_console "success-installer-01-keyboard-layout"
|
||||
|
||||
|
||||
@@ -306,9 +306,14 @@ keyboard_form() {
|
||||
say --foreground 8 "$(omarchy_text "Press Ctrl+C to prepare this machine for another owner.")"
|
||||
echo
|
||||
|
||||
omarchy_prompt_language && status=0 || status=$?
|
||||
status=0
|
||||
if ! $language_chosen; then
|
||||
omarchy_prompt_language && status=0 || status=$?
|
||||
((status == 0)) && apply_language
|
||||
fi
|
||||
# Esc, Ctrl+C or a later "No, change it" asks the language again.
|
||||
language_chosen=false
|
||||
if ((status == 0)); then
|
||||
apply_language
|
||||
local layouts=$OMARCHY_KEYBOARD_LAYOUTS selected="English (US)"
|
||||
[[ $language == "zh" ]] && selected="Chinese (Simplified, Pinyin)"
|
||||
# cage keeps its US layout, so the CJK console offers only US-keymap keyboards.
|
||||
@@ -406,7 +411,7 @@ $(omarchy_text "Full name"),${full_name:-$skipped}
|
||||
$(omarchy_text "Email address"),${email_address:-$skipped}
|
||||
$(omarchy_text Hostname),$hostname
|
||||
$(omarchy_text Timezone),$timezone$region_row
|
||||
$(omarchy_text Keyboard),$keyboard" |
|
||||
$(omarchy_text Keyboard),\"$keyboard_label\"" |
|
||||
gum table -s "," -p | sed "s/^/${PADDING_LEFT_SPACES}/"
|
||||
|
||||
echo
|
||||
@@ -1146,6 +1151,7 @@ defer_provisioning=false
|
||||
install_target="full_disk"
|
||||
# A rerun arrives with the language chosen; otherwise English.
|
||||
language="${OMARCHY_INSTALL_LANGUAGE:-en}"
|
||||
language_chosen=false
|
||||
|
||||
# Let the live VT reach its settled width before the first screen so the logo
|
||||
# isn't measured against the transient 80-column boot console.
|
||||
@@ -1153,6 +1159,7 @@ wait_for_stable_terminal
|
||||
|
||||
if [[ -n ${OMARCHY_INSTALL_LANGUAGE:-} ]]; then
|
||||
apply_language
|
||||
language_chosen=true
|
||||
else
|
||||
greeter
|
||||
fi
|
||||
|
||||
Reference in new issue
Block a user