# [PATCH] Internationalization of git-gui

17 messages from 2007-07-19 to 2007-07-22. Participants: Christian Stimming, Johannes Schindelin, Shawn O. Pearce, Paolo Ciarrocchi, Junio C Hamano, Sam Ravnborg, Xudong Guan, しらいしななこ.
Thread: https://gitlist.dev/t/9106

## Christian Stimming, 2007-07-19 10:56

Subject: [PATCH] Internationalization of git-gui
Message-ID: <20070719125657.8utk85ynuow4ow48@webmail.tu-harburg.de>
URL: https://gitlist.dev/e/20070719125657.8utk85ynuow4ow48%40webmail.tu-harburg.de

```
This is an initial patch of how internationalization (i18n) in git  
could be done, starting with the git-gui application (because I need  
that one in German to convince my workplace of switching to git).

Does this implementation look okay? If yes, I'd happily i18n'ize the  
rest of git-gui and provide a full German translation as well.

Thanks,

Christian Stimming


>From ea66070d95061e623cb5430fe88efea653e511e0 Mon Sep 17 00:00:00 2001
From: Christian Stimming <stimming@tuhh.de>
Date: Thu, 19 Jul 2007 12:48:08 +0200
Subject: [PATCH] Initialize msgcat (gettext).

---
 git-gui/git-gui.sh |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/git-gui/git-gui.sh b/git-gui/git-gui.sh
index 2077261..c56a3f1 100755
--- a/git-gui/git-gui.sh
+++ b/git-gui/git-gui.sh
@@ -108,6 +108,12 @@ if {$idx ne {}} {
 }
 unset -nocomplain oguirel idx fd
 
+## Internationalization (i18n) through gettext. See
+## http://www.gnu.org/software/gettext/manual/html_node/Tcl.html
+package require msgcat
+::msgcat::mcload [file join $oguilib msgs]
+proc _ {s} {return [::msgcat::mc $s]}
+
 ######################################################################
 ##
 ## read only globals
-- 
1.5.3.rc2.4.g726f9



>From 154d29786bdda205357595e22b3385d7cdb77453 Mon Sep 17 00:00:00 2001
From: Christian Stimming <stimming@tuhh.de>
Date: Thu, 19 Jul 2007 12:49:09 +0200
Subject: [PATCH] Mark strings for translation

---
 git-gui/git-gui.sh |  154 ++++++++++++++++++++++++++--------------------------
 1 files changed, 77 insertions(+), 77 deletions(-)

diff --git a/git-gui/git-gui.sh b/git-gui/git-gui.sh
index c56a3f1..45b7ef1 100755
--- a/git-gui/git-gui.sh
+++ b/git-gui/git-gui.sh
@@ -1618,18 +1618,18 @@ set ui_comm {}
 # -- Menu Bar
 #
 menu .mbar -tearoff 0
-.mbar add cascade -label Repository -menu .mbar.repository
-.mbar add cascade -label Edit -menu .mbar.edit
+.mbar add cascade -label [_ Repository] -menu .mbar.repository
+.mbar add cascade -label [_ Edit] -menu .mbar.edit
 if {[is_enabled branch]} {
-	.mbar add cascade -label Branch -menu .mbar.branch
+	.mbar add cascade -label [_ Branch] -menu .mbar.branch
 }
 if {[is_enabled multicommit] || [is_enabled singlecommit]} {
-	.mbar add cascade -label Commit -menu .mbar.commit
+	.mbar add cascade -label [_ Commit] -menu .mbar.commit
 }
 if {[is_enabled transport]} {
-	.mbar add cascade -label Merge -menu .mbar.merge
-	.mbar add cascade -label Fetch -menu .mbar.fetch
-	.mbar add cascade -label Push -menu .mbar.push
+	.mbar add cascade -label [_ Merge] -menu .mbar.merge
+	.mbar add cascade -label [_ Fetch] -menu .mbar.fetch
+	.mbar add cascade -label [_ Push] -menu .mbar.push
 }
 . configure -menu .mbar
 
@@ -1638,75 +1638,75 @@ if {[is_enabled transport]} {
 menu .mbar.repository
 
 .mbar.repository add command \
-	-label {Browse Current Branch} \
+	-label [_ {Browse Current Branch}] \
 	-command {browser::new $current_branch}
 trace add variable current_branch write ".mbar.repository entryconf [.mbar.repository index last] -label \"Browse \$current_branch\" ;#"
 .mbar.repository add separator
 
 .mbar.repository add command \
-	-label {Visualize Current Branch} \
+	-label [_ {Visualize Current Branch}]  \
 	-command {do_gitk $current_branch}
 trace add variable current_branch write ".mbar.repository entryconf [.mbar.repository index last] -label \"Visualize \$current_branch\" ;#"
 .mbar.repository add command \
-	-label {Visualize All Branches} \
+	-label [_ {Visualize All Branches}] \
 	-command {do_gitk --all}
 .mbar.repository add separator
 
 if {[is_enabled multicommit]} {
-	.mbar.repository add command -label {Database Statistics} \
+	.mbar.repository add command -label [_ {Database Statistics}] \
 		-command do_stats
 
-	.mbar.repository add command -label {Compress Database} \
+	.mbar.repository add command -label [_ {Compress Database}] \
 		-command do_gc
 
-	.mbar.repository add command -label {Verify Database} \
+	.mbar.repository add command -label [_ {Verify Database}] \
 		-command do_fsck_objects
 
 	.mbar.repository add separator
 
 	if {[is_Cygwin]} {
 		.mbar.repository add command \
-			-label {Create Desktop Icon} \
+			-label [_ {Create Desktop Icon}] \
 			-command do_cygwin_shortcut
 	} elseif {[is_Windows]} {
 		.mbar.repository add command \
-			-label {Create Desktop Icon} \
+			-label [_ {Create Desktop Icon}] \
 			-command do_windows_shortcut
 	} elseif {[is_MacOSX]} {
 		.mbar.repository add command \
-			-label {Create Desktop Icon} \
+			-label [_ {Create Desktop Icon}] \
 			-command do_macosx_app
 	}
 }
 
-.mbar.repository add command -label Quit \
+.mbar.repository add command -label [_ Quit] \
 	-command do_quit \
 	-accelerator $M1T-Q
 
 # -- Edit Menu
 #
 menu .mbar.edit
-.mbar.edit add command -label Undo \
+.mbar.edit add command -label [_ Undo] \
 	-command {catch {[focus] edit undo}} \
 	-accelerator $M1T-Z
-.mbar.edit add command -label Redo \
+.mbar.edit add command -label [_ Redo] \
 	-command {catch {[focus] edit redo}} \
 	-accelerator $M1T-Y
 .mbar.edit add separator
-.mbar.edit add command -label Cut \
+.mbar.edit add command -label [_ Cut] \
 	-command {catch {tk_textCut [focus]}} \
 	-accelerator $M1T-X
-.mbar.edit add command -label Copy \
+.mbar.edit add command -label [_ Copy] \
 	-command {catch {tk_textCopy [focus]}} \
 	-accelerator $M1T-C
-.mbar.edit add command -label Paste \
+.mbar.edit add command -label [_ Paste] \
 	-command {catch {tk_textPaste [focus]; [focus] see insert}} \
 	-accelerator $M1T-V
-.mbar.edit add command -label Delete \
+.mbar.edit add command -label [_ Delete] \
 	-command {catch {[focus] delete sel.first sel.last}} \
 	-accelerator Del
 .mbar.edit add separator
-.mbar.edit add command -label {Select All} \
+.mbar.edit add command -label [_ {Select All}] \
 	-command {catch {[focus] tag add sel 0.0 end}} \
 	-accelerator $M1T-A
 
@@ -1715,29 +1715,29 @@ menu .mbar.edit
 if {[is_enabled branch]} {
 	menu .mbar.branch
 
-	.mbar.branch add command -label {Create...} \
+	.mbar.branch add command -label [_ {Create...}] \
 		-command branch_create::dialog \
 		-accelerator $M1T-N
 	lappend disable_on_lock [list .mbar.branch entryconf \
 		[.mbar.branch index last] -state]
 
-	.mbar.branch add command -label {Checkout...} \
+	.mbar.branch add command -label [_ {Checkout...}] \
 		-command branch_checkout::dialog \
 		-accelerator $M1T-O
 	lappend disable_on_lock [list .mbar.branch entryconf \
 		[.mbar.branch index last] -state]
 
-	.mbar.branch add command -label {Rename...} \
+	.mbar.branch add command -label [_ {Rename...}] \
 		-command branch_rename::dialog
 	lappend disable_on_lock [list .mbar.branch entryconf \
 		[.mbar.branch index last] -state]
 
-	.mbar.branch add command -label {Delete...} \
+	.mbar.branch add command -label [_ {Delete...}] \
 		-command branch_delete::dialog
 	lappend disable_on_lock [list .mbar.branch entryconf \
 		[.mbar.branch index last] -state]
 
-	.mbar.branch add command -label {Reset...} \
+	.mbar.branch add command -label [_ {Reset...}] \
 		-command merge::reset_hard
 	lappend disable_on_lock [list .mbar.branch entryconf \
 		[.mbar.branch index last] -state]
@@ -1749,7 +1749,7 @@ if {[is_enabled multicommit] || [is_enabled singlecommit]} {
 	menu .mbar.commit
 
 	.mbar.commit add radiobutton \
-		-label {New Commit} \
+		-label [_ {New Commit}] \
 		-command do_select_commit_type \
 		-variable selected_commit_type \
 		-value new
@@ -1757,7 +1757,7 @@ if {[is_enabled multicommit] || [is_enabled singlecommit]} {
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
 	.mbar.commit add radiobutton \
-		-label {Amend Last Commit} \
+		-label [_ {Amend Last Commit}] \
 		-command do_select_commit_type \
 		-variable selected_commit_type \
 		-value amend
@@ -1766,40 +1766,40 @@ if {[is_enabled multicommit] || [is_enabled singlecommit]} {
 
 	.mbar.commit add separator
 
-	.mbar.commit add command -label Rescan \
+	.mbar.commit add command -label [_ Rescan] \
 		-command do_rescan \
 		-accelerator F5
 	lappend disable_on_lock \
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
-	.mbar.commit add command -label {Add To Commit} \
+	.mbar.commit add command -label [_ {Add To Commit}] \
 		-command do_add_selection
 	lappend disable_on_lock \
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
-	.mbar.commit add command -label {Add Existing To Commit} \
+	.mbar.commit add command -label [_ {Add Existing To Commit}] \
 		-command do_add_all \
 		-accelerator $M1T-I
 	lappend disable_on_lock \
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
-	.mbar.commit add command -label {Unstage From Commit} \
+	.mbar.commit add command -label [_ {Unstage From Commit}] \
 		-command do_unstage_selection
 	lappend disable_on_lock \
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
-	.mbar.commit add command -label {Revert Changes} \
+	.mbar.commit add command -label [_ {Revert Changes}] \
 		-command do_revert_selection
 	lappend disable_on_lock \
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
 	.mbar.commit add separator
 
-	.mbar.commit add command -label {Sign Off} \
+	.mbar.commit add command -label [_ {Sign Off}] \
 		-command do_signoff \
 		-accelerator $M1T-S
 
-	.mbar.commit add command -label Commit \
+	.mbar.commit add command -label [_ Commit] \
 		-command do_commit \
 		-accelerator $M1T-Return
 	lappend disable_on_lock \
@@ -1810,11 +1810,11 @@ if {[is_enabled multicommit] || [is_enabled singlecommit]} {
 #
 if {[is_enabled branch]} {
 	menu .mbar.merge
-	.mbar.merge add command -label {Local Merge...} \
+	.mbar.merge add command -label [_ {Local Merge...}] \
 		-command merge::dialog
 	lappend disable_on_lock \
 		[list .mbar.merge entryconf [.mbar.merge index last] -state]
-	.mbar.merge add command -label {Abort Merge...} \
+	.mbar.merge add command -label [_ {Abort Merge...}] \
 		-command merge::reset_hard
 	lappend disable_on_lock \
 		[list .mbar.merge entryconf [.mbar.merge index last] -state]
@@ -1827,28 +1827,28 @@ if {[is_enabled transport]} {
 	menu .mbar.fetch
 
 	menu .mbar.push
-	.mbar.push add command -label {Push...} \
+	.mbar.push add command -label [_ {Push...}] \
 		-command do_push_anywhere \
 		-accelerator $M1T-P
-	.mbar.push add command -label {Delete...} \
+	.mbar.push add command -label [_ {Delete...}] \
 		-command remote_branch_delete::dialog
 }
 
 if {[is_MacOSX]} {
 	# -- Apple Menu (Mac OS X only)
 	#
-	.mbar add cascade -label Apple -menu .mbar.apple
+	.mbar add cascade -label [_ Apple] -menu .mbar.apple
 	menu .mbar.apple
 
-	.mbar.apple add command -label "About [appname]" \
+	.mbar.apple add command -label [format [_ "About %s"] [appname]] \
 		-command do_about
-	.mbar.apple add command -label "Options..." \
+	.mbar.apple add command -label [_ "Options..."] \
 		-command do_options
 } else {
 	# -- Edit Menu
 	#
 	.mbar.edit add separator
-	.mbar.edit add command -label {Options...} \
+	.mbar.edit add command -label [_ {Options...}] \
 		-command do_options
 
 	# -- Tools Menu
@@ -1870,9 +1870,9 @@ if {[is_MacOSX]} {
 			rescan ui_ready
 		}
 	}
-	.mbar add cascade -label Tools -menu .mbar.tools
+	.mbar add cascade -label [_ Tools] -menu .mbar.tools
 	menu .mbar.tools
-	.mbar.tools add command -label "Migrate" \
+	.mbar.tools add command -label [_ "Migrate"] \
 		-command do_miga
 	lappend disable_on_lock \
 		[list .mbar.tools entryconf [.mbar.tools index last] -state]
@@ -1881,11 +1881,11 @@ if {[is_MacOSX]} {
 
 # -- Help Menu
 #
-.mbar add cascade -label Help -menu .mbar.help
+.mbar add cascade -label [_ Help] -menu .mbar.help
 menu .mbar.help
 
 if {![is_MacOSX]} {
-	.mbar.help add command -label "About [appname]" \
+	.mbar.help add command -label [format [_ "About %s"] [appname]] \
 		-command do_about
 }
 
@@ -1922,7 +1922,7 @@ if {[file isfile $doc_path]} {
 }
 
 if {$browser ne {}} {
-	.mbar.help add command -label {Online Documentation} \
+	.mbar.help add command -label [_ {Online Documentation}] \
 		-command [list exec $browser $doc_url &]
 }
 unset browser doc_path doc_url
@@ -2167,12 +2167,12 @@ label $ui_coml \
 proc trace_commit_type {varname args} {
 	global ui_coml commit_type
 	switch -glob -- $commit_type {
-	initial       {set txt {Initial Commit Message:}}
-	amend         {set txt {Amended Commit Message:}}
-	amend-initial {set txt {Amended Initial Commit Message:}}
-	amend-merge   {set txt {Amended Merge Commit Message:}}
-	merge         {set txt {Merge Commit Message:}}
-	*             {set txt {Commit Message:}}
+	initial       {set txt [_ {Initial Commit Message:}]}
+	amend         {set txt [_ {Amended Commit Message:}]}
+	amend-initial {set txt [_ {Amended Initial Commit Message:}]}
+	amend-merge   {set txt [_ {Amended Merge Commit Message:}]}
+	merge         {set txt [_ {Merge Commit Message:}]}
+	*             {set txt [_ {Commit Message:}]}
 	}
 	$ui_coml conf -text $txt
 }
@@ -2201,23 +2201,23 @@ pack .vpane.lower.commarea.buffer -side left -fill y
 set ctxm .vpane.lower.commarea.buffer.ctxm
 menu $ctxm -tearoff 0
 $ctxm add command \
-	-label {Cut} \
+	-label [_ {Cut}] \
 	-command {tk_textCut $ui_comm}
 $ctxm add command \
-	-label {Copy} \
+	-label [_ {Copy}] \
 	-command {tk_textCopy $ui_comm}
 $ctxm add command \
-	-label {Paste} \
+	-label [_ {Paste}] \
 	-command {tk_textPaste $ui_comm}
 $ctxm add command \
-	-label {Delete} \
+	-label [_ {Delete}] \
 	-command {$ui_comm delete sel.first sel.last}
 $ctxm add separator
 $ctxm add command \
-	-label {Select All} \
+	-label [_ {Select All}] \
 	-command {focus $ui_comm;$ui_comm tag add sel 0.0 end}
 $ctxm add command \
-	-label {Copy All} \
+	-label [_ {Copy All}] \
 	-command {
 		$ui_comm tag add sel 0.0 end
 		tk_textCopy $ui_comm
@@ -2225,7 +2225,7 @@ $ctxm add command \
 	}
 $ctxm add separator
 $ctxm add command \
-	-label {Sign Off} \
+	-label [_ {Sign Off}] \
 	-command do_signoff
 bind_button3 $ui_comm "tk_popup $ctxm %X %Y"
 
@@ -2275,7 +2275,7 @@ pack .vpane.lower.diff.header.path -fill x
 set ctxm .vpane.lower.diff.header.ctxm
 menu $ctxm -tearoff 0
 $ctxm add command \
-	-label {Copy} \
+	-label [_ {Copy}] \
 	-command {
 		clipboard clear
 		clipboard append \
@@ -2343,19 +2343,19 @@ $ui_diff tag raise sel
 set ctxm .vpane.lower.diff.body.ctxm
 menu $ctxm -tearoff 0
 $ctxm add command \
-	-label {Refresh} \
+	-label [_ {Refresh}] \
 	-command reshow_diff
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add command \
-	-label {Copy} \
+	-label [_ {Copy}] \
 	-command {tk_textCopy $ui_diff}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add command \
-	-label {Select All} \
+	-label [_ {Select All}] \
 	-command {focus $ui_diff;$ui_diff tag add sel 0.0 end}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add command \
-	-label {Copy All} \
+	-label [_ {Copy All}] \
 	-command {
 		$ui_diff tag add sel 0.0 end
 		tk_textCopy $ui_diff
@@ -2364,44 +2364,44 @@ $ctxm add command \
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add separator
 $ctxm add command \
-	-label {Apply/Reverse Hunk} \
+	-label [_ {Apply/Reverse Hunk}] \
 	-command {apply_hunk $cursorX $cursorY}
 set ui_diff_applyhunk [$ctxm index last]
 lappend diff_actions [list $ctxm entryconf $ui_diff_applyhunk -state]
 $ctxm add separator
 $ctxm add command \
-	-label {Decrease Font Size} \
+	-label [_ {Decrease Font Size}] \
 	-command {incr_font_size font_diff -1}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add command \
-	-label {Increase Font Size} \
+	-label [_ {Increase Font Size}] \
 	-command {incr_font_size font_diff 1}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add separator
 $ctxm add command \
-	-label {Show Less Context} \
+	-label [_ {Show Less Context}] \
 	-command {if {$repo_config(gui.diffcontext) >= 1} {
 		incr repo_config(gui.diffcontext) -1
 		reshow_diff
 	}}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add command \
-	-label {Show More Context} \
+	-label [_ {Show More Context}] \
 	-command {if {$repo_config(gui.diffcontext) < 99} {
 		incr repo_config(gui.diffcontext)
 		reshow_diff
 	}}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add separator
-$ctxm add command -label {Options...} \
+$ctxm add command -label [_ {Options...}] \
 	-command do_options
 bind_button3 $ui_diff "
 	set cursorX %x
 	set cursorY %y
 	if {\$ui_index eq \$current_diff_side} {
-		$ctxm entryconf $ui_diff_applyhunk -label {Unstage Hunk From Commit}
+		$ctxm entryconf $ui_diff_applyhunk -label [_ {Unstage Hunk From Commit}]
 	} else {
-		$ctxm entryconf $ui_diff_applyhunk -label {Stage Hunk For Commit}
+		$ctxm entryconf $ui_diff_applyhunk -label [_ {Stage Hunk For Commit}]
 	}
 	tk_popup $ctxm %X %Y
 "
-- 
1.5.3.rc2.4.g726f9



>From 3ff00ecdabb82448b95ad3b9e738441236c0eb11 Mon Sep 17 00:00:00 2001
From: Christian Stimming <stimming@tuhh.de>
Date: Thu, 19 Jul 2007 12:49:11 +0200
Subject: [PATCH] Enclose strings in quotes, not in braces, so that xgettext finds them

---
 git-gui/git-gui.sh |  104 ++++++++++++++++++++++++++--------------------------
 1 files changed, 52 insertions(+), 52 deletions(-)

diff --git a/git-gui/git-gui.sh b/git-gui/git-gui.sh
index 45b7ef1..5eef35d 100755
--- a/git-gui/git-gui.sh
+++ b/git-gui/git-gui.sh
@@ -1638,43 +1638,43 @@ if {[is_enabled transport]} {
 menu .mbar.repository
 
 .mbar.repository add command \
-	-label [_ {Browse Current Branch}] \
+	-label [_ "Browse Current Branch"] \
 	-command {browser::new $current_branch}
 trace add variable current_branch write ".mbar.repository entryconf [.mbar.repository index last] -label \"Browse \$current_branch\" ;#"
 .mbar.repository add separator
 
 .mbar.repository add command \
-	-label [_ {Visualize Current Branch}]  \
+	-label [_ "Visualize Current Branch"]  \
 	-command {do_gitk $current_branch}
 trace add variable current_branch write ".mbar.repository entryconf [.mbar.repository index last] -label \"Visualize \$current_branch\" ;#"
 .mbar.repository add command \
-	-label [_ {Visualize All Branches}] \
+	-label [_ "Visualize All Branches"] \
 	-command {do_gitk --all}
 .mbar.repository add separator
 
 if {[is_enabled multicommit]} {
-	.mbar.repository add command -label [_ {Database Statistics}] \
+	.mbar.repository add command -label [_ "Database Statistics"] \
 		-command do_stats
 
-	.mbar.repository add command -label [_ {Compress Database}] \
+	.mbar.repository add command -label [_ "Compress Database"] \
 		-command do_gc
 
-	.mbar.repository add command -label [_ {Verify Database}] \
+	.mbar.repository add command -label [_ "Verify Database"] \
 		-command do_fsck_objects
 
 	.mbar.repository add separator
 
 	if {[is_Cygwin]} {
 		.mbar.repository add command \
-			-label [_ {Create Desktop Icon}] \
+			-label [_ "Create Desktop Icon"] \
 			-command do_cygwin_shortcut
 	} elseif {[is_Windows]} {
 		.mbar.repository add command \
-			-label [_ {Create Desktop Icon}] \
+			-label [_ "Create Desktop Icon"] \
 			-command do_windows_shortcut
 	} elseif {[is_MacOSX]} {
 		.mbar.repository add command \
-			-label [_ {Create Desktop Icon}] \
+			-label [_ "Create Desktop Icon"] \
 			-command do_macosx_app
 	}
 }
@@ -1706,7 +1706,7 @@ menu .mbar.edit
 	-command {catch {[focus] delete sel.first sel.last}} \
 	-accelerator Del
 .mbar.edit add separator
-.mbar.edit add command -label [_ {Select All}] \
+.mbar.edit add command -label [_ "Select All"] \
 	-command {catch {[focus] tag add sel 0.0 end}} \
 	-accelerator $M1T-A
 
@@ -1715,29 +1715,29 @@ menu .mbar.edit
 if {[is_enabled branch]} {
 	menu .mbar.branch
 
-	.mbar.branch add command -label [_ {Create...}] \
+	.mbar.branch add command -label [_ "Create..."] \
 		-command branch_create::dialog \
 		-accelerator $M1T-N
 	lappend disable_on_lock [list .mbar.branch entryconf \
 		[.mbar.branch index last] -state]
 
-	.mbar.branch add command -label [_ {Checkout...}] \
+	.mbar.branch add command -label [_ "Checkout..."] \
 		-command branch_checkout::dialog \
 		-accelerator $M1T-O
 	lappend disable_on_lock [list .mbar.branch entryconf \
 		[.mbar.branch index last] -state]
 
-	.mbar.branch add command -label [_ {Rename...}] \
+	.mbar.branch add command -label [_ "Rename..."] \
 		-command branch_rename::dialog
 	lappend disable_on_lock [list .mbar.branch entryconf \
 		[.mbar.branch index last] -state]
 
-	.mbar.branch add command -label [_ {Delete...}] \
+	.mbar.branch add command -label [_ "Delete..."] \
 		-command branch_delete::dialog
 	lappend disable_on_lock [list .mbar.branch entryconf \
 		[.mbar.branch index last] -state]
 
-	.mbar.branch add command -label [_ {Reset...}] \
+	.mbar.branch add command -label [_ "Reset..."] \
 		-command merge::reset_hard
 	lappend disable_on_lock [list .mbar.branch entryconf \
 		[.mbar.branch index last] -state]
@@ -1749,7 +1749,7 @@ if {[is_enabled multicommit] || [is_enabled singlecommit]} {
 	menu .mbar.commit
 
 	.mbar.commit add radiobutton \
-		-label [_ {New Commit}] \
+		-label [_ "New Commit"] \
 		-command do_select_commit_type \
 		-variable selected_commit_type \
 		-value new
@@ -1757,7 +1757,7 @@ if {[is_enabled multicommit] || [is_enabled singlecommit]} {
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
 	.mbar.commit add radiobutton \
-		-label [_ {Amend Last Commit}] \
+		-label [_ "Amend Last Commit"] \
 		-command do_select_commit_type \
 		-variable selected_commit_type \
 		-value amend
@@ -1772,30 +1772,30 @@ if {[is_enabled multicommit] || [is_enabled singlecommit]} {
 	lappend disable_on_lock \
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
-	.mbar.commit add command -label [_ {Add To Commit}] \
+	.mbar.commit add command -label [_ "Add To Commit"] \
 		-command do_add_selection
 	lappend disable_on_lock \
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
-	.mbar.commit add command -label [_ {Add Existing To Commit}] \
+	.mbar.commit add command -label [_ "Add Existing To Commit"] \
 		-command do_add_all \
 		-accelerator $M1T-I
 	lappend disable_on_lock \
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
-	.mbar.commit add command -label [_ {Unstage From Commit}] \
+	.mbar.commit add command -label [_ "Unstage From Commit"] \
 		-command do_unstage_selection
 	lappend disable_on_lock \
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
-	.mbar.commit add command -label [_ {Revert Changes}] \
+	.mbar.commit add command -label [_ "Revert Changes"] \
 		-command do_revert_selection
 	lappend disable_on_lock \
 		[list .mbar.commit entryconf [.mbar.commit index last] -state]
 
 	.mbar.commit add separator
 
-	.mbar.commit add command -label [_ {Sign Off}] \
+	.mbar.commit add command -label [_ "Sign Off"] \
 		-command do_signoff \
 		-accelerator $M1T-S
 
@@ -1810,11 +1810,11 @@ if {[is_enabled multicommit] || [is_enabled singlecommit]} {
 #
 if {[is_enabled branch]} {
 	menu .mbar.merge
-	.mbar.merge add command -label [_ {Local Merge...}] \
+	.mbar.merge add command -label [_ "Local Merge..."] \
 		-command merge::dialog
 	lappend disable_on_lock \
 		[list .mbar.merge entryconf [.mbar.merge index last] -state]
-	.mbar.merge add command -label [_ {Abort Merge...}] \
+	.mbar.merge add command -label [_ "Abort Merge..."] \
 		-command merge::reset_hard
 	lappend disable_on_lock \
 		[list .mbar.merge entryconf [.mbar.merge index last] -state]
@@ -1827,10 +1827,10 @@ if {[is_enabled transport]} {
 	menu .mbar.fetch
 
 	menu .mbar.push
-	.mbar.push add command -label [_ {Push...}] \
+	.mbar.push add command -label [_ "Push..."] \
 		-command do_push_anywhere \
 		-accelerator $M1T-P
-	.mbar.push add command -label [_ {Delete...}] \
+	.mbar.push add command -label [_ "Delete..."] \
 		-command remote_branch_delete::dialog
 }
 
@@ -1848,7 +1848,7 @@ if {[is_MacOSX]} {
 	# -- Edit Menu
 	#
 	.mbar.edit add separator
-	.mbar.edit add command -label [_ {Options...}] \
+	.mbar.edit add command -label [_ "Options..."] \
 		-command do_options
 
 	# -- Tools Menu
@@ -1922,7 +1922,7 @@ if {[file isfile $doc_path]} {
 }
 
 if {$browser ne {}} {
-	.mbar.help add command -label [_ {Online Documentation}] \
+	.mbar.help add command -label [_ "Online Documentation"] \
 		-command [list exec $browser $doc_url &]
 }
 unset browser doc_path doc_url
@@ -2167,12 +2167,12 @@ label $ui_coml \
 proc trace_commit_type {varname args} {
 	global ui_coml commit_type
 	switch -glob -- $commit_type {
-	initial       {set txt [_ {Initial Commit Message:}]}
-	amend         {set txt [_ {Amended Commit Message:}]}
-	amend-initial {set txt [_ {Amended Initial Commit Message:}]}
-	amend-merge   {set txt [_ {Amended Merge Commit Message:}]}
-	merge         {set txt [_ {Merge Commit Message:}]}
-	*             {set txt [_ {Commit Message:}]}
+	initial       {set txt [_ "Initial Commit Message:"]}
+	amend         {set txt [_ "Amended Commit Message:"]}
+	amend-initial {set txt [_ "Amended Initial Commit Message:"]}
+	amend-merge   {set txt [_ "Amended Merge Commit Message:"]}
+	merge         {set txt [_ "Merge Commit Message:"]}
+	*             {set txt [_ "Commit Message:"]}
 	}
 	$ui_coml conf -text $txt
 }
@@ -2201,23 +2201,23 @@ pack .vpane.lower.commarea.buffer -side left -fill y
 set ctxm .vpane.lower.commarea.buffer.ctxm
 menu $ctxm -tearoff 0
 $ctxm add command \
-	-label [_ {Cut}] \
+	-label [_ Cut] \
 	-command {tk_textCut $ui_comm}
 $ctxm add command \
-	-label [_ {Copy}] \
+	-label [_ Copy] \
 	-command {tk_textCopy $ui_comm}
 $ctxm add command \
-	-label [_ {Paste}] \
+	-label [_ Paste] \
 	-command {tk_textPaste $ui_comm}
 $ctxm add command \
-	-label [_ {Delete}] \
+	-label [_ Delete] \
 	-command {$ui_comm delete sel.first sel.last}
 $ctxm add separator
 $ctxm add command \
-	-label [_ {Select All}] \
+	-label [_ "Select All"] \
 	-command {focus $ui_comm;$ui_comm tag add sel 0.0 end}
 $ctxm add command \
-	-label [_ {Copy All}] \
+	-label [_ "Copy All"] \
 	-command {
 		$ui_comm tag add sel 0.0 end
 		tk_textCopy $ui_comm
@@ -2225,7 +2225,7 @@ $ctxm add command \
 	}
 $ctxm add separator
 $ctxm add command \
-	-label [_ {Sign Off}] \
+	-label [_ "Sign Off"] \
 	-command do_signoff
 bind_button3 $ui_comm "tk_popup $ctxm %X %Y"
 
@@ -2275,7 +2275,7 @@ pack .vpane.lower.diff.header.path -fill x
 set ctxm .vpane.lower.diff.header.ctxm
 menu $ctxm -tearoff 0
 $ctxm add command \
-	-label [_ {Copy}] \
+	-label [_ Copy] \
 	-command {
 		clipboard clear
 		clipboard append \
@@ -2343,19 +2343,19 @@ $ui_diff tag raise sel
 set ctxm .vpane.lower.diff.body.ctxm
 menu $ctxm -tearoff 0
 $ctxm add command \
-	-label [_ {Refresh}] \
+	-label [_ Refresh] \
 	-command reshow_diff
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add command \
-	-label [_ {Copy}] \
+	-label [_ Copy] \
 	-command {tk_textCopy $ui_diff}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add command \
-	-label [_ {Select All}] \
+	-label [_ "Select All"] \
 	-command {focus $ui_diff;$ui_diff tag add sel 0.0 end}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add command \
-	-label [_ {Copy All}] \
+	-label [_ "Copy All"] \
 	-command {
 		$ui_diff tag add sel 0.0 end
 		tk_textCopy $ui_diff
@@ -2364,36 +2364,36 @@ $ctxm add command \
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add separator
 $ctxm add command \
-	-label [_ {Apply/Reverse Hunk}] \
+	-label [_ "Apply/Reverse Hunk"] \
 	-command {apply_hunk $cursorX $cursorY}
 set ui_diff_applyhunk [$ctxm index last]
 lappend diff_actions [list $ctxm entryconf $ui_diff_applyhunk -state]
 $ctxm add separator
 $ctxm add command \
-	-label [_ {Decrease Font Size}] \
+	-label [_ "Decrease Font Size"] \
 	-command {incr_font_size font_diff -1}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add command \
-	-label [_ {Increase Font Size}] \
+	-label [_ "Increase Font Size"] \
 	-command {incr_font_size font_diff 1}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add separator
 $ctxm add command \
-	-label [_ {Show Less Context}] \
+	-label [_ "Show Less Context"] \
 	-command {if {$repo_config(gui.diffcontext) >= 1} {
 		incr repo_config(gui.diffcontext) -1
 		reshow_diff
 	}}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add command \
-	-label [_ {Show More Context}] \
+	-label [_ "Show More Context"] \
 	-command {if {$repo_config(gui.diffcontext) < 99} {
 		incr repo_config(gui.diffcontext)
 		reshow_diff
 	}}
 lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state]
 $ctxm add separator
-$ctxm add command -label [_ {Options...}] \
+$ctxm add command -label [_ "Options..."] \
 	-command do_options
 bind_button3 $ui_diff "
 	set cursorX %x
-- 
1.5.3.rc2.4.g726f9



>From 9b7ef0f5d5627e65e5ab354cf99c8939770416d9 Mon Sep 17 00:00:00 2001
From: Christian Stimming <stimming@tuhh.de>
Date: Thu, 19 Jul 2007 12:50:19 +0200
Subject: [PATCH] Initial German translation for testing of i18n.

---
 git-gui/po/de.po |  249 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 249 insertions(+), 0 deletions(-)
 create mode 100644 git-gui/po/de.po

diff --git a/git-gui/po/de.po b/git-gui/po/de.po
new file mode 100644
index 0000000..7a74329
--- /dev/null
+++ b/git-gui/po/de.po
@@ -0,0 +1,249 @@
+# Translation of git-gui to German.
+# Copyright (C) 2007 Linux Thorvalds
+# This file is distributed under the same license as the git package.
+# Christian Stimming <stimming@tuhh.de>, 2007
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: git-gui\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2007-07-18 18:27+0200\n"
+"PO-Revision-Date: 2007-07-19 11:45+0200\n"
+"Last-Translator: Christian Stimming <stimming@tuhh.de>\n"
+"Language-Team: German\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: git-gui.sh:1622
+msgid "Repository"
+msgstr ""
+
+#: git-gui.sh:1623
+msgid "Edit"
+msgstr "Bearbeiten"
+
+#: git-gui.sh:1625
+msgid "Branch"
+msgstr ""
+
+#: git-gui.sh:1628 git-gui.sh:1803
+msgid "Commit"
+msgstr ""
+
+#: git-gui.sh:1631
+msgid "Merge"
+msgstr ""
+
+#: git-gui.sh:1632
+msgid "Fetch"
+msgstr ""
+
+#: git-gui.sh:1633
+msgid "Push"
+msgstr ""
+
+#: git-gui.sh:1642
+msgid "Browse Current Branch"
+msgstr ""
+
+#: git-gui.sh:1648
+msgid "Visualize Current Branch"
+msgstr ""
+
+#: git-gui.sh:1652
+msgid "Visualize All Branches"
+msgstr ""
+
+#: git-gui.sh:1657
+msgid "Database Statistics"
+msgstr ""
+
+#: git-gui.sh:1660
+msgid "Compress Database"
+msgstr ""
+
+#: git-gui.sh:1663
+msgid "Verify Database"
+msgstr ""
+
+#: git-gui.sh:1670 git-gui.sh:1674 git-gui.sh:1678
+msgid "Create Desktop Icon"
+msgstr ""
+
+#: git-gui.sh:1683
+msgid "Quit"
+msgstr "Beenden"
+
+#: git-gui.sh:1690
+msgid "Undo"
+msgstr "Rückgängig"
+
+#: git-gui.sh:1693
+msgid "Redo"
+msgstr ""
+
+#: git-gui.sh:1697 git-gui.sh:2205
+msgid "Cut"
+msgstr "Ausschneiden"
+
+#: git-gui.sh:1700 git-gui.sh:2208 git-gui.sh:2279 git-gui.sh:2351
+msgid "Copy"
+msgstr "Kopieren"
+
+#: git-gui.sh:1703 git-gui.sh:2211
+msgid "Paste"
+msgstr "Einfügen"
+
+#: git-gui.sh:1706 git-gui.sh:2214
+msgid "Delete"
+msgstr "Löschen"
+
+#: git-gui.sh:1710 git-gui.sh:2218 git-gui.sh:2355
+msgid "Select All"
+msgstr ""
+
+#: git-gui.sh:1719
+msgid "Create..."
+msgstr ""
+
+#: git-gui.sh:1725
+msgid "Checkout..."
+msgstr ""
+
+#: git-gui.sh:1731
+msgid "Rename..."
+msgstr ""
+
+#: git-gui.sh:1736 git-gui.sh:1834
+msgid "Delete..."
+msgstr "Löschen..."
+
+#: git-gui.sh:1741
+msgid "Reset..."
+msgstr ""
+
+#: git-gui.sh:1753
+msgid "New Commit"
+msgstr ""
+
+#: git-gui.sh:1761
+msgid "Amend Last Commit"
+msgstr ""
+
+#: git-gui.sh:1770
+msgid "Rescan"
+msgstr "Neu laden"
+
+#: git-gui.sh:1776
+msgid "Add To Commit"
+msgstr ""
+
+#: git-gui.sh:1781
+msgid "Add Existing To Commit"
+msgstr ""
+
+#: git-gui.sh:1787
+msgid "Unstage From Commit"
+msgstr ""
+
+#: git-gui.sh:1792
+msgid "Revert Changes"
+msgstr ""
+
+#: git-gui.sh:1799 git-gui.sh:2229
+msgid "Sign Off"
+msgstr ""
+
+#: git-gui.sh:1814
+msgid "Local Merge..."
+msgstr ""
+
+#: git-gui.sh:1818
+msgid "Abort Merge..."
+msgstr ""
+
+#: git-gui.sh:1831
+msgid "Push..."
+msgstr ""
+
+#: git-gui.sh:1841
+msgid "Apple"
+msgstr "Apple"
+
+#: git-gui.sh:1844 git-gui.sh:1889
+#, tcl-format
+msgid "About %s"
+msgstr ""
+
+#: git-gui.sh:1846 git-gui.sh:1852 git-gui.sh:2397
+msgid "Options..."
+msgstr ""
+
+#: git-gui.sh:1874
+msgid "Tools"
+msgstr "Werkzeuge"
+
+#: git-gui.sh:1876
+msgid "Migrate"
+msgstr ""
+
+#: git-gui.sh:1885
+msgid "Help"
+msgstr "Hilfe"
+
+#: git-gui.sh:1926
+msgid "Online Documentation"
+msgstr ""
+
+#: git-gui.sh:2171
+msgid "Initial Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2172
+msgid "Amended Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2173
+msgid "Amended Initial Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2174
+msgid "Amended Merge Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2175
+msgid "Merge Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2176
+msgid "Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2221 git-gui.sh:2359
+msgid "Copy All"
+msgstr "Alle kopieren"
+
+#: git-gui.sh:2347
+msgid "Refresh"
+msgstr "Aktualisieren"
+
+#: git-gui.sh:2368
+msgid "Apply/Reverse Hunk"
+msgstr ""
+
+#: git-gui.sh:2374
+msgid "Decrease Font Size"
+msgstr "Schriftgröße verkleinern"
+
+#: git-gui.sh:2378
+msgid "Increase Font Size"
+msgstr "Schriftgröße vergrößern"
+
+#: git-gui.sh:2383
+msgid "Show Less Context"
+msgstr ""
+
+#: git-gui.sh:2390
+msgid "Show More Context"
+msgstr ""
-- 
1.5.3.rc2.4.g726f9



>From a91dc11906f6ced938dc79bded2fa46fcc147524 Mon Sep 17 00:00:00 2001
From: Christian Stimming <stimming@tuhh.de>
Date: Thu, 19 Jul 2007 12:50:32 +0200
Subject: [PATCH] Makefile rules for message catalog generation and installation.

---
 git-gui/Makefile |   17 ++++++++++++++++-
 1 files changed, 16 insertions(+), 1 deletions(-)

diff --git a/git-gui/Makefile b/git-gui/Makefile
index 1bac6fe..f6a6ce3 100644
--- a/git-gui/Makefile
+++ b/git-gui/Makefile
@@ -103,6 +103,19 @@ $(patsubst %.sh,%,$(SCRIPT_SH)) : % : %.sh
 $(GITGUI_BUILT_INS): git-gui
 	$(QUIET_BUILT_IN)rm -f $@ && ln git-gui $@
 
+XGETTEXT   ?= xgettext
+msgsdir    ?= $(libdir)/msgs
+msgsdir_SQ  = $(subst ','\'',$(msgsdir))
+PO_TEMPLATE = po/git-gui.pot
+ALL_LINGUAS = de
+
+$(PO_TEMPLATE): $(SCRIPT_SH) $(ALL_LIBFILES)
+	$(XGETTEXT) -k_ -LTcl -o $@ $(SCRIPT_SH) $(ALL_LIBFILES)
+update-po:: $(PO_TEMPLATE)
+	( cd po ; for A in *.po ; do echo Updating $${A} ; msgmerge -U $${A} ../$(PO_TEMPLATE) ; done )
+catalogs:: $(PO_TEMPLATE)
+	( cd po ; for A in $(ALL_LINGUAS) ; do echo Generating catalog $${A} ; msgfmt --statistics --tcl $${A}.po -l $${A} -d . ; done )
+
 lib/tclIndex: $(ALL_LIBFILES)
 	$(QUIET_INDEX)if echo \
 	  $(foreach p,$(PRELOAD_FILES),source $p\;) \
@@ -136,7 +149,7 @@ GIT-GUI-VARS: .FORCE-GIT-GUI-VARS
 		echo 1>$@ "$$VARS"; \
 	fi
 
-all:: $(ALL_PROGRAMS) lib/tclIndex
+all:: $(ALL_PROGRAMS) lib/tclIndex catalogs
 
 install: all
 	$(QUIET)$(INSTALL_D0)'$(DESTDIR_SQ)$(gitexecdir_SQ)' $(INSTALL_D1)
@@ -145,6 +158,8 @@ install: all
 	$(QUIET)$(INSTALL_D0)'$(DESTDIR_SQ)$(libdir_SQ)' $(INSTALL_D1)
 	$(QUIET)$(INSTALL_R0)lib/tclIndex $(INSTALL_R1) '$(DESTDIR_SQ)$(libdir_SQ)'
 	$(QUIET)$(foreach p,$(ALL_LIBFILES), $(INSTALL_R0)$p $(INSTALL_R1) '$(DESTDIR_SQ)$(libdir_SQ)' &&) true
+	$(QUIET)$(INSTALL_D0)'$(DESTDIR_SQ)$(msgsdir_SQ)' $(INSTALL_D1)
+	$(QUIET)$(foreach p,$(ALL_LINGUAS), $(INSTALL_R0)po/$p.msg $(INSTALL_R1) '$(DESTDIR_SQ)$(msgsdir_SQ)' &&) true
 
 dist-version:
 	@mkdir -p $(TARDIR)
-- 
1.5.3.rc2.4.g726f9


```

