etc/profile: Fix setting of LC_* variables

Since hrev51075, locale -m changed meaning to the one expected by POSIX
(it now lists character maps, instead of giving the current language).

Since the short options may change again (locale -c is still not doing
what POSIX requires), use long options instead. This is more readable
and POSIX doesn't specify anything there so we can name them however we
want.

Fixes date parsing in Python which relies on these variables to detect
the current locale.
This commit is contained in:
Adrien Destugues
2017-11-23 14:50:11 +01:00
parent 4205fc9141
commit 5f4f984a94
+3 -3
View File
@@ -23,9 +23,9 @@ export HISTFILESIZE=500
export HISTCONTROL=ignoredups
# Locale
export LC_MESSAGES=`locale -m`
export LC_NUMERIC=`locale -f`
export LC_TIME=`locale -t`
export LC_MESSAGES=`locale --message`
export LC_NUMERIC=`locale --format`
export LC_TIME=`locale --time`
export LC_COLLATE=$LC_MESSAGES
export LC_CTYPE=$LC_MESSAGES
export LC_MONETARY=$LC_NUMERIC