From 39acfa3d224e4a125a3f72ef761ee2cbd24216c2 Mon Sep 17 00:00:00 2001 From: Kazuhiro Kato Date: Sat, 7 Dec 2019 00:29:09 +0000 Subject: git gui: fix branch name encoding error MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit After "git checkout -b '漢字'" to create a branch with UTF-8 character in it, "git gui" shows the branch name incorrectly, as it forgets to turn the bytes read from the "git for-each-ref" and read from "HEAD" file into Unicode characters. Signed-off-by: Kazuhiro Kato Signed-off-by: Pratyush Yadav --- git-gui.sh | 1 + 1 file changed, 1 insertion(+) (limited to 'git-gui.sh') diff --git a/git-gui.sh b/git-gui.sh index 6dcf6551b6..c1be733e3e 100755 --- a/git-gui.sh +++ b/git-gui.sh @@ -684,6 +684,7 @@ proc load_current_branch {} { global current_branch is_detached set fd [open [gitdir HEAD] r] + fconfigure $fd -translation binary -encoding utf-8 if {[gets $fd ref] < 1} { set ref {} } -- cgit v1.3-5-g9baa