## Johannes Schindelin, 2007-07-19 12:25

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <Pine.LNX.4.64.0707191323510.14781@racer.site>
URL: https://gitlist.dev/e/Pine.LNX.4.64.0707191323510.14781%40racer.site
In-Reply-To: <20070719125657.8utk85ynuow4ow48@webmail.tu-harburg.de>

```
Hi,

On Thu, 19 Jul 2007, Christian Stimming wrote:

> Does this implementation look okay?

This is valuable work, but unfortunately, it does not follow the 
recommendation in Documentation/SubmittingPatches at all.

For starters, please send the patches inlined, one per mail.  And you 
might want to Cc the maintainer of git-gui (Shawn Pearce), too...

Ciao,
Dscho

```

## Shawn O. Pearce, 2007-07-20 04:55

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <20070720045510.GL32566@spearce.org>
URL: https://gitlist.dev/e/20070720045510.GL32566%40spearce.org
In-Reply-To: <Pine.LNX.4.64.0707191323510.14781@racer.site>

```
Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
> On Thu, 19 Jul 2007, Christian Stimming wrote:
> 
> > Does this implementation look okay?
> 
> This is valuable work, but unfortunately, it does not follow the 
> recommendation in Documentation/SubmittingPatches at all.
> 
> For starters, please send the patches inlined, one per mail.  And you 
> might want to Cc the maintainer of git-gui (Shawn Pearce), too...

I agree that internationalization of git-gui is worth doing.
I've thought about working on it, but haven't yet because nobody
else has seemed interested in having it done.  Apparently someone
is, so patches towards that end are most welcome.

-- 
Shawn.

```

