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.
master
Mathieu Othacehe 2018-12-05 19:29:54 +09:00 committed by Ludovic Courtès
parent 30b4df8627
commit 30cf5e0426
No known key found for this signature in database
GPG Key ID: 090B11993D9AEBB5
1 changed files with 10 additions and 1 deletions

View File

@ -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)