author | Shawn O. Pearce <spearce@spearce.org> | |
Mon, 10 Sep 2007 05:54:16 +0000 (01:54 -0400) | ||
committer | Shawn O. Pearce <spearce@spearce.org> | |
Mon, 10 Sep 2007 05:54:16 +0000 (01:54 -0400) | ||
commit | 66c75a5c9f7434d857d836440dc1c3046c59b5f3 | |
tree | 5753b6221f18678cef90bfa028c34310869687dc | tree | snapshot |
parent | 93716a62c07561467a5c6fb0e14c4897cf264e7e | commit | diff |
git-gui: Localize commit/author dates when displaying them
Currently the Git plumbing is not localized so it does not know how
to output weekday and month names that conform to the user's locale
preferences. This doesn't fit with the rest of git-gui's UI as some
of our dates are formatted in Tcl and some are just read from the Git
plumbing so dates aren't consistently presented.
Since git-for-each-ref is presenting us formatted dates and it offers
no way to change that setting even in git 1.5.3.1 we need to first do
a parse of the text strings it produces, correct for timezones, then
reformat the timestamp using Tcl's formatting routines.
Not exactly what I wanted to do but it gets us consistently presented
date strings in areas like the blame viewer and the revision picker
mega-widget's tooltips.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Currently the Git plumbing is not localized so it does not know how
to output weekday and month names that conform to the user's locale
preferences. This doesn't fit with the rest of git-gui's UI as some
of our dates are formatted in Tcl and some are just read from the Git
plumbing so dates aren't consistently presented.
Since git-for-each-ref is presenting us formatted dates and it offers
no way to change that setting even in git 1.5.3.1 we need to first do
a parse of the text strings it produces, correct for timezones, then
reformat the timestamp using Tcl's formatting routines.
Not exactly what I wanted to do but it gets us consistently presented
date strings in areas like the blame viewer and the revision picker
mega-widget's tooltips.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
lib/blame.tcl | diff | blob | history | |
lib/choose_rev.tcl | diff | blob | history | |
lib/date.tcl | [new file with mode: 0644] | blob |