## Paolo Ciarrocchi, 2007-07-20 17:32

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <4d8e3fd30707201032m1f9a0fe2jc74d2bea6c55f6ab@mail.gmail.com>
URL: https://gitlist.dev/e/4d8e3fd30707201032m1f9a0fe2jc74d2bea6c55f6ab%40mail.gmail.com
In-Reply-To: <20070720045510.GL32566@spearce.org>

```
On 7/20/07, Shawn O. Pearce <spearce@spearce.org> wrote:
> Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
> > On Thu, 19 Jul 2007, Christian Stimming wrote:
> >
> > > Does this implementation look okay?
> >
> > This is valuable work, but unfortunately, it does not follow the
> > recommendation in Documentation/SubmittingPatches at all.
> >
> > For starters, please send the patches inlined, one per mail.  And you
> > might want to Cc the maintainer of git-gui (Shawn Pearce), too...
>
> I agree that internationalization of git-gui is worth doing.
> I've thought about working on it, but haven't yet because nobody
> else has seemed interested in having it done.  Apparently someone
> is, so patches towards that end are most welcome.

Hi Shawn,
I volunteer to translate all the git-gui messages in Italian.

Just let me if you are interested and please give me an hint on how to
produce the translation so that you can incorporate it.

Thanks.

Regards,

-- 
Paolo
"Tutto cio' che merita di essere fatto,merita di essere fatto bene"
Philip Stanhope IV conte di Chesterfield

```

