summaryrefslogtreecommitdiff
path: root/gnu/installer/newt
diff options
context:
space:
mode:
authorMathieu Othacehe <m.othacehe@gmail.com>2018-12-05 19:29:54 +0900
committerLudovic Courtès <ludo@gnu.org>2019-01-17 14:04:24 +0100
commit30cf5e04264e18b2fd0dcc73cbce2ef4324563e1 (patch)
tree24447e7f5652ce5db71ee8cbcf0b1c99d395f84b /gnu/installer/newt
parent30b4df8627b0ecf1ee15e832b7adcf5640f09d3c (diff)
installer: locale: Set English as the default language.
* gnu/installer/newt/locale.scm (sort-languages): New procedure ... (run-locale-page)[locale-steps]: ... used here to make english the default language.
Diffstat (limited to 'gnu/installer/newt')
-rw-r--r--gnu/installer/newt/locale.scm11
1 files changed, 10 insertions, 1 deletions
diff --git a/gnu/installer/newt/locale.scm b/gnu/installer/newt/locale.scm
index 0389416459..4de78f3330 100644
--- a/gnu/installer/newt/locale.scm
+++ b/gnu/installer/newt/locale.scm
@@ -146,6 +146,14 @@ glibc locale string and return it."
((locale)
(locale->locale-string locale))))
+ (define (sort-languages languages)
+ "Extract some languages from LANGUAGES list and place them ahead."
+ (let* ((first-languages '("en"))
+ (other-languages (lset-difference equal?
+ languages
+ first-languages)))
+ `(,@first-languages ,@other-languages)))
+
(define locale-steps
(list
(installer-step
@@ -153,7 +161,8 @@ glibc locale string and return it."
(compute
(lambda _
(run-language-page
- (delete-duplicates (map locale-language supported-locales))
+ (sort-languages
+ (delete-duplicates (map locale-language supported-locales)))
(cut language-code->language-name iso639-languages <>)))))
(installer-step
(id 'territory)