Apparent I should set LC_TIME to en_DK (why danish? I don't want danish months!) but nothing I've done manages to change the output of locale.
2 Answers
What do you want to achieve? To change the format temporarily
$ date
Mon Feb 21 18:46:57 CET 2011
$ LANG=cs_CZ.utf8 date
Po úno 21 18:47:22 CET 2011
or permanently by putting the variables in /etc/default/locale?
-
Permanently, but only the time format (24h), dd-mm-yyyy, not the language, and /etc/default/locale already contains
LC_TIME=en_DK.UTF-8but it doesn't affect the output oflocale. Feb 21, 2011 at 18:26 -
1But why? The output of
LANG=en_DK.utf8 dateis the same as ofLANG=en_US.utf8 date. Or you want something likedate +%d-%m-%Y?– arrangeFeb 21, 2011 at 19:10
@arrange I had the same as you. But i resolved it. Additionally you need to add
export TIME_STYLE="long-iso"
export LC_TIME="en_DK.UTF-8"
to ~/.bashrc file at the end and relogin my user or execute:
source ~/.bashrc
Then ls -l print 2017-01-22 21:45 date format.
Maybe it help for another.