## Junio C Hamano, 2007-07-20 18:10

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <7vodi7vtct.fsf@assigned-by-dhcp.cox.net>
URL: https://gitlist.dev/e/7vodi7vtct.fsf%40assigned-by-dhcp.cox.net
In-Reply-To: <4d8e3fd30707201032m1f9a0fe2jc74d2bea6c55f6ab@mail.gmail.com>

```
"Paolo Ciarrocchi" <paolo.ciarrocchi@gmail.com> writes:

> I volunteer to translate all the git-gui messages in Italian.
>
> Just let me if you are interested and please give me an hint on how to
> produce the translation so that you can incorporate it.

Ah, am I expected to volunteer for Japanese part?

Unless yashi, yoshifuji, or nanako3 volunteer, although I do not
mind doing that myself, that is (if there are any Japanese
people I forgot, I apologize).  I wonder how many people outside
English zone are regularly on the list...

```

## Johannes Schindelin, 2007-07-20 18:38

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <Pine.LNX.4.64.0707201937080.14781@racer.site>
URL: https://gitlist.dev/e/Pine.LNX.4.64.0707201937080.14781%40racer.site
In-Reply-To: <7vodi7vtct.fsf@assigned-by-dhcp.cox.net>

```
Hi,

On Fri, 20 Jul 2007, Junio C Hamano wrote:

> "Paolo Ciarrocchi" <paolo.ciarrocchi@gmail.com> writes:
> 
> > I volunteer to translate all the git-gui messages in Italian.
> >
> > Just let me if you are interested and please give me an hint on how to
> > produce the translation so that you can incorporate it.
> 
> Ah, am I expected to volunteer for Japanese part?
> 
> Unless yashi, yoshifuji, or nanako3 volunteer, although I do not
> mind doing that myself, that is (if there are any Japanese
> people I forgot, I apologize).

According to http://en.wikipedia.org/wiki/Japan, you forgot roughly 
127,433,490 people ;-)

> I wonder how many people outside English zone are regularly on the 
> list...

Here is one, but Christian already volunteered for the German part, I 
understand...

Ciao,
Dscho

```

