Hello,
the current LiveCD uses the following construction for printing the date in
bash prompt:
PS1="...\@ \d..."
This doesn't produce the "canonical" representation of date and time in some
locales. E.g., 12-hour clock is uncommon in Russia. I propose changing this
to:
PS1="...\D{%c}..."
This always prints date and time according to the current locale "preferred"
representation, e.g.:
LANG=C: Sat May 14 18:28:49 2005
LANG=en_US: Sat May 14 2005 06:28:49 PM YEKST
LANG=en_GB: Sat May 14 2005 18:28:49 YEKST
LANG=es_ES: sÃb 14 may 2005 18:28:49 YEKST
LANG=ru_RU.KOI8-R: ÐÐÑ 14 ÐÐÐ 2005 18:28:49
LANG=hu_HU: 2005. mÃj. 14., szombat, 18.28.49 YEKST
LANG=zh_TW: èå2005å05æ14æ (éå) 18æ28å49ç
(but there's no way to see the last line on the Live CD without editing
several configuration files).
Unfortunately, there's no way to suppress seconds from "locale-correct" date
representation.
Any objections to this change in /etc/bashrc? Should bash print that in orange
or in bright white color for a regular user?
--
Alexander E. Patrakov
--
http://linuxfromscratch.org/mailman/listinfo/livecd
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page