From 66e15a6b83a0b79232377137cc1710343a81aea4 Mon Sep 17 00:00:00 2001 From: Charles Bailey <charles@hashpling.org> Date: Wed, 9 Jan 2008 14:31:09 +0000 Subject: [PATCH 1/9] gitk: Fix the Makefile to cope with systems lacking msgfmt The po2msg.sh script and the .gitignore in the po directory have been shamelessly copied from the current git-gui. This enables the top level "make NO_MSGFMT" to work consistently for git across the git-gui and gitk sub-projects. This is the same effective patch that has previously been posted as a git.git patch which more succinctly described the copying of po/.gitignore and po/po2msg.sh from git-gui. Signed-off-by: Charles Bailey <charles@hashpling.org> Signed-off-by: Junio C Hamano <gitster@pobox.com> --- Makefile | 7 ++- po/.gitignore | 1 + po/po2msg.sh | 133 ++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 140 insertions(+), 1 deletion(-) create mode 100644 po/.gitignore create mode 100644 po/po2msg.sh diff --git a/Makefile b/Makefile index 61585045b76..ae2b80b1083 100644 --- a/Makefile +++ b/Makefile @@ -18,7 +18,12 @@ TCLTK_PATH_SQ = $(subst ','\'',$(TCLTK_PATH)) ## po-file creation rules XGETTEXT ?= xgettext -MSGFMT ?= msgfmt +ifdef NO_MSGFMT + MSGFMT ?= $(TCL_PATH) po/po2msg.sh +else + MSGFMT ?= msgfmt +endif + PO_TEMPLATE = po/gitk.pot ALL_POFILES = $(wildcard po/*.po) ALL_MSGFILES = $(subst .po,.msg,$(ALL_POFILES)) diff --git a/po/.gitignore b/po/.gitignore new file mode 100644 index 00000000000..e358dd19033 --- /dev/null +++ b/po/.gitignore @@ -0,0 +1 @@ +*.msg diff --git a/po/po2msg.sh b/po/po2msg.sh new file mode 100644 index 00000000000..c63248e3752 --- /dev/null +++ b/po/po2msg.sh @@ -0,0 +1,133 @@ +#!/bin/sh +# Tcl ignores the next line -*- tcl -*- \ +exec tclsh "$0" -- "$@" + +# This is a really stupid program, which serves as an alternative to +# msgfmt. It _only_ translates to Tcl mode, does _not_ validate the +# input, and does _not_ output any statistics. + +proc u2a {s} { + set res "" + foreach i [split $s ""] { + scan $i %c c + if {$c<128} { + # escape '[', '\' and ']' + if {$c == 0x5b || $c == 0x5d} { + append res "\\" + } + append res $i + } else { + append res \\u[format %04.4x $c] + } + } + return $res +} + +set output_directory "." +set lang "dummy" +set files [list] +set show_statistics 0 + +# parse options +for {set i 0} {$i < $argc} {incr i} { + set arg [lindex $argv $i] + if {$arg == "--statistics"} { + incr show_statistics + continue + } + if {$arg == "--tcl"} { + # we know + continue + } + if {$arg == "-l"} { + incr i + set lang [lindex $argv $i] + continue + } + if {$arg == "-d"} { + incr i + set tmp [lindex $argv $i] + regsub "\[^/\]$" $tmp "&/" output_directory + continue + } + lappend files $arg +} + +proc flush_msg {} { + global msgid msgstr mode lang out fuzzy + global translated_count fuzzy_count not_translated_count + + if {![info exists msgid] || $mode == ""} { + return + } + set mode "" + if {$fuzzy == 1} { + incr fuzzy_count + set fuzzy 0 + return + } + + if {$msgid == ""} { + set prefix "set ::msgcat::header" + } else { + if {$msgstr == ""} { + incr not_translated_count + return + } + set prefix "::msgcat::mcset $lang \"[u2a $msgid]\"" + incr translated_count + } + + puts $out "$prefix \"[u2a $msgstr]\"" +} + +set fuzzy 0 +set translated_count 0 +set fuzzy_count 0 +set not_translated_count 0 +foreach file $files { + regsub "^.*/\(\[^/\]*\)\.po$" $file "$output_directory\\1.msg" outfile + set in [open $file "r"] + fconfigure $in -encoding utf-8 + set out [open $outfile "w"] + + set mode "" + while {[gets $in line] >= 0} { + if {[regexp "^#" $line]} { + if {[regexp ", fuzzy" $line]} { + set fuzzy 1 + } else { + flush_msg + } + continue + } elseif {[regexp "^msgid \"(.*)\"$" $line dummy match]} { + flush_msg + set msgid $match + set mode "msgid" + } elseif {[regexp "^msgstr \"(.*)\"$" $line dummy match]} { + set msgstr $match + set mode "msgstr" + } elseif {$line == ""} { + flush_msg + } elseif {[regexp "^\"(.*)\"$" $line dummy match]} { + if {$mode == "msgid"} { + append msgid $match + } elseif {$mode == "msgstr"} { + append msgstr $match + } else { + puts stderr "I do not know what to do: $match" + } + } else { + puts stderr "Cannot handle $line" + } + } + flush_msg + close $in + close $out +} + +if {$show_statistics} { + puts [concat "$translated_count translated messages, " \ + "$fuzzy_count fuzzy ones, " \ + "$not_translated_count untranslated ones."] +} From 55e34436e1da167a2abf276e31ef27d3b1e1208b Mon Sep 17 00:00:00 2001 From: Christian Stimming <stimming@tuhh.de> Date: Wed, 9 Jan 2008 22:23:18 +0100 Subject: [PATCH 2/9] gitk: Fix typo in user message. Signed-off-by: Christian Stimming <stimming@tuhh.de> Signed-off-by: Junio C Hamano <gitster@pobox.com> --- gitk | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gitk b/gitk index 801a5a9d86d..b3cb8e8b7e6 100755 --- a/gitk +++ b/gitk @@ -2629,12 +2629,12 @@ proc askrelhighlight {row id} { if {![info exists selectedline]} return set isbold 0 - if {$highlight_related eq [mc "Descendent"] || - $highlight_related eq [mc "Not descendent"]} { + if {$highlight_related eq [mc "Descendant"] || + $highlight_related eq [mc "Not descendant"]} { if {![info exists descendent($id)]} { is_descendent $id } - if {$descendent($id) == ($highlight_related eq [mc "Descendent"])} { + if {$descendent($id) == ($highlight_related eq [mc "Descendant"])} { set isbold 1 } } elseif {$highlight_related eq [mc "Ancestor"] || From 7d8856d091d3fd098643acb6157dfed376eddaea Mon Sep 17 00:00:00 2001 From: Christian Stimming <stimming@tuhh.de> Date: Wed, 9 Jan 2008 22:21:58 +0100 Subject: [PATCH 3/9] gitk: Update German translation. Now 100% complete (163 strings). Signed-off-by: Christian Stimming <stimming@tuhh.de> Signed-off-by: Junio C Hamano <gitster@pobox.com> --- po/de.po | 422 +++++++++++++++++++++++++++++-------------------------- 1 file changed, 222 insertions(+), 200 deletions(-) diff --git a/po/de.po b/po/de.po index d7881dd1212..5ee2fca8b26 100644 --- a/po/de.po +++ b/po/de.po @@ -7,8 +7,8 @@ msgid "" msgstr "" "Project-Id-Version: git-gui\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2007-12-21 12:04+0100\n" -"PO-Revision-Date: 2008-01-08 21:48+0100\n" +"POT-Creation-Date: 2008-01-09 22:20+0100\n" +"PO-Revision-Date: 2008-01-09 22:21+0100\n" "Last-Translator: Christian Stimming <stimming@tuhh.de>\n" "Language-Team: German\n" "MIME-Version: 1.0\n" @@ -17,13 +17,13 @@ msgstr "" #: gitk:101 msgid "Error executing git rev-list:" -msgstr "" +msgstr "Fehler beim Ausführen von git-rev-list:" #: gitk:114 msgid "Reading" msgstr "Lesen" -#: gitk:141 gitk:2151 +#: gitk:141 gitk:2143 msgid "Reading commits..." msgstr "Versionen lesen..." @@ -31,197 +31,197 @@ msgstr "Versionen lesen..." msgid "Can't parse git log output:" msgstr "Git log Ausgabe kann nicht erkannt werden:" -#: gitk:375 gitk:2155 +#: gitk:375 gitk:2147 msgid "No commits selected" msgstr "Keine Versionen ausgewählt." #: gitk:486 msgid "No commit information available" -msgstr "" +msgstr "Keine Versionsinformation verfügbar" -#: gitk:585 gitk:607 gitk:1914 gitk:6374 gitk:7875 gitk:8035 +#: gitk:585 gitk:607 gitk:1908 gitk:6366 gitk:7866 gitk:8020 msgid "OK" msgstr "Ok" -#: gitk:609 gitk:1916 gitk:6054 gitk:6125 gitk:6226 gitk:6272 gitk:6376 -#: gitk:7877 gitk:8037 +#: gitk:609 gitk:1909 gitk:6046 gitk:6117 gitk:6218 gitk:6264 gitk:6368 +#: gitk:7867 gitk:8021 msgid "Cancel" msgstr "Abbrechen" -#: gitk:633 +#: gitk:646 msgid "File" msgstr "Datei" -#: gitk:636 +#: gitk:648 msgid "Update" msgstr "Aktualisieren" -#: gitk:637 +#: gitk:649 msgid "Reread references" msgstr "Zweige neu laden" -#: gitk:638 +#: gitk:650 msgid "List references" msgstr "Zweige auflisten" -#: gitk:639 +#: gitk:651 msgid "Quit" msgstr "Beenden" -#: gitk:642 +#: gitk:653 msgid "Edit" msgstr "Bearbeiten" -#: gitk:643 +#: gitk:654 msgid "Preferences" msgstr "Einstellungen" -#: gitk:647 +#: gitk:657 msgid "View" msgstr "Ansicht" -#: gitk:648 +#: gitk:658 msgid "New view..." msgstr "Neue Ansicht..." -#: gitk:649 gitk:2093 gitk:8666 +#: gitk:659 gitk:2085 gitk:8651 msgid "Edit view..." msgstr "Ansicht bearbeiten..." -#: gitk:651 gitk:2094 gitk:8667 +#: gitk:661 gitk:2086 gitk:8652 msgid "Delete view" msgstr "Ansicht löschen" -#: gitk:653 +#: gitk:663 msgid "All files" msgstr "Alle Dateien" -#: gitk:657 +#: gitk:667 msgid "Help" msgstr "Hilfe" -#: gitk:658 gitk:1280 +#: gitk:668 gitk:1280 msgid "About gitk" msgstr "Über gitk" -#: gitk:659 +#: gitk:669 msgid "Key bindings" msgstr "Tastenkürzel" -#: gitk:716 +#: gitk:726 msgid "SHA1 ID: " -msgstr "" +msgstr "SHA1:" -#: gitk:766 +#: gitk:776 msgid "Find" msgstr "Suche" -#: gitk:767 +#: gitk:777 msgid "next" msgstr "nächste" -#: gitk:768 +#: gitk:778 msgid "prev" msgstr "vorige" -#: gitk:769 +#: gitk:779 msgid "commit" msgstr "Version" -#: gitk:772 gitk:774 gitk:2316 gitk:2339 gitk:2363 gitk:4265 gitk:4328 +#: gitk:782 gitk:784 gitk:2308 gitk:2331 gitk:2355 gitk:4257 gitk:4320 msgid "containing:" msgstr "enthaltend:" -#: gitk:775 gitk:1746 gitk:1751 gitk:2391 +#: gitk:785 gitk:1741 gitk:1746 gitk:2383 msgid "touching paths:" msgstr "Pfad betreffend:" -#: gitk:776 gitk:2396 +#: gitk:786 gitk:2388 msgid "adding/removing string:" msgstr "String dazu/löschen:" -#: gitk:787 gitk:789 +#: gitk:795 gitk:797 msgid "Exact" msgstr "Exakt" -#: gitk:789 gitk:2474 gitk:4233 +#: gitk:797 gitk:2466 gitk:4225 msgid "IgnCase" msgstr "Kein Groß/Klein" -#: gitk:789 gitk:2365 gitk:2472 gitk:4229 +#: gitk:797 gitk:2357 gitk:2464 gitk:4221 msgid "Regexp" msgstr "Regexp" -#: gitk:793 gitk:794 gitk:2493 gitk:2523 gitk:2530 gitk:4339 gitk:4395 +#: gitk:799 gitk:800 gitk:2485 gitk:2515 gitk:2522 gitk:4331 gitk:4387 msgid "All fields" msgstr "Alle Felder" -#: gitk:794 gitk:2491 gitk:2523 gitk:4295 +#: gitk:800 gitk:2483 gitk:2515 gitk:4287 msgid "Headline" msgstr "Überschrift" -#: gitk:795 gitk:2491 gitk:4295 gitk:4395 gitk:4783 +#: gitk:801 gitk:2483 gitk:4287 gitk:4387 gitk:4775 msgid "Comments" msgstr "Beschreibung" -#: gitk:795 gitk:2491 gitk:2495 gitk:2530 gitk:4295 gitk:4719 gitk:5903 -#: gitk:5918 +#: gitk:801 gitk:2483 gitk:2487 gitk:2522 gitk:4287 gitk:4711 gitk:5895 +#: gitk:5910 msgid "Author" msgstr "Autor" -#: gitk:795 gitk:2491 gitk:4295 gitk:4721 +#: gitk:801 gitk:2483 gitk:4287 gitk:4713 msgid "Committer" msgstr "Eintragender" -#: gitk:825 +#: gitk:829 msgid "Search" msgstr "Suche" -#: gitk:833 +#: gitk:836 msgid "Diff" msgstr "Vergleich" -#: gitk:835 +#: gitk:838 msgid "Old version" msgstr "Alte Version" -#: gitk:837 +#: gitk:840 msgid "New version" msgstr "Neue Version" -#: gitk:839 +#: gitk:842 msgid "Lines of context" msgstr "Kontextzeilen" -#: gitk:898 +#: gitk:900 msgid "Patch" -msgstr "" +msgstr "Patch" -#: gitk:901 +#: gitk:902 msgid "Tree" msgstr "Baum" -#: gitk:1018 gitk:1033 gitk:5969 +#: gitk:1018 gitk:1033 gitk:5961 msgid "Diff this -> selected" msgstr "Vergleich diese -> gewählte" -#: gitk:1020 gitk:1035 gitk:5970 +#: gitk:1020 gitk:1035 gitk:5962 msgid "Diff selected -> this" msgstr "Vergleich gewählte -> diese" -#: gitk:1022 gitk:1037 gitk:5971 +#: gitk:1022 gitk:1037 gitk:5963 msgid "Make patch" msgstr "Patch erstellen" -#: gitk:1023 gitk:6109 +#: gitk:1023 gitk:6101 msgid "Create tag" msgstr "Markierung erstellen" -#: gitk:1024 gitk:6206 +#: gitk:1024 gitk:6198 msgid "Write commit to file" msgstr "Version in Datei schreiben" -#: gitk:1025 gitk:6260 +#: gitk:1025 gitk:6252 msgid "Create new branch" msgstr "Neuen Zweig erstellen" @@ -243,11 +243,11 @@ msgstr "Zweig löschen" #: gitk:1052 msgid "Highlight this too" -msgstr "" +msgstr "Diesen auch hervorheben" #: gitk:1054 msgid "Highlight this only" -msgstr "" +msgstr "Nur diesen hervorheben" #: gitk:1281 msgid "" @@ -258,261 +258,271 @@ msgid "" "\n" "Use and redistribute under the terms of the GNU General Public License" msgstr "" +"\n" +"Gitk - eine Visualisierung der Git Historie\n" +"\n" +"Copyright © 2005-2006 Paul Mackerras\n" +"\n" +"Benutzung und Weiterverbreitung gemäß den Bedingungen der GNU General Public " +"License\n" +" " -#: gitk:1290 gitk:1354 gitk:6532 +#: gitk:1289 gitk:1350 gitk:6524 msgid "Close" msgstr "Schließen" -#: gitk:1311 +#: gitk:1308 msgid "Gitk key bindings" -msgstr "" +msgstr "Gitk Tastaturbelegung" -#: gitk:1863 +#: gitk:1858 msgid "Gitk view definition" -msgstr "" +msgstr "Gitk Ansichten" -#: gitk:1888 +#: gitk:1882 msgid "Name" msgstr "Name" -#: gitk:1891 +#: gitk:1885 msgid "Remember this view" msgstr "Diese Ansicht speichern" -#: gitk:1895 +#: gitk:1889 msgid "Commits to include (arguments to git rev-list):" -msgstr "" +msgstr "Versionen anzeigen (Argumente von git-rev-list):" -#: gitk:1901 +#: gitk:1895 msgid "Enter files and directories to include, one per line:" -msgstr "" +msgstr "Folgende Dateien und Verzeichnisse anzeigen (eine pro Zeile):" -#: gitk:1950 +#: gitk:1942 msgid "Error in commit selection arguments:" -msgstr "" +msgstr "Fehler in den ausgewählten Versionen:" -#: gitk:2001 gitk:2087 gitk:2543 gitk:2557 gitk:3740 gitk:8635 gitk:8636 +#: gitk:1993 gitk:2079 gitk:2535 gitk:2549 gitk:3732 gitk:8620 gitk:8621 msgid "None" msgstr "Keine" -#: gitk:2491 gitk:4295 gitk:5905 gitk:5920 +#: gitk:2483 gitk:4287 gitk:5897 gitk:5912 msgid "Date" msgstr "Datum" -#: gitk:2491 gitk:4295 +#: gitk:2483 gitk:4287 msgid "CDate" msgstr "Eintragedatum" +#: gitk:2632 gitk:2637 +msgid "Descendant" +msgstr "Abkömmling" + +#: gitk:2633 +msgid "Not descendant" +msgstr "Nicht Abkömmling" + #: gitk:2640 gitk:2645 -msgid "Descendent" -msgstr "" +msgid "Ancestor" +msgstr "Vorgänger" #: gitk:2641 -msgid "Not descendent" -msgstr "" - -#: gitk:2648 gitk:2653 -msgid "Ancestor" -msgstr "" - -#: gitk:2649 msgid "Not ancestor" -msgstr "" +msgstr "Nicht Vorgänger" -#: gitk:2883 +#: gitk:2875 msgid "Local changes checked in to index but not committed" msgstr "Lokale Änderungen bereitgestellt, aber nicht eingetragen" -#: gitk:2913 +#: gitk:2905 msgid "Local uncommitted changes, not checked in to index" msgstr "Lokale Änderungen, nicht bereitgestellt" -#: gitk:4264 +#: gitk:4256 msgid "Searching" msgstr "Suchen" -#: gitk:4723 +#: gitk:4715 msgid "Tags:" msgstr "Markierungen:" -#: gitk:4740 gitk:4746 gitk:5898 +#: gitk:4732 gitk:4738 gitk:5890 msgid "Parent" msgstr "Eltern" -#: gitk:4751 +#: gitk:4743 msgid "Child" msgstr "Kind" -#: gitk:4760 +#: gitk:4752 msgid "Branch" msgstr "Zweig" -#: gitk:4763 +#: gitk:4755 msgid "Follows" -msgstr "" +msgstr "Folgt auf" -#: gitk:4766 +#: gitk:4758 msgid "Precedes" -msgstr "" +msgstr "Vorgänger von" -#: gitk:5048 +#: gitk:5040 msgid "Error getting merge diffs:" msgstr "Fehler beim Laden des Vergleichs:" -#: gitk:5725 +#: gitk:5717 msgid "Goto:" -msgstr "" +msgstr "Gehe zu:" -#: gitk:5727 +#: gitk:5719 msgid "SHA1 ID:" -msgstr "" +msgstr "SHA1 Kennung:" -#: gitk:5752 +#: gitk:5744 #, tcl-format msgid "Short SHA1 id %s is ambiguous" -msgstr "" +msgstr "Kurze SHA1-Kennung »%s« ist mehrdeutig" -#: gitk:5764 +#: gitk:5756 #, tcl-format msgid "SHA1 id %s is not known" -msgstr "" +msgstr "SHA1-Kennung »%s« unbekannt" -#: gitk:5766 +#: gitk:5758 #, tcl-format msgid "Tag/Head %s is not known" -msgstr "" +msgstr "Markierung/Zweig »%s« ist unbekannt" -#: gitk:5908 +#: gitk:5900 msgid "Children" msgstr "Kinder" -#: gitk:5965 +#: gitk:5957 #, tcl-format msgid "Reset %s branch to here" msgstr "Zweig »%s« hierher zurücksetzen" -#: gitk:5996 +#: gitk:5988 msgid "Top" msgstr "Oben" -#: gitk:5997 +#: gitk:5989 msgid "From" msgstr "Von" -#: gitk:6002 +#: gitk:5994 msgid "To" msgstr "bis" -#: gitk:6025 +#: gitk:6017 msgid "Generate patch" msgstr "Patch erstellen" -#: gitk:6027 +#: gitk:6019 msgid "From:" msgstr "Von:" -#: gitk:6036 +#: gitk:6028 msgid "To:" msgstr "bis:" -#: gitk:6045 +#: gitk:6037 msgid "Reverse" msgstr "Umgekehrt" -#: gitk:6047 gitk:6220 +#: gitk:6039 gitk:6212 msgid "Output file:" -msgstr "" +msgstr "Ausgabedatei:" -#: gitk:6053 +#: gitk:6045 msgid "Generate" msgstr "Erzeugen" -#: gitk:6089 +#: gitk:6081 msgid "Error creating patch:" -msgstr "" +msgstr "Fehler beim Patch erzeugen:" -#: gitk:6111 gitk:6208 gitk:6262 +#: gitk:6103 gitk:6200 gitk:6254 msgid "ID:" -msgstr "" +msgstr "ID:" -#: gitk:6120 +#: gitk:6112 msgid "Tag name:" msgstr "Markierungsname:" -#: gitk:6124 gitk:6271 +#: gitk:6116 gitk:6263 msgid "Create" msgstr "Erstellen" -#: gitk:6139 +#: gitk:6131 msgid "No tag name specified" -msgstr "" +msgstr "Kein Markierungsname angegeben" -#: gitk:6143 +#: gitk:6135 #, tcl-format msgid "Tag \"%s\" already exists" msgstr "Markierung »%s« existiert bereits." -#: gitk:6153 +#: gitk:6145 msgid "Error creating tag:" -msgstr "" +msgstr "Fehler bei Markierung erstellen:" + +#: gitk:6209 +msgid "Command:" +msgstr "Kommando:" #: gitk:6217 -msgid "Command:" -msgstr "" - -#: gitk:6225 msgid "Write" msgstr "Schreiben" -#: gitk:6241 +#: gitk:6233 msgid "Error writing commit:" -msgstr "" +msgstr "Fehler beim Version eintragen:" -#: gitk:6267 +#: gitk:6259 msgid "Name:" msgstr "Name:" -#: gitk:6286 +#: gitk:6278 msgid "Please specify a name for the new branch" -msgstr "" +msgstr "Bitte geben Sie einen Namen für den neuen Zweig an." -#: gitk:6315 +#: gitk:6307 #, tcl-format msgid "Commit %s is already included in branch %s -- really re-apply it?" msgstr "" +"Version »%s« ist bereits im Zweig »%s« enthalten -- trotzdem erneut " +"eintragen?" -#: gitk:6320 +#: gitk:6312 msgid "Cherry-picking" msgstr "Version pflücken" -#: gitk:6332 +#: gitk:6324 msgid "No changes committed" msgstr "Keine Änderungen eingetragen" -#: gitk:6355 +#: gitk:6347 msgid "Confirm reset" msgstr "Zurücksetzen bestätigen" -#: gitk:6357 +#: gitk:6349 #, tcl-format msgid "Reset branch %s to %s?" msgstr "Zweig »%s« auf »%s« zurücksetzen?" -#: gitk:6361 +#: gitk:6353 msgid "Reset type:" msgstr "Art des Zurücksetzens:" -#: gitk:6365 +#: gitk:6357 msgid "Soft: Leave working tree and index untouched" msgstr "Harmlos: Arbeitskopie und Bereitstellung unverändert" -#: gitk:6368 +#: gitk:6360 msgid "Mixed: Leave working tree untouched, reset index" msgstr "" "Gemischt: Arbeitskopie unverändert,\n" "Bereitstellung zurückgesetzt" -#: gitk:6371 +#: gitk:6363 msgid "" "Hard: Reset working tree and index\n" "(discard ALL local changes)" @@ -520,184 +530,196 @@ msgstr "" "Hart: Arbeitskopie und Bereitstellung\n" "(Alle lokalen Änderungen werden gelöscht)" -#: gitk:6387 +#: gitk:6379 msgid "Resetting" msgstr "Zurücksetzen" -#: gitk:6444 +#: gitk:6436 msgid "Checking out" msgstr "Umstellen" -#: gitk:6474 +#: gitk:6466 msgid "Cannot delete the currently checked-out branch" -msgstr "Der Zweig, auf den die Arbeitskopie momentan umgestellt ist, kann nicht gelöscht werden." +msgstr "" +"Der Zweig, auf den die Arbeitskopie momentan umgestellt ist, kann nicht " +"gelöscht werden." -#: gitk:6480 +#: gitk:6472 #, tcl-format msgid "" "The commits on branch %s aren't on any other branch.\n" "Really delete branch %s?" msgstr "" +"Die Versionen auf Zweig »%s« existieren auf keinem anderen Zweig.\n" +"Zweig »%s« trotzdem löschen?" -#: gitk:6511 +#: gitk:6503 #, tcl-format msgid "Tags and heads: %s" -msgstr "" +msgstr "Markierungen und Zweige: %s" -#: gitk:6525 +#: gitk:6517 msgid "Filter" -msgstr "" +msgstr "Filtern" -#: gitk:6820 +#: gitk:6811 msgid "" "Error reading commit topology information; branch and preceding/following " "tag information will be incomplete." msgstr "" +"Fehler beim Lesen der Strukturinformationen; Zweige und Vorgänger/Nachfolger " +"Informationen werden unvollständig sein." -#: gitk:7804 +#: gitk:7795 msgid "Tag" msgstr "Markierung" -#: gitk:7804 +#: gitk:7795 msgid "Id" -msgstr "" +msgstr "Id" -#: gitk:7844 +#: gitk:7835 msgid "Gitk font chooser" -msgstr "" +msgstr "Gitk Schriften wählen" -#: gitk:7861 +#: gitk:7852 msgid "B" msgstr "F" -#: gitk:7864 +#: gitk:7855 msgid "I" msgstr "K" -#: gitk:7959 +#: gitk:7948 msgid "Gitk preferences" msgstr "Gitk Einstellungen" -#: gitk:7960 +#: gitk:7949 msgid "Commit list display options" msgstr "Anzeige Versionsliste" -#: gitk:7964 +#: gitk:7952 msgid "Maximum graph width (lines)" msgstr "Maximale Graphenbreite (Zeilen)" -#: gitk:7968 +#: gitk:7956 #, tcl-format msgid "Maximum graph width (% of pane)" msgstr "Maximale Graphenbreite (% des Fensters)" -#: gitk:7973 +#: gitk:7961 msgid "Show local changes" msgstr "Lokale Änderungen anzeigen" -#: gitk:7978 +#: gitk:7966 msgid "Diff display options" msgstr "Anzeige Vergleich" -#: gitk:7981 +#: gitk:7968 msgid "Tab spacing" msgstr "Tabulatorbreite" -#: gitk:7985 +#: gitk:7972 msgid "Display nearby tags" -msgstr "" +msgstr "Naheliegende Überschriften anzeigen" -#: gitk:7990 +#: gitk:7977 msgid "Limit diffs to listed paths" msgstr "Vergleich nur für angezeigte Pfade" -#: gitk:7995 +#: gitk:7982 msgid "Colors: press to choose" msgstr "Farben: Klicken zum Wählen" -#: gitk:7999 +#: gitk:7985 msgid "Background" msgstr "Vordergrund" -#: gitk:8003 +#: gitk:7989 msgid "Foreground" msgstr "Hintergrund" -#: gitk:8007 +#: gitk:7993 msgid "Diff: old lines" msgstr "Vergleich: Alte Zeilen" -#: gitk:8012 +#: gitk:7998 msgid "Diff: new lines" msgstr "Vergleich: Neue Zeilen" -#: gitk:8017 +#: gitk:8003 msgid "Diff: hunk header" msgstr "Vergleich: Änderungstitel" -#: gitk:8023 +#: gitk:8009 msgid "Select bg" msgstr "Hintergrundfarbe Auswählen" -#: gitk:8027 +#: gitk:8013 msgid "Fonts: press to choose" msgstr "Schriftart: Klicken zum Wählen" -#: gitk:8030 +#: gitk:8015 msgid "Main font" msgstr "Programmschriftart" -#: gitk:8031 +#: gitk:8016 msgid "Diff display font" msgstr "Vergleich" -#: gitk:8032 +#: gitk:8017 msgid "User interface font" msgstr "Beschriftungen" -#: gitk:8050 +#: gitk:8033 #, tcl-format msgid "Gitk: choose color for %s" msgstr "Gitk: Farbe wählen für %s" -#: gitk:8431 +#: gitk:8414 msgid "" "Sorry, gitk cannot run with this version of Tcl/Tk.\n" " Gitk requires at least Tcl/Tk 8.4." msgstr "" +"Gitk läuft nicht mit dieser Version von Tcl/Tk.\n" +"Gitk benötigt mindestens Tcl/Tk 8.4." -#: gitk:8516 +#: gitk:8501 msgid "Cannot find a git repository here." msgstr "Kein Git-Projektarchiv gefunden." -#: gitk:8520 +#: gitk:8505 #, tcl-format msgid "Cannot find the git directory \"%s\"." -msgstr "" +msgstr "Git-Verzeichnis »%s« wurde nicht gefunden." -#: gitk:8559 +#: gitk:8544 #, tcl-format msgid "Ambiguous argument '%s': both revision and filename" -msgstr "" +msgstr "Mehrdeutige Angabe »%s«: Sowohl Version als auch Dateiname existiert." -#: gitk:8571 +#: gitk:8556 msgid "Bad arguments to gitk:" -msgstr "" +msgstr "Falsche Kommandozeilen-Parameter für gitk:" -#: gitk:8583 +#: gitk:8568 msgid "Couldn't get list of unmerged files:" -msgstr "" +msgstr "Liste der nicht-zusammengeführten Dateien nicht gefunden:" -#: gitk:8599 +#: gitk:8584 msgid "No files selected: --merge specified but no files are unmerged." msgstr "" +"Keine Dateien ausgewähle: --merge angegeben, es existieren aber keine nicht-" +"zusammengeführten Dateien." -#: gitk:8602 +#: gitk:8587 msgid "" "No files selected: --merge specified but no unmerged files are within file " "limit." msgstr "" +"Keine Dateien ausgewähle: --merge angegeben, aber keine nicht-" +"zusammengeführten Dateien sind in der Dateiauswahl." -#: gitk:8661 +#: gitk:8646 msgid "Command line" msgstr "Kommandozeile" From 646f3a149d1cc8a6511a433cd2a51987d7582463 Mon Sep 17 00:00:00 2001 From: Johannes Schindelin <Johannes.Schindelin@gmx.de> Date: Fri, 11 Jan 2008 12:39:33 +0000 Subject: [PATCH 4/9] [PATCH] gitk: make Ctrl "+" really increase the font size Only Ctrl "=" was bound to increase the font size, probably because English keyboards have the plus on the same key as the equal sign. However, not the whole world is English, and at least with some other keyboard layouts, Ctrl "+" did not work as documented. Noticed by Stephan Hennig. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Paul Mackerras <paulus@samba.org> --- gitk | 1 + 1 file changed, 1 insertion(+) diff --git a/gitk b/gitk index b3cb8e8b7e6..5560e4dc560 100755 --- a/gitk +++ b/gitk @@ -996,6 +996,7 @@ proc makewindow {} { bind . <$M1B-r> dosearchback bind . <$M1B-s> dosearch bind . <$M1B-equal> {incrfont 1} + bind . <$M1B-plus> {incrfont 1} bind . <$M1B-KP_Add> {incrfont 1} bind . <$M1B-minus> {incrfont -1} bind . <$M1B-KP_Subtract> {incrfont -1} From 3d2c998e305fdf9f3d9ecc1ecfbfafe4c65020f1 Mon Sep 17 00:00:00 2001 From: Michele Ballabio <barra_cuda@katamail.com> Date: Tue, 15 Jan 2008 23:31:49 +0100 Subject: [PATCH 5/9] [PATCH] gitk: Fix "Key bindings" message The "Key bindings" message under the "Help" menu was too long and could not be parsed by the translation engine. Fix both issues by translating one line at a time. Signed-off-by: Michele Ballabio <barra_cuda@katamail.com> Signed-off-by: Paul Mackerras <paulus@samba.org> --- gitk | 76 ++++++++++++++++++++++++++++++------------------------------ 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/gitk b/gitk index 5560e4dc560..755596880d4 100755 --- a/gitk +++ b/gitk @@ -1307,45 +1307,45 @@ proc keys {} { } toplevel $w wm title $w [mc "Gitk key bindings"] - message $w.m -text [mc " -Gitk key bindings: + message $w.m -text " +[mc "Gitk key bindings:"] -<$M1T-Q> Quit -<Home> Move to first commit -<End> Move to last commit -<Up>, p, i Move up one commit -<Down>, n, k Move down one commit -<Left>, z, j Go back in history list -<Right>, x, l Go forward in history list -<PageUp> Move up one page in commit list -<PageDown> Move down one page in commit list -<$M1T-Home> Scroll to top of commit list -<$M1T-End> Scroll to bottom of commit list -<$M1T-Up> Scroll commit list up one line -<$M1T-Down> Scroll commit list down one line -<$M1T-PageUp> Scroll commit list up one page -<$M1T-PageDown> Scroll commit list down one page -<Shift-Up> Find backwards (upwards, later commits) -<Shift-Down> Find forwards (downwards, earlier commits) -<Delete>, b Scroll diff view up one page -<Backspace> Scroll diff view up one page -<Space> Scroll diff view down one page -u Scroll diff view up 18 lines -d Scroll diff view down 18 lines -<$M1T-F> Find -<$M1T-G> Move to next find hit -<Return> Move to next find hit -/ Move to next find hit, or redo find -? Move to previous find hit -f Scroll diff view to next file -<$M1T-S> Search for next hit in diff view -<$M1T-R> Search for previous hit in diff view -<$M1T-KP+> Increase font size -<$M1T-plus> Increase font size -<$M1T-KP-> Decrease font size -<$M1T-minus> Decrease font size -<F5> Update -"] \ +[mc "<%s-Q> Quit" $M1T] +[mc "<Home> Move to first commit"] +[mc "<End> Move to last commit"] +[mc "<Up>, p, i Move up one commit"] +[mc "<Down>, n, k Move down one commit"] +[mc "<Left>, z, j Go back in history list"] +[mc "<Right>, x, l Go forward in history list"] +[mc "<PageUp> Move up one page in commit list"] +[mc "<PageDown> Move down one page in commit list"] +[mc "<%s-Home> Scroll to top of commit list" $M1T] +[mc "<%s-End> Scroll to bottom of commit list" $M1T] +[mc "<%s-Up> Scroll commit list up one line" $M1T] +[mc "<%s-Down> Scroll commit list down one line" $M1T] +[mc "<%s-PageUp> Scroll commit list up one page" $M1T] +[mc "<%s-PageDown> Scroll commit list down one page" $M1T] +[mc "<Shift-Up> Find backwards (upwards, later commits)"] +[mc "<Shift-Down> Find forwards (downwards, earlier commits)"] +[mc "<Delete>, b Scroll diff view up one page"] +[mc "<Backspace> Scroll diff view up one page"] +[mc "<Space> Scroll diff view down one page"] +[mc "u Scroll diff view up 18 lines"] +[mc "d Scroll diff view down 18 lines"] +[mc "<%s-F> Find" $M1T] +[mc "<%s-G> Move to next find hit" $M1T] +[mc "<Return> Move to next find hit"] +[mc "/ Move to next find hit, or redo find"] +[mc "? Move to previous find hit"] +[mc "f Scroll diff view to next file"] +[mc "<%s-S> Search for next hit in diff view" $M1T] +[mc "<%s-R> Search for previous hit in diff view" $M1T] +[mc "<%s-KP+> Increase font size" $M1T] +[mc "<%s-plus> Increase font size" $M1T] +[mc "<%s-KP-> Decrease font size" $M1T] +[mc "<%s-minus> Decrease font size" $M1T] +[mc "<F5> Update"] +" \ -justify left -bg white -border 2 -relief groove pack $w.m -side top -fill both -padx 2 -pady 2 button $w.ok -text [mc "Close"] -command "destroy $w" -default active From b9b86007e27d9a06d58feab618a5be1d491ed13e Mon Sep 17 00:00:00 2001 From: Steffen Prohaska <prohaska@zib.de> Date: Thu, 17 Jan 2008 23:42:55 +0100 Subject: [PATCH 6/9] [PATCH] gitk: Add checkbutton to ignore space changes Ignoring space changes can be helpful. For example, a commit claims to only reformat source code and you quickly want to verify if this claim is true. Or a commit accidentally changes code formatting and you want to focus on the real changes. In such cases a button to toggle of whitespace changes would be quite handy. You could quickly toggle between seeing and ignoring whitespace changes. This commit adds such a checkbutton right above the diff view. However, in general it is a good thing to see whitespace changes and therefore the state of the checkbutton is not saved. For example, space changes might happen unintentionally. But they are real changes yielding different sha1s for the blobs involved. Signed-off-by: Steffen Prohaska <prohaska@zib.de> Signed-off-by: Paul Mackerras <paulus@samba.org> --- gitk | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/gitk b/gitk index 755596880d4..dab9df067eb 100755 --- a/gitk +++ b/gitk @@ -632,6 +632,7 @@ proc makewindow {} { global findtype findtypemenu findloc findstring fstring geometry global entries sha1entry sha1string sha1but global diffcontextstring diffcontext + global ignorespace global maincursor textcursor curtextcursor global rowctxmenu fakerowmenu mergemax wrapcomment global highlight_files gdttype @@ -849,6 +850,9 @@ proc makewindow {} { trace add variable diffcontextstring write diffcontextchange lappend entries .bleft.mid.diffcontext pack .bleft.mid.labeldiffcontext .bleft.mid.diffcontext -side left + checkbutton .bleft.mid.ignspace -text [mc "Ignore space change"] \ + -command changeignorespace -variable ignorespace + pack .bleft.mid.ignspace -side left -padx 5 set ctext .bleft.ctext text $ctext -background $bgcolor -foreground $fgcolor \ -state disabled -font textfont \ @@ -5270,13 +5274,21 @@ proc diffcontextchange {n1 n2 op} { } } +proc changeignorespace {} { + reselectline +} + proc getblobdiffs {ids} { global blobdifffd diffids env global diffinhdr treediffs global diffcontext + global ignorespace global limitdiffs viewfiles curview set cmd [diffcmd $ids "-p -C --no-commit-id -U$diffcontext"] + if {$ignorespace} { + append cmd " -w" + } if {$limitdiffs && $viewfiles($curview) ne {}} { set cmd [concat $cmd -- $viewfiles($curview)] } @@ -8459,6 +8471,7 @@ set bgcolor white set fgcolor black set diffcolors {red "#00a000" blue} set diffcontext 3 +set ignorespace 0 set selectbgcolor gray85 ## For msgcat loading, first locate the installation location. From 48750d6a84a7fc08dcd7cb4533c280c00106f9b6 Mon Sep 17 00:00:00 2001 From: Gerrit Pape <pape@smarden.org> Date: Mon, 11 Feb 2008 10:57:40 +0000 Subject: [PATCH 7/9] [PATCH] gitk: properly deal with tag names containing / (slash) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When creating a tag through gitk, and the tag name includes a slash (or slashes), gitk errors out in a popup window. This patch makes gitk use 'git tag' to create the tag instead of modifying files in refs/tags/, which fixes the issue; if 'git tag' throws an error, gitk pops up with the error message. The problem was reported by Frédéric Brière through http://bugs.debian.org/464104 Signed-off-by: Gerrit Pape <pape@smarden.org> Signed-off-by: Paul Mackerras <paulus@samba.org> --- gitk | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/gitk b/gitk index dab9df067eb..80544bfc538 100755 --- a/gitk +++ b/gitk @@ -6149,11 +6149,7 @@ proc domktag {} { return } if {[catch { - set dir [gitdir] - set fname [file join $dir "refs/tags" $tag] - set f [open $fname w] - puts $f $id - close $f + exec git tag $tag $id } err]} { error_popup "[mc "Error creating tag:"] $err" return From 1407ade93cc1c58d520c2a0f509152ba27b594e8 Mon Sep 17 00:00:00 2001 From: Linus Torvalds <torvalds@linux-foundation.org> Date: Sat, 9 Feb 2008 14:02:07 -0800 Subject: [PATCH 8/9] [PATCH] gitk: learn --show-all output It's really not very easy to visualize the commit walker, because - on purpose - it obvously doesn't show the uninteresting commits! We will soon add a "--show-all" flag to the revision walker, which will make it show uninteresting commits too, and they'll have a '^' in front of them. This is to update 'gitk' to show those negative commits in gray to futureproof it. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Paul Mackerras <paulus@samba.org> --- gitk | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/gitk b/gitk index 80544bfc538..25ab725bba4 100755 --- a/gitk +++ b/gitk @@ -240,11 +240,12 @@ proc getcommitlines {fd view} { set listed 1 if {$j >= 0 && [string match "commit *" $cmit]} { set ids [string range $cmit 7 [expr {$j - 1}]] - if {[string match {[-<>]*} $ids]} { + if {[string match {[-^<>]*} $ids]} { switch -- [string index $ids 0] { "-" {set listed 0} - "<" {set listed 2} - ">" {set listed 3} + "^" {set listed 2} + "<" {set listed 3} + ">" {set listed 4} } set ids [string range $ids 1 end] } @@ -3631,23 +3632,23 @@ proc drawcmittext {id row col} { global linehtag linentag linedtag selectedline global canvxmax boldrows boldnamerows fgcolor nullid nullid2 - # listed is 0 for boundary, 1 for normal, 2 for left, 3 for right + # listed is 0 for boundary, 1 for normal, 2 for negative, 3 for left, 4 for right set listed [lindex $commitlisted $row] if {$id eq $nullid} { set ofill red } elseif {$id eq $nullid2} { set ofill green } else { - set ofill [expr {$listed != 0? "blue": "white"}] + set ofill [expr {$listed != 0 ? $listed == 2 ? "gray" : "blue" : "white"}] } set x [xc $row $col] set y [yc $row] set orad [expr {$linespc / 3}] - if {$listed <= 1} { + if {$listed <= 2} { set t [$canv create oval [expr {$x - $orad}] [expr {$y - $orad}] \ [expr {$x + $orad - 1}] [expr {$y + $orad - 1}] \ -fill $ofill -outline $fgcolor -width 1 -tags circle] - } elseif {$listed == 2} { + } elseif {$listed == 3} { # triangle pointing left for left-side commits set t [$canv create polygon \ [expr {$x - $orad}] $y \ From 6675ea4240540e3ee3b0dd2f26b1ad86121d22c6 Mon Sep 17 00:00:00 2001 From: Johannes Sixt <johannes.sixt@telecom.at> Date: Wed, 13 Feb 2008 17:27:30 +0100 Subject: [PATCH 9/9] [PATCH] gitk: Heed the lines of context in merge commits There is an edit box where the number of context lines can be chosen. But it was only used when regular diffs were displayed, not for merge commits. This fixes it. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Paul Mackerras <paulus@samba.org> --- gitk | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gitk b/gitk index 25ab725bba4..f1f21e97bf5 100755 --- a/gitk +++ b/gitk @@ -5032,13 +5032,14 @@ proc getblobline {bf id} { proc mergediff {id l} { global diffmergeid mdifffd global diffids + global diffcontext global parentlist global limitdiffs viewfiles curview set diffmergeid $id set diffids $id # this doesn't seem to actually affect anything... - set cmd [concat | git diff-tree --no-commit-id --cc $id] + set cmd [concat | git diff-tree --no-commit-id --cc -U$diffcontext $id] if {$limitdiffs && $viewfiles($curview) ne {}} { set cmd [concat $cmd -- $viewfiles($curview)] }