## Paolo Ciarrocchi, 2007-07-20 18:47

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <4d8e3fd30707201147l1f1797f8vefc712b2d3ae0f19@mail.gmail.com>
URL: https://gitlist.dev/e/4d8e3fd30707201147l1f1797f8vefc712b2d3ae0f19%40mail.gmail.com
In-Reply-To: <Pine.LNX.4.64.0707201937080.14781@racer.site>

```
On 7/20/07, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
[...]
> > I wonder how many people outside English zone are regularly on the
> > list...

I tried to verify the results of the survey I sent out last year:
    http://git.or.cz/gitwiki/GitSurvey
unfortunately that page seems to be full of spam.

Ciao,
-- 
Paolo

```

## Sam Ravnborg, 2007-07-20 19:02

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <20070720190209.GA22964@uranus.ravnborg.org>
URL: https://gitlist.dev/e/20070720190209.GA22964%40uranus.ravnborg.org
In-Reply-To: <7vodi7vtct.fsf@assigned-by-dhcp.cox.net>

```
On Fri, Jul 20, 2007 at 11:10:42AM -0700, Junio C Hamano wrote:
> I wonder how many people outside
> English zone are regularly on the list...

>From a scandinavian country (Denmark) but really I would never use
a translated version. So some decent amount of pressure would
be needed to convince me to add danish :-)

	Sam

```

