From: Junio C Hamano Date: Mon, 28 Nov 2005 00:12:51 +0000 (-0800) Subject: [PATCH] gitk: Use i18n.commitencoding configuration item. X-Git-Tag: v0.99.9l^2~27^2~1 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=671bc1538a88d82096a8e59d9ccef4f4a5c40a32;p=git.git [PATCH] gitk: Use i18n.commitencoding configuration item. Hardcoding "utf-8" in the script breaks projects that use local encoding, so allow setting i18n.commitEncoding. Signed-off-by: Junio C Hamano Signed-off-by: Paul Mackerras --- diff --git a/gitk b/gitk index e1c395475..730ffd920 100755 --- a/gitk +++ b/gitk @@ -3656,7 +3656,14 @@ set datemode 0 set boldnames 0 set diffopts "-U 5 -p" set wrcomcmd "git-diff-tree --stdin -p --pretty" -set gitencoding "utf-8" + +set gitencoding "" +catch { + set gitencoding [exec git-repo-config --get i18n.commitencoding] +} +if {$gitencoding == ""} { + set gitencoding "utf-8" +} set mainfont {Helvetica 9} set textfont {Courier 9}