summaryrefslogtreecommitdiff
path: root/guix
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2020-09-02 15:59:09 +0200
committerLudovic Courtès <ludo@gnu.org>2020-09-02 17:17:37 +0200
commitfe4e770fc1a1a0ddc5025ac61d3d960621127fd8 (patch)
treecac05f0acd071dce1f7077b5bd9bf41b76e31861 /guix
parent739f6309478d8ab8501bb653ceb2f634c8560f55 (diff)
ui: Attempt to fall back to "en_US.utf8" rather than "C".
* guix/ui.scm (install-locale): Add call to 'setlocale' in 'catch' handler.
Diffstat (limited to 'guix')
-rw-r--r--guix/ui.scm6
1 files changed, 5 insertions, 1 deletions
diff --git a/guix/ui.scm b/guix/ui.scm
index efc3f39186..9513f42b93 100644
--- a/guix/ui.scm
+++ b/guix/ui.scm
@@ -494,7 +494,11 @@ guix package -i glibc-utf8-locales
export GUIX_LOCPATH=\"$HOME/.guix-profile/lib/locale\"
@end example
-See the \"Application Setup\" section in the manual, for more info.\n")))))
+See the \"Application Setup\" section in the manual, for more info.\n"))
+ ;; We're now running in the "C" locale. Try to install a UTF-8 locale
+ ;; instead. This one is guaranteed to be available in 'guix' from 'guix
+ ;; pull'.
+ (false-if-exception (setlocale LC_ALL "en_US.utf8")))))
(define (initialize-guix)
"Perform the usual initialization for stand-alone Guix commands."