## Johannes Schindelin, 2007-07-20 19:06

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <Pine.LNX.4.64.0707202005090.14781@racer.site>
URL: https://gitlist.dev/e/Pine.LNX.4.64.0707202005090.14781%40racer.site
In-Reply-To: <4d8e3fd30707201147l1f1797f8vefc712b2d3ae0f19@mail.gmail.com>

```
Hi,

On Fri, 20 Jul 2007, Paolo Ciarrocchi wrote:

> On 7/20/07, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
> [...]
> > > I wonder how many people outside English zone are regularly on the
> > > list...
> 
> I tried to verify the results of the survey I sent out last year:
>    http://git.or.cz/gitwiki/GitSurvey
> unfortunately that page seems to be full of spam.

No longer.  FWIW you can do it yourself: if you are logged in, there is a 
"restore" link to the far right on the "Info" page of every wiki page.

Hth,
Dscho

```

## Xudong Guan, 2007-07-20 19:16

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <20070720191650.GA7334@xguan-laptop>
URL: https://gitlist.dev/e/20070720191650.GA7334%40xguan-laptop
In-Reply-To: <7vodi7vtct.fsf@assigned-by-dhcp.cox.net>

```
On 11:10 Fri 20 Jul     , Junio C Hamano wrote:
> I wonder how many people outside
> English zone are regularly on the list...

I am a Chinese, subscribed today.

Xudong

```

## しらいしななこ, 2007-07-21 08:12

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <200707210815.l6L8F2Da032066@mi0.bluebottle.com>
URL: https://gitlist.dev/e/200707210815.l6L8F2Da032066%40mi0.bluebottle.com
In-Reply-To: <7vodi7vtct.fsf@assigned-by-dhcp.cox.net>

```
Quoting Junio C Hamano <gitster@pobox.com>:

> "Paolo Ciarrocchi" <paolo.ciarrocchi@gmail.com> writes:
>
>> I volunteer to translate all the git-gui messages in Italian.
>>
>> Just let me if you are interested and please give me an hint on how to
>> produce the translation so that you can incorporate it.
>
> Ah, am I expected to volunteer for Japanese part?
>
> Unless yashi, yoshifuji, or nanako3 volunteer, although I do not
> mind doing that myself, that is (if there are any Japanese
> people I forgot, I apologize).  I wonder how many people outside
> English zone are regularly on the list...

I can help.  What's involved?

-- 
Nanako Shiraishi
http://ivory.ap.teacup.com/nanako3/

----------------------------------------------------------------------
Free pop3 email with a spam filter.
http://www.bluebottle.com/tag/5

```

## Junio C Hamano, 2007-07-21 08:22

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <7vr6n2upwv.fsf@assigned-by-dhcp.cox.net>
URL: https://gitlist.dev/e/7vr6n2upwv.fsf%40assigned-by-dhcp.cox.net
In-Reply-To: <200707210815.l6L8F2Da032066@mi0.bluebottle.com>

```
しらいしななこ  <nanako3@bluebottle.com> writes:

> Quoting Junio C Hamano <gitster@pobox.com>:
>
>> Ah, am I expected to volunteer for Japanese part?
>>
>> Unless yashi, yoshifuji, or nanako3 volunteer, although I do not
>> mind doing that myself,...
>
> I can help.  What's involved?

Wonderful.

As Johannes announced the 'mob' stuff, I think it would be
easiest to work there as others --- for this type of work, there
probably won't be much stepping on each other's toes involved as
long as there are not more than one translator per language.

What's involved to get a new language 'xy' started is roughly:

 - Run 'make' once, to get po/git-gui.pot generated;

 - Copy po/git-gui.pot to po/xy.po;

 - Update the placeholder strings at the beginning of the
   po/xy.po file appropriately.

 - Add 'xy' to the list of languages to ALL_LINGUAS list in the
   Makefile.

After that, add translations to the (initially empty) string on
the lines that begin with 'msgstr'.  Set of msgid's need to be
kept in sync with the source as the translated software evolve,
but gettext framework hopefully will take care of most of the
chore.

I'll get on the 'mob' bandwagon and try to push out something
like the attached patch, so that you do not necessarily have to
have the whole gettext toolchain.

-- >8 --

This gets the ball started for Japanese translation, but as I am
lazy, I only translated three words.  I took credit by placing
my name on the "Last-Translator" line, but shifted most of the
remaining work to Nana, who showed interest on the list, by
naming her at the beginnign of the file ;-)

Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
 Makefile |    2 +-
 po/ja.po |  250 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 251 insertions(+), 1 deletions(-)
 create mode 100644 po/ja.po

diff --git a/Makefile b/Makefile
index f6a6ce3..85d2c00 100644
--- a/Makefile
+++ b/Makefile
@@ -107,7 +107,7 @@ XGETTEXT   ?= xgettext
 msgsdir    ?= $(libdir)/msgs
 msgsdir_SQ  = $(subst ','\'',$(msgsdir))
 PO_TEMPLATE = po/git-gui.pot
-ALL_LINGUAS = de
+ALL_LINGUAS = de ja
 
 $(PO_TEMPLATE): $(SCRIPT_SH) $(ALL_LIBFILES)
 	$(XGETTEXT) -k_ -LTcl -o $@ $(SCRIPT_SH) $(ALL_LIBFILES)
diff --git a/po/ja.po b/po/ja.po
new file mode 100644
index 0000000..abfd4f1
--- /dev/null
+++ b/po/ja.po
@@ -0,0 +1,250 @@
+# Translation of git-gui to Japanese
+# Copyright (C) 2007 Shawn Pearce
+# This file is distributed under the same license as the git-gui package.
+# しらいし ななこ <nanako3@bluebottle.com>, 2007.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: git-gui\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2007-07-21 01:23-0700\n"
+"PO-Revision-Date: 2007-07-21 01:23-0700\n"
+"Last-Translator: Junio C Hamano <gitster@pobox.com>\n"
+"Language-Team: Japanese\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: git-gui.sh:1656
+msgid "Repository"
+msgstr "レポジトリ"
+
+#: git-gui.sh:1657
+msgid "Edit"
+msgstr "編集"
+
+#: git-gui.sh:1659
+msgid "Branch"
+msgstr "分岐"
+
+#: git-gui.sh:1662 git-gui.sh:1840
+msgid "Commit"
+msgstr ""
+
+#: git-gui.sh:1665
+msgid "Merge"
+msgstr ""
+
+#: git-gui.sh:1666
+msgid "Fetch"
+msgstr ""
+
+#: git-gui.sh:1667
+msgid "Push"
+msgstr ""
+
+#: git-gui.sh:1676
+msgid "Browse Current Branch's Files"
+msgstr ""
+
+#: git-gui.sh:1685
+msgid "Visualize Current Branch's History"
+msgstr ""
+
+#: git-gui.sh:1689
+msgid "Visualize All Branch History"
+msgstr ""
+
+#: git-gui.sh:1694
+msgid "Database Statistics"
+msgstr ""
+
+#: git-gui.sh:1697
+msgid "Compress Database"
+msgstr ""
+
+#: git-gui.sh:1700
+msgid "Verify Database"
+msgstr ""
+
+#: git-gui.sh:1707 git-gui.sh:1711 git-gui.sh:1715
+msgid "Create Desktop Icon"
+msgstr ""
+
+#: git-gui.sh:1720
+msgid "Quit"
+msgstr ""
+
+#: git-gui.sh:1727
+msgid "Undo"
+msgstr ""
+
+#: git-gui.sh:1730
+msgid "Redo"
+msgstr ""
+
+#: git-gui.sh:1734 git-gui.sh:2249
+msgid "Cut"
+msgstr ""
+
+#: git-gui.sh:1737 git-gui.sh:2252 git-gui.sh:2323 git-gui.sh:2395
+msgid "Copy"
+msgstr ""
+
+#: git-gui.sh:1740 git-gui.sh:2255
+msgid "Paste"
+msgstr ""
+
+#: git-gui.sh:1743 git-gui.sh:2258
+msgid "Delete"
+msgstr ""
+
+#: git-gui.sh:1747 git-gui.sh:2262 git-gui.sh:2399
+msgid "Select All"
+msgstr ""
+
+#: git-gui.sh:1756
+msgid "Create..."
+msgstr ""
+
+#: git-gui.sh:1762
+msgid "Checkout..."
+msgstr ""
+
+#: git-gui.sh:1768
+msgid "Rename..."
+msgstr ""
+
+#: git-gui.sh:1773 git-gui.sh:1871
+msgid "Delete..."
+msgstr ""
+
+#: git-gui.sh:1778
+msgid "Reset..."
+msgstr ""
+
+#: git-gui.sh:1790
+msgid "New Commit"
+msgstr ""
+
+#: git-gui.sh:1798
+msgid "Amend Last Commit"
+msgstr ""
+
+#: git-gui.sh:1807
+msgid "Rescan"
+msgstr ""
+
+#: git-gui.sh:1813
+msgid "Add To Commit"
+msgstr ""
+
+#: git-gui.sh:1818
+msgid "Add Existing To Commit"
+msgstr ""
+
+#: git-gui.sh:1824
+msgid "Unstage From Commit"
+msgstr ""
+
+#: git-gui.sh:1829
+msgid "Revert Changes"
+msgstr ""
+
+#: git-gui.sh:1836 git-gui.sh:2273
+msgid "Sign Off"
+msgstr ""
+
+#: git-gui.sh:1851
+msgid "Local Merge..."
+msgstr ""
+
+#: git-gui.sh:1856
+msgid "Abort Merge..."
+msgstr ""
+
+#: git-gui.sh:1868
+msgid "Push..."
+msgstr ""
+
+#: git-gui.sh:1878
+msgid "Apple"
+msgstr ""
+
+#: git-gui.sh:1881 git-gui.sh:1928
+#, tcl-format
+msgid "About %s"
+msgstr ""
+
+#: git-gui.sh:1883 git-gui.sh:1889 git-gui.sh:2441
+msgid "Options..."
+msgstr ""
+
+#: git-gui.sh:1913
+msgid "Tools"
+msgstr ""
+
+#: git-gui.sh:1915
+msgid "Migrate"
+msgstr ""
+
+#: git-gui.sh:1924
+msgid "Help"
+msgstr ""
+
+#: git-gui.sh:1965
+msgid "Online Documentation"
+msgstr ""
+
+#: git-gui.sh:2215
+msgid "Initial Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2216
+msgid "Amended Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2217
+msgid "Amended Initial Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2218
+msgid "Amended Merge Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2219
+msgid "Merge Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2220
+msgid "Commit Message:"
+msgstr ""
+
+#: git-gui.sh:2265 git-gui.sh:2403
+msgid "Copy All"
+msgstr ""
+
+#: git-gui.sh:2391
+msgid "Refresh"
+msgstr ""
+
+#: git-gui.sh:2412
+msgid "Apply/Reverse Hunk"
+msgstr ""
+
+#: git-gui.sh:2418
+msgid "Decrease Font Size"
+msgstr ""
+
+#: git-gui.sh:2422
+msgid "Increase Font Size"
+msgstr ""
+
+#: git-gui.sh:2427
+msgid "Show Less Context"
+msgstr ""
+
+#: git-gui.sh:2434
+msgid "Show More Context"
+msgstr ""
-- 
1.5.3.rc2.22.g69a9b

```

## Johannes Schindelin, 2007-07-21 13:21

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <Pine.LNX.4.64.0707211415500.14781@racer.site>
URL: https://gitlist.dev/e/Pine.LNX.4.64.0707211415500.14781%40racer.site
In-Reply-To: <7vr6n2upwv.fsf@assigned-by-dhcp.cox.net>

```
Hi,

On Sat, 21 Jul 2007, Junio C Hamano wrote:

> As Johannes announced the 'mob' stuff, I think it would be easiest to 
> work there as others --- for this type of work, there probably won't be 
> much stepping on each other's toes involved as long as there are not 
> more than one translator per language.

Already merged into git-gui-i18n's master.

Ciao,
Dscho

```

## Paolo Ciarrocchi, 2007-07-21 18:57

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <4d8e3fd30707211157l1be243basfb259082b7aa8160@mail.gmail.com>
URL: https://gitlist.dev/e/4d8e3fd30707211157l1be243basfb259082b7aa8160%40mail.gmail.com
In-Reply-To: <7vr6n2upwv.fsf@assigned-by-dhcp.cox.net>

```
On 7/21/07, Junio C Hamano <gitster@pobox.com> wrote:

paolo@paolo-desktop:~/git-gui-i18n$ ls
git-gui.sh  GIT-VERSION-GEN  lib  Makefile  po


>  - Run 'make' once, to get po/git-gui.pot generated;

paolo@paolo-desktop:~/git-gui-i18n$ make
GITGUI_VERSION = 0.8.GITGUI
    * new locations or Tcl/Tk interpreter
    GEN git-gui
    BUILTIN git-citool
    INDEX lib/

paolo@paolo-desktop:~/git-gui-i18n$ ls po/
de.msg  de.po  glossary.csv  ja.msg  ja.po

There is "po/git-gui.pot" file in my repository.

Am I doing something wrong?

Thanks!

Ciao,
-- 
Paolo
"Tutto cio' che merita di essere fatto,merita di essere fatto bene"
Philip Stanhope IV conte di Chesterfield

```

## Johannes Schindelin, 2007-07-21 21:25

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <Pine.LNX.4.64.0707212224480.14781@racer.site>
URL: https://gitlist.dev/e/Pine.LNX.4.64.0707212224480.14781%40racer.site
In-Reply-To: <4d8e3fd30707211157l1be243basfb259082b7aa8160@mail.gmail.com>

```
Hi,

On Sat, 21 Jul 2007, Paolo Ciarrocchi wrote:

> On 7/21/07, Junio C Hamano <gitster@pobox.com> wrote:
> 
> paolo@paolo-desktop:~/git-gui-i18n$ ls
> git-gui.sh  GIT-VERSION-GEN  lib  Makefile  po
> 
> 
> >  - Run 'make' once, to get po/git-gui.pot generated;
> 
> paolo@paolo-desktop:~/git-gui-i18n$ make
> GITGUI_VERSION = 0.8.GITGUI
>    * new locations or Tcl/Tk interpreter
>    GEN git-gui
>    BUILTIN git-citool
>    INDEX lib/
> 
> paolo@paolo-desktop:~/git-gui-i18n$ ls po/
> de.msg  de.po  glossary.csv  ja.msg  ja.po
> 
> There is "po/git-gui.pot" file in my repository.

My fault.  I was rebasing Junio's patch on top of Christian's new series.  
Alas, the PO_TEMPLATE was no longer created by default.

Should be fixed now.

Thanks,
Dscho

```

## Junio C Hamano, 2007-07-21 22:57

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <7vvecdtlf1.fsf@assigned-by-dhcp.cox.net>
URL: https://gitlist.dev/e/7vvecdtlf1.fsf%40assigned-by-dhcp.cox.net
In-Reply-To: <Pine.LNX.4.64.0707212224480.14781@racer.site>

```
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:

>> paolo@paolo-desktop:~/git-gui-i18n$ ls po/
>> de.msg  de.po  glossary.csv  ja.msg  ja.po
>> 
>> There is "po/git-gui.pot" file in my repository.
>
> My fault.  I was rebasing Junio's patch on top of Christian's new series.  
> Alas, the PO_TEMPLATE was no longer created by default.
>
> Should be fixed now.

Note that if everybody agrees that the division of labor between
the developer, the i18n coordinator and translators I suggested
in the earlier message is the way to go, po/git-gui.pot should
be managed by the i18n coordinator and revision tracked in-tree.
Simple "make" should not try to update it for ordinary people,
but we can have a "i18n coordinator only" maintenance target to
update it.

That way, translators do not have to touch anything other than
their own po/xx.po files.

```

## Johannes Schindelin, 2007-07-22 01:12

Subject: Re: [PATCH] Internationalization of git-gui
Message-ID: <Pine.LNX.4.64.0707220212280.14781@racer.site>
URL: https://gitlist.dev/e/Pine.LNX.4.64.0707220212280.14781%40racer.site
In-Reply-To: <7vvecdtlf1.fsf@assigned-by-dhcp.cox.net>

```
Hi,

On Sat, 21 Jul 2007, Junio C Hamano wrote:

> Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
> 
> >> paolo@paolo-desktop:~/git-gui-i18n$ ls po/
> >> de.msg  de.po  glossary.csv  ja.msg  ja.po
> >> 
> >> There is "po/git-gui.pot" file in my repository.
> >
> > My fault.  I was rebasing Junio's patch on top of Christian's new series.  
> > Alas, the PO_TEMPLATE was no longer created by default.
> >
> > Should be fixed now.
> 
> Note that if everybody agrees that the division of labor between
> the developer, the i18n coordinator and translators I suggested
> in the earlier message is the way to go, po/git-gui.pot should
> be managed by the i18n coordinator and revision tracked in-tree.
> Simple "make" should not try to update it for ordinary people,
> but we can have a "i18n coordinator only" maintenance target to
> update it.
> 
> That way, translators do not have to touch anything other than
> their own po/xx.po files.

Done.

Ciao,
Dscho

```
