From fba6072ed83bfc3c0e1eb56f11476b06a3b0dfb7 Mon Sep 17 00:00:00 2001 From: Johannes Sixt Date: Thu, 13 Dec 2007 15:39:21 +0100 Subject: [PATCH 01/93] git-gui: Move frequently used commands to the top of the context menu. "Stage/Unstage Hunk" is probably the most frequently used command of the patch context menu *and* it is not available in some other form than the context menu. Therefore, it should go to the top. "Less Context" and "More Context" entries are also not easily available otherwise, and are therefore, moved second. The other entries are available via key strokes (Copy, Paste, Refresh) or rarly used (Font Size, Options) and can go last. Signed-off-by: Johannes Sixt Signed-off-by: Shawn O. Pearce --- git-gui.sh | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/git-gui.sh b/git-gui.sh index 1fca11f278..fcb2ab2fb7 100755 --- a/git-gui.sh +++ b/git-gui.sh @@ -2541,6 +2541,27 @@ $ui_diff tag raise sel # set ctxm .vpane.lower.diff.body.ctxm menu $ctxm -tearoff 0 +$ctxm add command \ + -label [mc "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 [mc "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 [mc "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 [mc Refresh] \ -command reshow_diff @@ -2562,12 +2583,6 @@ $ctxm add command \ } lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state] $ctxm add separator -$ctxm add command \ - -label [mc "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 [mc "Decrease Font Size"] \ -command {incr_font_size font_diff -1} @@ -2577,21 +2592,6 @@ $ctxm add command \ -command {incr_font_size font_diff 1} lappend diff_actions [list $ctxm entryconf [$ctxm index last] -state] $ctxm add separator -$ctxm add command \ - -label [mc "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 [mc "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 [mc "Options..."] \ -command do_options proc popup_diff_menu {ctxm x y X Y} { From a4750dd26671427009cc2c7a6a303f7ad8c39e8a Mon Sep 17 00:00:00 2001 From: "Shawn O. Pearce" Date: Fri, 14 Dec 2007 01:51:22 -0500 Subject: [PATCH 02/93] git-gui: Handle file mode changes (644->755) in diff viewer Johannes Sixt pointed out the diff headers "old mode ..." and "new mode ..." were not being parsed properly by git-gui. We now include them in the diff viewer for a file. Signed-off-by: Shawn O. Pearce --- lib/diff.tcl | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/diff.tcl b/lib/diff.tcl index 43565e412f..18aba3eae3 100644 --- a/lib/diff.tcl +++ b/lib/diff.tcl @@ -220,6 +220,7 @@ proc read_diff {fd} { if {[string match {mode *} $line] || [string match {new file *} $line] + || [regexp {^(old|new) mode *} $line] || [string match {deleted file *} $line] || [string match {deleted symlink} $line] || [string match {Binary files * and * differ} $line] From 9fe98116a2c7231503e7f5156417c1af84d4a59e Mon Sep 17 00:00:00 2001 From: Mark Levedahl Date: Thu, 13 Dec 2007 09:02:26 -0500 Subject: [PATCH 03/93] git-gui: Unconditionally use absolute paths with Cygwin The mapping of Windows vs Cygwin/Posix paths is arbitrary and not knowable from the Posix side, so logic to determine whether to use relative paths to locate the git-gui library just does not work on Cygwin. Fix this to unconditionally use absolute path on Cygwin. (This fixes a regression from 1.5.4). Signed-off-by: Mark Levedahl Signed-off-by: Shawn O. Pearce --- Makefile | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 26ac4b6bb0..c109eab137 100644 --- a/Makefile +++ b/Makefile @@ -117,14 +117,12 @@ GITGUI_SCRIPT := $$0 GITGUI_RELATIVE := GITGUI_MACOSXAPP := -ifeq ($(exedir),$(gg_libdir)) - GITGUI_RELATIVE := 1 -endif - ifeq ($(uname_O),Cygwin) GITGUI_SCRIPT := `cygpath --windows --absolute "$(GITGUI_SCRIPT)"` - ifeq ($(GITGUI_RELATIVE),) - gg_libdir := $(shell cygpath --windows --absolute "$(gg_libdir)") + gg_libdir := $(shell cygpath --windows --absolute "$(gg_libdir)") +else + ifeq ($(exedir),$(gg_libdir)) + GITGUI_RELATIVE := 1 endif endif ifeq ($(uname_S),Darwin) From 25ec9384844d0cc855cf16672f61cf6b3be9f67d Mon Sep 17 00:00:00 2001 From: Christian Stimming Date: Wed, 7 Nov 2007 18:39:08 +0100 Subject: [PATCH 04/93] [PATCH] gitk i18n: Add Makefile with rules for po file creation and installation The compiled .msg files will be installed into $(sharedir)/gitk/lib/msgs according to Junio's mailing list proposal on 2007-07-28. Signed-off-by: Christian Stimming Signed-off-by: Paul Mackerras --- Makefile | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 Makefile diff --git a/Makefile b/Makefile new file mode 100644 index 0000000000..38154b6e08 --- /dev/null +++ b/Makefile @@ -0,0 +1,45 @@ +# Set the installation directories; this section is needed only in +# gitk.git but probably not in git.git. +ifndef gitexecdir + gitexecdir := $(shell git --exec-path) +endif +ifndef sharedir + sharedir := $(dir $(gitexecdir))share +endif + +# From here on, these are needed in git.git/gitk/Makefile. +gitk_libdir ?= $(sharedir)/gitk/lib +msgsdir ?= $(gitk_libdir)/msgs +msgsdir_SQ = $(subst ','\'',$(msgsdir)) + +## Beginning of po-file creation rules +XGETTEXT ?= xgettext +MSGFMT ?= msgfmt +PO_TEMPLATE = po/gitk.pot +ALL_POFILES = $(wildcard po/*.po) +ALL_MSGFILES = $(subst .po,.msg,$(ALL_POFILES)) + +all:: $(ALL_MSGFILES) + +$(PO_TEMPLATE): gitk + $(XGETTEXT) -kmc -LTcl -o $@ gitk +update-po:: $(PO_TEMPLATE) + $(foreach p, $(ALL_POFILES), echo Updating $p ; msgmerge -U $p $(PO_TEMPLATE) ; ) +$(ALL_MSGFILES): %.msg : %.po + @echo Generating catalog $@ + $(MSGFMT) --statistics --tcl $< -l $(basename $(notdir $<)) -d $(dir $@) + +clean:: + rm -f $(ALL_PROGRAMS) po/*.msg +## End of po-file creation rules + +# Install rules for po-files +install: all + $(QUIET)$(INSTALL_D0)'$(DESTDIR_SQ)$(msgsdir_SQ)' $(INSTALL_D1) + $(QUIET)$(foreach p,$(ALL_MSGFILES), $(INSTALL_R0)$p $(INSTALL_R1) '$(DESTDIR_SQ)$(msgsdir_SQ)' &&) true + +uninstall: + $(QUIET)$(foreach p,$(ALL_MSGFILES), $(REMOVE_F0)'$(DESTDIR_SQ)$(msgsdir_SQ)'/$(notdir $p) $(REMOVE_F1) &&) true + $(QUIET)$(REMOVE_D0)'$(DESTDIR_SQ)$(msgsdir_SQ)' $(REMOVE_D1) + $(QUIET)$(REMOVE_D0)'$(DESTDIR_SQ)$(libdir_SQ)' $(REMOVE_D1) + $(QUIET)$(REMOVE_D0)`dirname '$(DESTDIR_SQ)$(libdir_SQ)'` $(REMOVE_D1) From 663c3aa9c89ae7d7a52308c50bda084f8b4ab337 Mon Sep 17 00:00:00 2001 From: Christian Stimming Date: Wed, 7 Nov 2007 18:40:59 +0100 Subject: [PATCH 05/93] [PATCH] gitk i18n: Import msgcat for message string translation; load translation catalogs By setting the environment variable GITK_MSGSDIR, one can manually set the directory where the .msg files are located. This is quite handy during development with GITK_MSGSDIR=po. Signed-off-by: Christian Stimming Signed-off-by: Paul Mackerras --- gitk | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/gitk b/gitk index 1da0b0af1d..629acfbcc5 100755 --- a/gitk +++ b/gitk @@ -8476,6 +8476,25 @@ set diffcolors {red "#00a000" blue} set diffcontext 3 set selectbgcolor gray85 +## For msgcat loading, first locate the installation location. +if { [info exists ::env(GITK_MSGSDIR)] } { + ## Msgsdir was manually set in the environment. + set gitk_msgsdir $::env(GITK_MSGSDIR) +} else { + ## Let's guess the prefix from argv0. + set gitk_prefix [file dirname [file dirname [file normalize $argv0]]] + set gitk_libdir [file join $gitk_prefix share gitk lib] + set gitk_msgsdir [file join $gitk_libdir msgs] + unset gitk_prefix +} + +## Internationalization (i18n) through msgcat and gettext. See +## http://www.gnu.org/software/gettext/manual/html_node/Tcl.html +package require msgcat +namespace import ::msgcat::mc +## And eventually load the actual message catalog +::msgcat::mcload $gitk_msgsdir + catch {source ~/.gitk} font create optionfont -family sans-serif -size -12 From d990cedf9c61269eb71c257b84a4762bbbc196ef Mon Sep 17 00:00:00 2001 From: Christian Stimming Date: Wed, 7 Nov 2007 18:42:55 +0100 Subject: [PATCH 06/93] [PATCH] gitk i18n: Markup several strings for translation This just marks up plain strings, that aren't used in any unusual way. Signed-off-by: Christian Stimming Signed-off-by: Paul Mackerras --- gitk | 401 ++++++++++++++++++++++++++++++----------------------------- 1 file changed, 201 insertions(+), 200 deletions(-) diff --git a/gitk b/gitk index 629acfbcc5..e291577e52 100755 --- a/gitk +++ b/gitk @@ -98,7 +98,7 @@ proc start_rev_list {view} { set fd [open [concat | git log --no-color -z --pretty=raw $order --parents \ --boundary $viewargs($view) "--" $viewfiles($view)] r] } err]} { - error_popup "Error executing git rev-list: $err" + error_popup "[mc "Error executing git rev-list:"] $err" exit 1 } set commfd($view) $fd @@ -111,7 +111,7 @@ proc start_rev_list {view} { fconfigure $fd -encoding $tclencoding } filerun $fd [list getcommitlines $fd $view] - nowbusy $view "Reading" + nowbusy $view [mc "Reading"] if {$view == $curview} { set progressdirn 1 set progresscoords {0 0} @@ -138,7 +138,7 @@ proc getcommits {} { set phase getcommits initlayout start_rev_list $curview - show_status "Reading commits..." + show_status [mc "Reading commits..."] } # This makes a string representation of a positive integer which @@ -261,7 +261,7 @@ proc getcommitlines {fd view} { if {[string length $shortcmit] > 80} { set shortcmit "[string range $shortcmit 0 80]..." } - error_popup "Can't parse git log output: {$shortcmit}" + error_popup "[mc "Can't parse git log output:"] {$shortcmit}" exit 1 } set id [lindex $ids 0] @@ -372,7 +372,7 @@ proc chewcommits {view} { #set ms [expr {[clock clicks -milliseconds] - $startmsecs}] #puts "overall $ms ms for $numcommits commits" } else { - show_status "No commits selected" + show_status [mc "No commits selected"] } notbusy layout set phase {} @@ -483,7 +483,7 @@ proc getcommit {id} { } else { readcommit $id if {![info exists commitinfo($id)]} { - set commitinfo($id) {"No commit information available"} + set commitinfo($id) [list [mc "No commit information available"]] } } return 1 @@ -582,7 +582,7 @@ proc removehead {id name} { proc show_error {w top msg} { message $w.m -text $msg -justify center -aspect 400 pack $w.m -side top -fill x -padx 20 -pady 20 - button $w.ok -text OK -command "destroy $top" + button $w.ok -text [mc OK] -command "destroy $top" pack $w.ok -side bottom -fill x bind $top "grab $top; focus $top" bind $top "destroy $top" @@ -604,9 +604,9 @@ proc confirm_popup msg { wm transient $w . message $w.m -text $msg -justify center -aspect 400 pack $w.m -side top -fill x -padx 20 -pady 20 - button $w.ok -text OK -command "set confirm_ok 1; destroy $w" + button $w.ok -text [mc OK] -command "set confirm_ok 1; destroy $w" pack $w.ok -side left -fill x - button $w.cancel -text Cancel -command "destroy $w" + button $w.cancel -text [mc Cancel] -command "destroy $w" pack $w.cancel -side right -fill x bind $w "grab $w; focus $w" tkwait window $w @@ -630,33 +630,33 @@ proc makewindow {} { global have_tk85 menu .bar - .bar add cascade -label "File" -menu .bar.file + .bar add cascade -label [mc "File"] -menu .bar.file .bar configure -font uifont menu .bar.file - .bar.file add command -label "Update" -command updatecommits - .bar.file add command -label "Reread references" -command rereadrefs - .bar.file add command -label "List references" -command showrefs - .bar.file add command -label "Quit" -command doquit + .bar.file add command -label [mc "Update"] -command updatecommits + .bar.file add command -label [mc "Reread references"] -command rereadrefs + .bar.file add command -label [mc "List references"] -command showrefs + .bar.file add command -label [mc "Quit"] -command doquit .bar.file configure -font uifont menu .bar.edit - .bar add cascade -label "Edit" -menu .bar.edit - .bar.edit add command -label "Preferences" -command doprefs + .bar add cascade -label [mc "Edit"] -menu .bar.edit + .bar.edit add command -label [mc "Preferences"] -command doprefs .bar.edit configure -font uifont menu .bar.view -font uifont - .bar add cascade -label "View" -menu .bar.view - .bar.view add command -label "New view..." -command {newview 0} - .bar.view add command -label "Edit view..." -command editview \ + .bar add cascade -label [mc "View"] -menu .bar.view + .bar.view add command -label [mc "New view..."] -command {newview 0} + .bar.view add command -label [mc "Edit view..."] -command editview \ -state disabled - .bar.view add command -label "Delete view" -command delview -state disabled + .bar.view add command -label [mc "Delete view"] -command delview -state disabled .bar.view add separator - .bar.view add radiobutton -label "All files" -command {showview 0} \ + .bar.view add radiobutton -label [mc "All files"] -command {showview 0} \ -variable selectedview -value 0 menu .bar.help - .bar add cascade -label "Help" -menu .bar.help - .bar.help add command -label "About gitk" -command about - .bar.help add command -label "Key bindings" -command keys + .bar add cascade -label [mc "Help"] -menu .bar.help + .bar.help add command -label [mc "About gitk"] -command about + .bar.help add command -label [mc "Key bindings"] -command keys .bar.help configure -font uifont . configure -menu .bar @@ -713,7 +713,7 @@ proc makewindow {} { set sha1entry .tf.bar.sha1 set entries $sha1entry set sha1but .tf.bar.sha1label - button $sha1but -text "SHA1 ID: " -state disabled -relief flat \ + button $sha1but -text [mc "SHA1 ID: "] -state disabled -relief flat \ -command gotocommit -width 8 -font uifont $sha1but conf -disabledforeground [$sha1but cget -foreground] pack .tf.bar.sha1label -side left @@ -763,10 +763,10 @@ proc makewindow {} { set progupdatepending 0 # build up the bottom bar of upper window - label .tf.lbar.flabel -text "Find " -font uifont - button .tf.lbar.fnext -text "next" -command {dofind 1 1} -font uifont - button .tf.lbar.fprev -text "prev" -command {dofind -1 1} -font uifont - label .tf.lbar.flab2 -text " commit " -font uifont + label .tf.lbar.flabel -text "[mc "Find"] " -font uifont + button .tf.lbar.fnext -text [mc "next"] -command {dofind 1 1} -font uifont + button .tf.lbar.fprev -text [mc "prev"] -command {dofind -1 1} -font uifont + label .tf.lbar.flab2 -text " [mc "commit"] " -font uifont pack .tf.lbar.flabel .tf.lbar.fnext .tf.lbar.fprev .tf.lbar.flab2 \ -side left -fill y set gdttype "containing:" @@ -822,7 +822,7 @@ proc makewindow {} { frame .bleft.top frame .bleft.mid - button .bleft.top.search -text "Search" -command dosearch \ + button .bleft.top.search -text [mc "Search"] -command dosearch \ -font uifont pack .bleft.top.search -side left -padx 5 set sstring .bleft.top.sstring @@ -830,13 +830,13 @@ proc makewindow {} { lappend entries $sstring trace add variable searchstring write incrsearch pack $sstring -side left -expand 1 -fill x - radiobutton .bleft.mid.diff -text "Diff" -font uifont \ + radiobutton .bleft.mid.diff -text [mc "Diff"] -font uifont \ -command changediffdisp -variable diffelide -value {0 0} - radiobutton .bleft.mid.old -text "Old version" -font uifont \ + radiobutton .bleft.mid.old -text [mc "Old version"] -font uifont \ -command changediffdisp -variable diffelide -value {0 1} - radiobutton .bleft.mid.new -text "New version" -font uifont \ + radiobutton .bleft.mid.new -text [mc "New version"] -font uifont \ -command changediffdisp -variable diffelide -value {1 0} - label .bleft.mid.labeldiffcontext -text " Lines of context: " \ + label .bleft.mid.labeldiffcontext -text " [mc "Lines of context"]: " \ -font uifont pack .bleft.mid.diff .bleft.mid.old .bleft.mid.new -side left spinbox .bleft.mid.diffcontext -width 5 -font textfont \ @@ -895,10 +895,10 @@ proc makewindow {} { # lower right frame .bright frame .bright.mode - radiobutton .bright.mode.patch -text "Patch" \ + radiobutton .bright.mode.patch -text [mc "Patch"] \ -command reselectline -variable cmitmode -value "patch" .bright.mode.patch configure -font uifont - radiobutton .bright.mode.tree -text "Tree" \ + radiobutton .bright.mode.tree -text [mc "Tree"] \ -command reselectline -variable cmitmode -value "tree" .bright.mode.tree configure -font uifont grid .bright.mode.patch .bright.mode.tree -sticky ew @@ -1015,43 +1015,43 @@ proc makewindow {} { set rowctxmenu .rowctxmenu menu $rowctxmenu -tearoff 0 - $rowctxmenu add command -label "Diff this -> selected" \ + $rowctxmenu add command -label [mc "Diff this -> selected"] \ -command {diffvssel 0} - $rowctxmenu add command -label "Diff selected -> this" \ + $rowctxmenu add command -label [mc "Diff selected -> this"] \ -command {diffvssel 1} - $rowctxmenu add command -label "Make patch" -command mkpatch - $rowctxmenu add command -label "Create tag" -command mktag - $rowctxmenu add command -label "Write commit to file" -command writecommit - $rowctxmenu add command -label "Create new branch" -command mkbranch - $rowctxmenu add command -label "Cherry-pick this commit" \ + $rowctxmenu add command -label [mc "Make patch"] -command mkpatch + $rowctxmenu add command -label [mc "Create tag"] -command mktag + $rowctxmenu add command -label [mc "Write commit to file"] -command writecommit + $rowctxmenu add command -label [mc "Create new branch"] -command mkbranch + $rowctxmenu add command -label [mc "Cherry-pick this commit"] \ -command cherrypick - $rowctxmenu add command -label "Reset HEAD branch to here" \ + $rowctxmenu add command -label [mc "Reset HEAD branch to here"] \ -command resethead set fakerowmenu .fakerowmenu menu $fakerowmenu -tearoff 0 - $fakerowmenu add command -label "Diff this -> selected" \ + $fakerowmenu add command -label [mc "Diff this -> selected"] \ -command {diffvssel 0} - $fakerowmenu add command -label "Diff selected -> this" \ + $fakerowmenu add command -label [mc "Diff selected -> this"] \ -command {diffvssel 1} - $fakerowmenu add command -label "Make patch" -command mkpatch -# $fakerowmenu add command -label "Commit" -command {mkcommit 0} -# $fakerowmenu add command -label "Commit all" -command {mkcommit 1} -# $fakerowmenu add command -label "Revert local changes" -command revertlocal + $fakerowmenu add command -label [mc "Make patch"] -command mkpatch +# $fakerowmenu add command -label [mc "Commit"] -command {mkcommit 0} +# $fakerowmenu add command -label [mc "Commit all"] -command {mkcommit 1} +# $fakerowmenu add command -label [mc "Revert local changes"] -command revertlocal set headctxmenu .headctxmenu menu $headctxmenu -tearoff 0 - $headctxmenu add command -label "Check out this branch" \ + $headctxmenu add command -label [mc "Check out this branch"] \ -command cobranch - $headctxmenu add command -label "Remove this branch" \ + $headctxmenu add command -label [mc "Remove this branch"] \ -command rmbranch global flist_menu set flist_menu .flistctxmenu menu $flist_menu -tearoff 0 - $flist_menu add command -label "Highlight this too" \ + $flist_menu add command -label [mc "Highlight this too"] \ -command {flist_hl 0} - $flist_menu add command -label "Highlight this only" \ + $flist_menu add command -label [mc "Highlight this only"] \ -command {flist_hl 1} } @@ -1277,17 +1277,17 @@ proc about {} { return } toplevel $w - wm title $w "About gitk" - message $w.m -text { + wm title $w [mc "About gitk"] + message $w.m -text [mc " Gitk - a commit viewer for git Copyright © 2005-2006 Paul Mackerras -Use and redistribute under the terms of the GNU General Public License} \ +Use and redistribute under the terms of the GNU General Public License"] \ -justify center -aspect 400 -border 2 -bg white -relief groove pack $w.m -side top -fill x -padx 2 -pady 2 $w.m configure -font uifont - button $w.ok -text Close -command "destroy $w" -default active + button $w.ok -text [mc "Close"] -command "destroy $w" -default active pack $w.ok -side bottom $w.ok configure -font uifont bind $w "focus $w.ok" @@ -1308,8 +1308,8 @@ proc keys {} { set M1T Ctrl } toplevel $w - wm title $w "Gitk key bindings" - message $w.m -text " + wm title $w [mc "Gitk key bindings"] + message $w.m -text [mc " Gitk key bindings: <$M1T-Q> Quit @@ -1347,11 +1347,11 @@ f Scroll diff view to next file <$M1T-KP-> Decrease font size <$M1T-minus> Decrease font size Update -" \ +"] \ -justify left -bg white -border 2 -relief groove pack $w.m -side top -fill both -padx 2 -pady 2 $w.m configure -font uifont - button $w.ok -text Close -command "destroy $w" -default active + button $w.ok -text [mc "Close"] -command "destroy $w" -default active pack $w.ok -side bottom $w.ok configure -font uifont bind $w "focus $w.ok" @@ -1860,7 +1860,7 @@ proc newview {ishighlight} { set newviewname($nextviewnum) "View $nextviewnum" set newviewperm($nextviewnum) 0 set newviewargs($nextviewnum) [shellarglist $revtreeargs] - vieweditor $top $nextviewnum "Gitk view definition" + vieweditor $top $nextviewnum [mc "Gitk view definition"] } proc editview {} { @@ -1885,20 +1885,20 @@ proc vieweditor {top n title} { toplevel $top wm title $top $title - label $top.nl -text "Name" -font uifont + label $top.nl -text [mc "Name"] -font uifont entry $top.name -width 20 -textvariable newviewname($n) -font uifont grid $top.nl $top.name -sticky w -pady 5 - checkbutton $top.perm -text "Remember this view" -variable newviewperm($n) \ + checkbutton $top.perm -text [mc "Remember this view"] -variable newviewperm($n) \ -font uifont grid $top.perm - -pady 5 -sticky w message $top.al -aspect 1000 -font uifont \ - -text "Commits to include (arguments to git rev-list):" + -text [mc "Commits to include (arguments to git rev-list):"] grid $top.al - -sticky w -pady 5 entry $top.args -width 50 -textvariable newviewargs($n) \ -background white -font uifont grid $top.args - -sticky ew -padx 5 message $top.l -aspect 1000 -font uifont \ - -text "Enter files and directories to include, one per line:" + -text [mc "Enter files and directories to include, one per line:"] grid $top.l - -sticky w text $top.t -width 40 -height 10 -background white -font uifont if {[info exists viewfiles($n)]} { @@ -1911,9 +1911,9 @@ proc vieweditor {top n title} { } grid $top.t - -sticky ew -padx 5 frame $top.buts - button $top.buts.ok -text "OK" -command [list newviewok $top $n] \ + button $top.buts.ok -text [mc "OK"] -command [list newviewok $top $n] \ -font uifont - button $top.buts.can -text "Cancel" -command [list destroy $top] \ + button $top.buts.can -text [mc "Cancel"] -command [list destroy $top] \ -font uifont grid $top.buts.ok $top.buts.can grid columnconfigure $top.buts 0 -weight 1 -uniform a @@ -1947,7 +1947,7 @@ proc newviewok {top n} { if {[catch { set newargs [shellsplit $newviewargs($n)] } err]} { - error_popup "Error in commit selection arguments: $err" + error_popup "[mc "Error in commit selection arguments:"] $err" wm raise $top focus $top return @@ -2090,8 +2090,8 @@ proc showview {n} { set curview $n set selectedview $n - .bar.view entryconf Edit* -state [expr {$n == 0? "disabled": "normal"}] - .bar.view entryconf Delete* -state [expr {$n == 0? "disabled": "normal"}] + .bar.view entryconf [mc "Edit view..."] -state [expr {$n == 0? "disabled": "normal"}] + .bar.view entryconf [mc "Delete view"] -state [expr {$n == 0? "disabled": "normal"}] run refill_reflist if {![info exists viewdata($n)]} { @@ -2148,11 +2148,11 @@ proc showview {n} { } if {$phase ne {}} { if {$phase eq "getcommits"} { - show_status "Reading commits..." + show_status [mc "Reading commits..."] } run chewcommits $n } elseif {$numcommits == 0} { - show_status "No commits selected" + show_status [mc "No commits selected"] } } @@ -2880,7 +2880,7 @@ proc readdiffindex {fd serial} { if {$isdiff && $serial == $lserial && $localirow == -1} { # add the line for the changes in the index to the graph set localirow $commitrow($curview,$mainheadid) - set hl "Local changes checked in to index but not committed" + set hl [mc "Local changes checked in to index but not committed"] set commitinfo($nullid2) [list $hl {} {} {} {} " $hl\n"] set commitdata($nullid2) "\n $hl\n" insertrow $localirow $nullid2 @@ -2910,7 +2910,7 @@ proc readdifffiles {fd serial} { } else { set localfrow $commitrow($curview,$mainheadid) } - set hl "Local uncommitted changes, not checked in to index" + set hl [mc "Local uncommitted changes, not checked in to index"] set commitinfo($nullid) [list $hl {} {} {} {} " $hl\n"] set commitdata($nullid) "\n $hl\n" insertrow $localfrow $nullid @@ -4716,11 +4716,11 @@ proc selectline {l isnew} { set linknum 0 set info $commitinfo($id) set date [formatdate [lindex $info 2]] - $ctext insert end "Author: [lindex $info 1] $date\n" + $ctext insert end "[mc "Author"]: [lindex $info 1] $date\n" set date [formatdate [lindex $info 4]] - $ctext insert end "Committer: [lindex $info 3] $date\n" + $ctext insert end "[mc "Committer"]: [lindex $info 3] $date\n" if {[info exists idtags($id)]} { - $ctext insert end "Tags:" + $ctext insert end [mc "Tags:"] foreach tag $idtags($id) { $ctext insert end " $tag" } @@ -4737,18 +4737,18 @@ proc selectline {l isnew} { } else { set tag m$np } - $ctext insert end "Parent: " $tag + $ctext insert end "[mc "Parent"]: " $tag appendwithlinks [commit_descriptor $p] {} incr np } } else { foreach p $olds { - append headers "Parent: [commit_descriptor $p]" + append headers "[mc "Parent"]: [commit_descriptor $p]" } } foreach c $children($curview,$id) { - append headers "Child: [commit_descriptor $c]" + append headers "[mc "Child"]: [commit_descriptor $c]" } # make anything that looks like a SHA1 ID be a clickable link @@ -4757,13 +4757,13 @@ proc selectline {l isnew} { if {![info exists allcommits]} { getallcommits } - $ctext insert end "Branch: " + $ctext insert end "[mc "Branch"]: " $ctext mark set branch "end -1c" $ctext mark gravity branch left - $ctext insert end "\nFollows: " + $ctext insert end "\n[mc "Follows"]: " $ctext mark set follows "end -1c" $ctext mark gravity follows left - $ctext insert end "\nPrecedes: " + $ctext insert end "\n[mc "Precedes"]: " $ctext mark set precedes "end -1c" $ctext mark gravity precedes left $ctext insert end "\n" @@ -5045,7 +5045,7 @@ proc mergediff {id l} { set cmd [concat $cmd -- $viewfiles($curview)] } if {[catch {set mdf [open $cmd r]} err]} { - error_popup "Error getting merge diffs: $err" + error_popup "[mc "Error getting merge diffs:"] $err" return } fconfigure $mdf -blocking 0 @@ -5722,9 +5722,9 @@ proc sha1change {n1 n2 op} { } if {[$sha1but cget -state] == $state} return if {$state == "normal"} { - $sha1but conf -state normal -relief raised -text "Goto: " + $sha1but conf -state normal -relief raised -text "[mc "Goto:"] " } else { - $sha1but conf -state disabled -relief flat -text "SHA1 ID: " + $sha1but conf -state disabled -relief flat -text "[mc "SHA1 ID:"] " } } @@ -5749,7 +5749,7 @@ proc gotocommit {} { } if {$matches ne {}} { if {[llength $matches] > 1} { - error_popup "Short SHA1 id $id is ambiguous" + error_popup [mc "Short SHA1 id %s is ambiguous" $id] return } set id [lindex $matches 0] @@ -5761,11 +5761,11 @@ proc gotocommit {} { return } if {[regexp {^[0-9a-fA-F]{4,}$} $sha1string]} { - set type "SHA1 id" + set msg [mc "SHA1 id %s is not known" $sha1string] } else { - set type "Tag/Head" + set msg [mc "Tag/Head %s is not known" $sha1string] } - error_popup "$type $sha1string is not known" + error_popup $msg } proc lineenter {x y id} { @@ -5895,17 +5895,17 @@ proc lineclick {x y id isnew} { $ctext conf -state normal clear_ctext settabs 0 - $ctext insert end "Parent:\t" + $ctext insert end "[mc "Parent"]:\t" $ctext insert end $id link0 setlink $id link0 set info $commitinfo($id) $ctext insert end "\n\t[lindex $info 0]\n" - $ctext insert end "\tAuthor:\t[lindex $info 1]\n" + $ctext insert end "\t[mc "Author"]:\t[lindex $info 1]\n" set date [formatdate [lindex $info 2]] - $ctext insert end "\tDate:\t$date\n" + $ctext insert end "\t[mc "Date"]:\t$date\n" set kids $children($curview,$id) if {$kids ne {}} { - $ctext insert end "\nChildren:" + $ctext insert end "\n[mc "Children"]:" set i 0 foreach child $kids { incr i @@ -5915,9 +5915,9 @@ proc lineclick {x y id isnew} { $ctext insert end $child link$i setlink $child link$i $ctext insert end "\n\t[lindex $info 0]" - $ctext insert end "\n\tAuthor:\t[lindex $info 1]" + $ctext insert end "\n\t[mc "Author"]:\t[lindex $info 1]" set date [formatdate [lindex $info 2]] - $ctext insert end "\n\tDate:\t$date\n" + $ctext insert end "\n\t[mc "Date"]:\t$date\n" } } $ctext conf -state disabled @@ -5962,13 +5962,13 @@ proc rowmenu {x y id} { } if {$id ne $nullid && $id ne $nullid2} { set menu $rowctxmenu - $menu entryconfigure 7 -label "Reset $mainhead branch to here" + $menu entryconfigure 7 -label [mc "Reset %s branch to here" $mainhead] } else { set menu $fakerowmenu } - $menu entryconfigure "Diff this*" -state $state - $menu entryconfigure "Diff selected*" -state $state - $menu entryconfigure "Make patch" -state $state + $menu entryconfigure [mc "Diff this -> selected"] -state $state + $menu entryconfigure [mc "Diff selected -> this"] -state $state + $menu entryconfigure [mc "Make patch"] -state $state tk_popup $menu $x $y } @@ -5993,13 +5993,13 @@ proc doseldiff {oldid newid} { $ctext conf -state normal clear_ctext - init_flist "Top" - $ctext insert end "From " + init_flist [mc "Top"] + $ctext insert end "[mc "From"] " $ctext insert end $oldid link0 setlink $oldid link0 $ctext insert end "\n " $ctext insert end [lindex $commitinfo($oldid) 0] - $ctext insert end "\n\nTo " + $ctext insert end "\n\n[mc "To"] " $ctext insert end $newid link1 setlink $newid link1 $ctext insert end "\n " @@ -6022,9 +6022,9 @@ proc mkpatch {} { set patchtop $top catch {destroy $top} toplevel $top - label $top.title -text "Generate patch" + label $top.title -text [mc "Generate patch"] grid $top.title - -pady 10 - label $top.from -text "From:" + label $top.from -text [mc "From:"] entry $top.fromsha1 -width 40 -relief flat $top.fromsha1 insert 0 $oldid $top.fromsha1 conf -state readonly @@ -6033,7 +6033,7 @@ proc mkpatch {} { $top.fromhead insert 0 $oldhead $top.fromhead conf -state readonly grid x $top.fromhead -sticky w - label $top.to -text "To:" + label $top.to -text [mc "To:"] entry $top.tosha1 -width 40 -relief flat $top.tosha1 insert 0 $newid $top.tosha1 conf -state readonly @@ -6042,16 +6042,16 @@ proc mkpatch {} { $top.tohead insert 0 $newhead $top.tohead conf -state readonly grid x $top.tohead -sticky w - button $top.rev -text "Reverse" -command mkpatchrev -padx 5 + button $top.rev -text [mc "Reverse"] -command mkpatchrev -padx 5 grid $top.rev x -pady 10 - label $top.flab -text "Output file:" + label $top.flab -text [mc "Output file:"] entry $top.fname -width 60 $top.fname insert 0 [file normalize "patch$patchnum.patch"] incr patchnum grid $top.flab $top.fname -sticky w frame $top.buts - button $top.buts.gen -text "Generate" -command mkpatchgo - button $top.buts.can -text "Cancel" -command mkpatchcan + button $top.buts.gen -text [mc "Generate"] -command mkpatchgo + button $top.buts.can -text [mc "Cancel"] -command mkpatchcan grid $top.buts.gen $top.buts.can grid columnconfigure $top.buts 0 -weight 1 -uniform a grid columnconfigure $top.buts 1 -weight 1 -uniform a @@ -6086,7 +6086,7 @@ proc mkpatchgo {} { set cmd [lrange $cmd 1 end] lappend cmd >$fname & if {[catch {eval exec $cmd} err]} { - error_popup "Error creating patch: $err" + error_popup "[mc "Error creating patch:"] $err" } catch {destroy $patchtop} unset patchtop @@ -6106,9 +6106,9 @@ proc mktag {} { set mktagtop $top catch {destroy $top} toplevel $top - label $top.title -text "Create tag" + label $top.title -text [mc "Create tag"] grid $top.title - -pady 10 - label $top.id -text "ID:" + label $top.id -text [mc "ID:"] entry $top.sha1 -width 40 -relief flat $top.sha1 insert 0 $rowmenuid $top.sha1 conf -state readonly @@ -6117,12 +6117,12 @@ proc mktag {} { $top.head insert 0 [lindex $commitinfo($rowmenuid) 0] $top.head conf -state readonly grid x $top.head -sticky w - label $top.tlab -text "Tag name:" + label $top.tlab -text [mc "Tag name:"] entry $top.tag -width 60 grid $top.tlab $top.tag -sticky w frame $top.buts - button $top.buts.gen -text "Create" -command mktaggo - button $top.buts.can -text "Cancel" -command mktagcan + button $top.buts.gen -text [mc "Create"] -command mktaggo + button $top.buts.can -text [mc "Cancel"] -command mktagcan grid $top.buts.gen $top.buts.can grid columnconfigure $top.buts 0 -weight 1 -uniform a grid columnconfigure $top.buts 1 -weight 1 -uniform a @@ -6136,11 +6136,11 @@ proc domktag {} { set id [$mktagtop.sha1 get] set tag [$mktagtop.tag get] if {$tag == {}} { - error_popup "No tag name specified" + error_popup [mc "No tag name specified"] return } if {[info exists tagids($tag)]} { - error_popup "Tag \"$tag\" already exists" + error_popup [mc "Tag \"%s\" already exists" $tag] return } if {[catch { @@ -6150,7 +6150,7 @@ proc domktag {} { puts $f $id close $f } err]} { - error_popup "Error creating tag: $err" + error_popup "[mc "Error creating tag:"] $err" return } @@ -6203,9 +6203,9 @@ proc writecommit {} { set wrcomtop $top catch {destroy $top} toplevel $top - label $top.title -text "Write commit to file" + label $top.title -text [mc "Write commit to file"] grid $top.title - -pady 10 - label $top.id -text "ID:" + label $top.id -text [mc "ID:"] entry $top.sha1 -width 40 -relief flat $top.sha1 insert 0 $rowmenuid $top.sha1 conf -state readonly @@ -6214,16 +6214,16 @@ proc writecommit {} { $top.head insert 0 [lindex $commitinfo($rowmenuid) 0] $top.head conf -state readonly grid x $top.head -sticky w - label $top.clab -text "Command:" + label $top.clab -text [mc "Command:"] entry $top.cmd -width 60 -textvariable wrcomcmd grid $top.clab $top.cmd -sticky w -pady 10 - label $top.flab -text "Output file:" + label $top.flab -text [mc "Output file:"] entry $top.fname -width 60 $top.fname insert 0 [file normalize "commit-[string range $rowmenuid 0 6]"] grid $top.flab $top.fname -sticky w frame $top.buts - button $top.buts.gen -text "Write" -command wrcomgo - button $top.buts.can -text "Cancel" -command wrcomcan + button $top.buts.gen -text [mc "Write"] -command wrcomgo + button $top.buts.can -text [mc "Cancel"] -command wrcomcan grid $top.buts.gen $top.buts.can grid columnconfigure $top.buts 0 -weight 1 -uniform a grid columnconfigure $top.buts 1 -weight 1 -uniform a @@ -6238,7 +6238,7 @@ proc wrcomgo {} { set cmd "echo $id | [$wrcomtop.cmd get]" set fname [$wrcomtop.fname get] if {[catch {exec sh -c $cmd >$fname &} err]} { - error_popup "Error writing commit: $err" + error_popup "[mc "Error writing commit:"] $err" } catch {destroy $wrcomtop} unset wrcomtop @@ -6257,19 +6257,19 @@ proc mkbranch {} { set top .makebranch catch {destroy $top} toplevel $top - label $top.title -text "Create new branch" + label $top.title -text [mc "Create new branch"] grid $top.title - -pady 10 - label $top.id -text "ID:" + label $top.id -text [mc "ID:"] entry $top.sha1 -width 40 -relief flat $top.sha1 insert 0 $rowmenuid $top.sha1 conf -state readonly grid $top.id $top.sha1 -sticky w - label $top.nlab -text "Name:" + label $top.nlab -text [mc "Name:"] entry $top.name -width 40 grid $top.nlab $top.name -sticky w frame $top.buts - button $top.buts.go -text "Create" -command [list mkbrgo $top] - button $top.buts.can -text "Cancel" -command "catch {destroy $top}" + button $top.buts.go -text [mc "Create"] -command [list mkbrgo $top] + button $top.buts.can -text [mc "Cancel"] -command "catch {destroy $top}" grid $top.buts.go $top.buts.can grid columnconfigure $top.buts 0 -weight 1 -uniform a grid columnconfigure $top.buts 1 -weight 1 -uniform a @@ -6283,7 +6283,7 @@ proc mkbrgo {top} { set name [$top.name get] set id [$top.sha1 get] if {$name eq {}} { - error_popup "Please specify a name for the new branch" + error_popup [mc "Please specify a name for the new branch"] return } catch {destroy $top} @@ -6312,11 +6312,12 @@ proc cherrypick {} { set oldhead [exec git rev-parse HEAD] set dheads [descheads $rowmenuid] if {$dheads ne {} && [lsearch -exact $dheads $oldhead] >= 0} { - set ok [confirm_popup "Commit [string range $rowmenuid 0 7] is already\ - included in branch $mainhead -- really re-apply it?"] + set ok [confirm_popup [mc "Commit %s is already\ + included in branch %s -- really re-apply it?" \ + [string range $rowmenuid 0 7] $mainhead]] if {!$ok} return } - nowbusy cherrypick "Cherry-picking" + nowbusy cherrypick [mc "Cherry-picking"] update # Unfortunately git-cherry-pick writes stuff to stderr even when # no error occurs, and exec takes that as an indication of error... @@ -6328,7 +6329,7 @@ proc cherrypick {} { set newhead [exec git rev-parse HEAD] if {$newhead eq $oldhead} { notbusy cherrypick - error_popup "No changes committed" + error_popup [mc "No changes committed"] return } addnewchild $newhead $oldhead @@ -6351,28 +6352,28 @@ proc resethead {} { set w ".confirmreset" toplevel $w wm transient $w . - wm title $w "Confirm reset" + wm title $w [mc "Confirm reset"] message $w.m -text \ - "Reset branch $mainhead to [string range $rowmenuid 0 7]?" \ + [mc "Reset branch %s to %s?" $mainhead [string range $rowmenuid 0 7]] \ -justify center -aspect 1000 pack $w.m -side top -fill x -padx 20 -pady 20 frame $w.f -relief sunken -border 2 - message $w.f.rt -text "Reset type:" -aspect 1000 + message $w.f.rt -text [mc "Reset type:"] -aspect 1000 grid $w.f.rt -sticky w set resettype mixed radiobutton $w.f.soft -value soft -variable resettype -justify left \ - -text "Soft: Leave working tree and index untouched" + -text [mc "Soft: Leave working tree and index untouched"] grid $w.f.soft -sticky w radiobutton $w.f.mixed -value mixed -variable resettype -justify left \ - -text "Mixed: Leave working tree untouched, reset index" + -text [mc "Mixed: Leave working tree untouched, reset index"] grid $w.f.mixed -sticky w radiobutton $w.f.hard -value hard -variable resettype -justify left \ - -text "Hard: Reset working tree and index\n(discard ALL local changes)" + -text [mc "Hard: Reset working tree and index\n(discard ALL local changes)"] grid $w.f.hard -sticky w pack $w.f -side top -fill x - button $w.ok -text OK -command "set confirm_ok 1; destroy $w" + button $w.ok -text [mc OK] -command "set confirm_ok 1; destroy $w" pack $w.ok -side left -fill x -padx 20 -pady 20 - button $w.cancel -text Cancel -command "destroy $w" + button $w.cancel -text [mc Cancel] -command "destroy $w" pack $w.cancel -side right -fill x -padx 20 -pady 20 bind $w "grab $w; focus $w" tkwait window $w @@ -6383,7 +6384,7 @@ proc resethead {} { } else { dohidelocalchanges filerun $fd [list readresetstat $fd] - nowbusy reset "Resetting" + nowbusy reset [mc "Resetting"] } } @@ -6440,7 +6441,7 @@ proc cobranch {} { # check the tree is clean first?? set oldmainhead $mainhead - nowbusy checkout "Checking out" + nowbusy checkout [mc "Checking out"] update dohidelocalchanges if {[catch { @@ -6470,14 +6471,14 @@ proc rmbranch {} { set id $headmenuid # this check shouldn't be needed any more... if {$head eq $mainhead} { - error_popup "Cannot delete the currently checked-out branch" + error_popup [mc "Cannot delete the currently checked-out branch"] return } set dheads [descheads $id] if {[llength $dheads] == 1 && $idheads($dheads) eq $head} { # the stuff on this branch isn't on any other branch - if {![confirm_popup "The commits on branch $head aren't on any other\ - branch.\nReally delete branch $head?"]} return + if {![confirm_popup [mc "The commits on branch %s aren't on any other\ + branch.\nReally delete branch %s?" $head $head]]} return } nowbusy rmbranch update @@ -6507,7 +6508,7 @@ proc showrefs {} { return } toplevel $top - wm title $top "Tags and heads: [file tail [pwd]]" + wm title $top [mc "Tags and heads: %s" [file tail [pwd]]] text $top.list -background $bgcolor -foreground $fgcolor \ -selectbackground $selectbgcolor -font mainfont \ -xscrollcommand "$top.xsb set" -yscrollcommand "$top.ysb set" \ @@ -6521,14 +6522,14 @@ proc showrefs {} { grid $top.list $top.ysb -sticky nsew grid $top.xsb x -sticky ew frame $top.f - label $top.f.l -text "Filter: " -font uifont + label $top.f.l -text "[mc "Filter"]: " -font uifont entry $top.f.e -width 20 -textvariable reflistfilter -font uifont set reflistfilter "*" trace add variable reflistfilter write reflistfilter_change pack $top.f.e -side right -fill x -expand 1 pack $top.f.l -side left grid $top.f - -sticky ew -pady 2 - button $top.close -command [list destroy $top] -text "Close" \ + button $top.close -command [list destroy $top] -text [mc "Close"] \ -font uifont grid $top.close - grid columnconfigure $top 0 -weight 1 @@ -6816,9 +6817,9 @@ proc getallclines {fd} { dropcache $err return } - error_popup "Error reading commit topology information;\ + error_popup "[mc "Error reading commit topology information;\ branch and preceding/following tag information\ - will be incomplete.\n($err)" + will be incomplete."]\n($err)" set cacheok 0 } if {[incr allcommits -1] == 0} { @@ -7800,7 +7801,7 @@ proc showtag {tag isnew} { if {[info exists tagcontents($tag)]} { set text $tagcontents($tag) } else { - set text "Tag: $tag\nId: $tagids($tag)" + set text "[mc "Tag"]: $tag\n[mc "Id"]: $tagids($tag)" } appendwithlinks $text {} $ctext conf -state disabled @@ -7840,7 +7841,7 @@ proc choosefont {font which} { font create sample eval font config sample [font actual $font] toplevel $top - wm title $top "Gitk font chooser" + wm title $top [mc "Gitk font chooser"] label $top.l -textvariable fontparam(which) -font uifont pack $top.l -side top set fontlist [lsort [font families]] @@ -7857,10 +7858,10 @@ proc choosefont {font which} { -textvariable fontparam(size) \ -validatecommand {string is integer -strict %s} checkbutton $top.g.bold -padx 5 \ - -font {{Times New Roman} 12 bold} -text "B" -indicatoron 0 \ + -font {{Times New Roman} 12 bold} -text [mc "B"] -indicatoron 0 \ -variable fontparam(weight) -onvalue bold -offvalue normal checkbutton $top.g.ital -padx 5 \ - -font {{Times New Roman} 12 italic} -text "I" -indicatoron 0 \ + -font {{Times New Roman} 12 italic} -text [mc "I"] -indicatoron 0 \ -variable fontparam(slant) -onvalue italic -offvalue roman pack $top.g.size $top.g.bold $top.g.ital -side left pack $top.g -side top @@ -7871,9 +7872,9 @@ proc choosefont {font which} { bind $top.c [list centertext $top.c] pack $top.c -side top -fill x frame $top.buts - button $top.buts.ok -text "OK" -command fontok -default active \ + button $top.buts.ok -text [mc "OK"] -command fontok -default active \ -font uifont - button $top.buts.can -text "Cancel" -command fontcan -default normal \ + button $top.buts.can -text [mc "Cancel"] -command fontcan -default normal \ -font uifont grid $top.buts.ok $top.buts.can grid columnconfigure $top.buts 0 -weight 1 -uniform a @@ -7955,85 +7956,85 @@ proc doprefs {} { set oldprefs($v) [set $v] } toplevel $top - wm title $top "Gitk preferences" - label $top.ldisp -text "Commit list display options" + wm title $top [mc "Gitk preferences"] + label $top.ldisp -text [mc "Commit list display options"] $top.ldisp configure -font uifont grid $top.ldisp - -sticky w -pady 10 label $top.spacer -text " " - label $top.maxwidthl -text "Maximum graph width (lines)" \ + label $top.maxwidthl -text [mc "Maximum graph width (lines)"] \ -font optionfont spinbox $top.maxwidth -from 0 -to 100 -width 4 -textvariable maxwidth grid $top.spacer $top.maxwidthl $top.maxwidth -sticky w - label $top.maxpctl -text "Maximum graph width (% of pane)" \ + label $top.maxpctl -text [mc "Maximum graph width (% of pane)"] \ -font optionfont spinbox $top.maxpct -from 1 -to 100 -width 4 -textvariable maxgraphpct grid x $top.maxpctl $top.maxpct -sticky w frame $top.showlocal - label $top.showlocal.l -text "Show local changes" -font optionfont + label $top.showlocal.l -text [mc "Show local changes"] -font optionfont checkbutton $top.showlocal.b -variable showlocalchanges pack $top.showlocal.b $top.showlocal.l -side left grid x $top.showlocal -sticky w - label $top.ddisp -text "Diff display options" + label $top.ddisp -text [mc "Diff display options"] $top.ddisp configure -font uifont grid $top.ddisp - -sticky w -pady 10 - label $top.tabstopl -text "Tab spacing" -font optionfont + label $top.tabstopl -text [mc "Tab spacing"] -font optionfont spinbox $top.tabstop -from 1 -to 20 -width 4 -textvariable tabstop grid x $top.tabstopl $top.tabstop -sticky w frame $top.ntag - label $top.ntag.l -text "Display nearby tags" -font optionfont + label $top.ntag.l -text [mc "Display nearby tags"] -font optionfont checkbutton $top.ntag.b -variable showneartags pack $top.ntag.b $top.ntag.l -side left grid x $top.ntag -sticky w frame $top.ldiff - label $top.ldiff.l -text "Limit diffs to listed paths" -font optionfont + label $top.ldiff.l -text [mc "Limit diffs to listed paths"] -font optionfont checkbutton $top.ldiff.b -variable limitdiffs pack $top.ldiff.b $top.ldiff.l -side left grid x $top.ldiff -sticky w - label $top.cdisp -text "Colors: press to choose" + label $top.cdisp -text [mc "Colors: press to choose"] $top.cdisp configure -font uifont grid $top.cdisp - -sticky w -pady 10 label $top.bg -padx 40 -relief sunk -background $bgcolor - button $top.bgbut -text "Background" -font optionfont \ + button $top.bgbut -text [mc "Background"] -font optionfont \ -command [list choosecolor bgcolor 0 $top.bg background setbg] grid x $top.bgbut $top.bg -sticky w label $top.fg -padx 40 -relief sunk -background $fgcolor - button $top.fgbut -text "Foreground" -font optionfont \ + button $top.fgbut -text [mc "Foreground"] -font optionfont \ -command [list choosecolor fgcolor 0 $top.fg foreground setfg] grid x $top.fgbut $top.fg -sticky w label $top.diffold -padx 40 -relief sunk -background [lindex $diffcolors 0] - button $top.diffoldbut -text "Diff: old lines" -font optionfont \ + button $top.diffoldbut -text [mc "Diff: old lines"] -font optionfont \ -command [list choosecolor diffcolors 0 $top.diffold "diff old lines" \ [list $ctext tag conf d0 -foreground]] grid x $top.diffoldbut $top.diffold -sticky w label $top.diffnew -padx 40 -relief sunk -background [lindex $diffcolors 1] - button $top.diffnewbut -text "Diff: new lines" -font optionfont \ + button $top.diffnewbut -text [mc "Diff: new lines"] -font optionfont \ -command [list choosecolor diffcolors 1 $top.diffnew "diff new lines" \ [list $ctext tag conf d1 -foreground]] grid x $top.diffnewbut $top.diffnew -sticky w label $top.hunksep -padx 40 -relief sunk -background [lindex $diffcolors 2] - button $top.hunksepbut -text "Diff: hunk header" -font optionfont \ + button $top.hunksepbut -text [mc "Diff: hunk header"] -font optionfont \ -command [list choosecolor diffcolors 2 $top.hunksep \ "diff hunk header" \ [list $ctext tag conf hunksep -foreground]] grid x $top.hunksepbut $top.hunksep -sticky w label $top.selbgsep -padx 40 -relief sunk -background $selectbgcolor - button $top.selbgbut -text "Select bg" -font optionfont \ + button $top.selbgbut -text [mc "Select bg"] -font optionfont \ -command [list choosecolor selectbgcolor 0 $top.selbgsep background setselbg] grid x $top.selbgbut $top.selbgsep -sticky w - label $top.cfont -text "Fonts: press to choose" + label $top.cfont -text [mc "Fonts: press to choose"] $top.cfont configure -font uifont grid $top.cfont - -sticky w -pady 10 - mkfontdisp mainfont $top "Main font" - mkfontdisp textfont $top "Diff display font" - mkfontdisp uifont $top "User interface font" + mkfontdisp mainfont $top [mc "Main font"] + mkfontdisp textfont $top [mc "Diff display font"] + mkfontdisp uifont $top [mc "User interface font"] frame $top.buts - button $top.buts.ok -text "OK" -command prefsok -default active + button $top.buts.ok -text [mc "OK"] -command prefsok -default active $top.buts.ok configure -font uifont - button $top.buts.can -text "Cancel" -command prefscan -default normal + button $top.buts.can -text [mc "Cancel"] -command prefscan -default normal $top.buts.can configure -font uifont grid $top.buts.ok $top.buts.can grid columnconfigure $top.buts 0 -weight 1 -uniform a @@ -8046,7 +8047,7 @@ proc choosecolor {v vi w x cmd} { global $v set c [tk_chooseColor -initialcolor [lindex [set $v] $vi] \ - -title "Gitk: choose color for $x"] + -title [mc "Gitk: choose color for %s" $x]] if {$c eq {}} return $w conf -background $c lset $v $vi $c @@ -8427,8 +8428,8 @@ proc tcl_encoding {enc} { # First check that Tcl/Tk is recent enough if {[catch {package require Tk 8.4} err]} { - show_error {} . "Sorry, gitk cannot run with this version of Tcl/Tk.\n\ - Gitk requires at least Tcl/Tk 8.4." + show_error {} . [mc "Sorry, gitk cannot run with this version of Tcl/Tk.\n\ + Gitk requires at least Tcl/Tk 8.4."] exit 1 } @@ -8512,11 +8513,11 @@ eval font create uifont [fontflags uifont] # check that we can find a .git directory somewhere... if {[catch {set gitdir [gitdir]}]} { - show_error {} . "Cannot find a git repository here." + show_error {} . [mc "Cannot find a git repository here."] exit 1 } if {![file isdirectory $gitdir]} { - show_error {} . "Cannot find the git directory \"$gitdir\"." + show_error {} . [mc "Cannot find the git directory \"%s\"." $gitdir] exit 1 } @@ -8555,8 +8556,8 @@ if {$i >= [llength $argv] && $revtreeargs ne {}} { # with git log and git rev-list, check revtreeargs for filenames. foreach arg $revtreeargs { if {[file exists $arg]} { - show_error {} . "Ambiguous argument '$arg': both revision\ - and filename" + show_error {} . [mc "Ambiguous argument '%s': both revision\ + and filename" $arg] exit 1 } } @@ -8567,7 +8568,7 @@ if {$i >= [llength $argv] && $revtreeargs ne {}} { if {$i > 0} { set err [string range $err [expr {$i + 6}] end] } - show_error {} . "Bad arguments to gitk:\n$err" + show_error {} . "[mc "Bad arguments to gitk:"]\n$err" exit 1 } } @@ -8579,7 +8580,7 @@ if {$mergeonly} { if {[catch { set fd [open "| git ls-files -u" r] } err]} { - show_error {} . "Couldn't get list of unmerged files: $err" + show_error {} . "[mc "Couldn't get list of unmerged files:"] $err" exit 1 } while {[gets $fd line] >= 0} { @@ -8595,11 +8596,11 @@ if {$mergeonly} { catch {close $fd} if {$mlist eq {}} { if {$nr_unmerged == 0} { - show_error {} . "No files selected: --merge specified but\ - no files are unmerged." + show_error {} . [mc "No files selected: --merge specified but\ + no files are unmerged."] } else { - show_error {} . "No files selected: --merge specified but\ - no unmerged files are within file limit." + show_error {} . [mc "No files selected: --merge specified but\ + no unmerged files are within file limit."] } exit 1 } @@ -8657,13 +8658,13 @@ if {$cmdline_files ne {} || $revtreeargs ne {}} { set curview 1 set selectedview 1 set nextviewnum 2 - set viewname(1) "Command line" + set viewname(1) [mc "Command line"] set viewfiles(1) $cmdline_files set viewargs(1) $revtreeargs set viewperm(1) 0 addviewmenu 1 - .bar.view entryconf Edit* -state normal - .bar.view entryconf Delete* -state normal + .bar.view entryconf [mc "Edit view..."] -state normal + .bar.view entryconf [mc "Delete view"] -state normal } if {[info exists permviews]} { From 15bc7bae91e69dc1c1f85e6acc740bf57f7b554a Mon Sep 17 00:00:00 2001 From: Christian Stimming Date: Wed, 7 Nov 2007 18:44:02 +0100 Subject: [PATCH 07/93] [PATCH] gitk i18n: Initial German translation Signed-off-by: Christian Stimming Signed-off-by: Paul Mackerras --- po/de.po | 703 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 703 insertions(+) create mode 100644 po/de.po diff --git a/po/de.po b/po/de.po new file mode 100644 index 0000000000..a4fdf9a6b9 --- /dev/null +++ b/po/de.po @@ -0,0 +1,703 @@ +# Translation of gitk to German. +# Copyright (C) 2007 Paul Mackerras and Christian Stimming. +# This file is distributed under the same license as the git package. +# Christian Stimming , 2007 +# +msgid "" +msgstr "" +"Project-Id-Version: git-gui\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2007-11-07 12:27+0100\n" +"PO-Revision-Date: 2007-11-07 12:36+0100\n" +"Last-Translator: Christian Stimming \n" +"Language-Team: German\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: gitk:101 +msgid "Error executing git rev-list:" +msgstr "" + +#: gitk:114 +msgid "Reading" +msgstr "Lesen" + +#: gitk:141 gitk:2151 +msgid "Reading commits..." +msgstr "Versionen lesen..." + +#: gitk:264 +msgid "Can't parse git log output:" +msgstr "Git log Ausgabe kann nicht erkannt werden:" + +#: gitk:375 gitk:2155 +msgid "No commits selected" +msgstr "Keine Versionen ausgewählt." + +#: gitk:486 +msgid "No commit information available" +msgstr "" + +#: gitk:585 gitk:607 gitk:1914 gitk:6374 gitk:7875 gitk:8035 +msgid "OK" +msgstr "Ok" + +#: gitk:609 gitk:1916 gitk:6054 gitk:6125 gitk:6226 gitk:6272 gitk:6376 +#: gitk:7877 gitk:8037 +msgid "Cancel" +msgstr "Abbrechen" + +#: gitk:633 +msgid "File" +msgstr "Datei" + +#: gitk:636 +msgid "Update" +msgstr "Aktualisieren" + +#: gitk:637 +msgid "Reread references" +msgstr "Zweige neu laden" + +#: gitk:638 +msgid "List references" +msgstr "Zweige auflisten" + +#: gitk:639 +msgid "Quit" +msgstr "Beenden" + +#: gitk:642 +msgid "Edit" +msgstr "Bearbeiten" + +#: gitk:643 +msgid "Preferences" +msgstr "Einstellungen" + +#: gitk:647 +msgid "View" +msgstr "Ansicht" + +#: gitk:648 +msgid "New view..." +msgstr "Neue Ansicht..." + +#: gitk:649 gitk:2093 gitk:8666 +msgid "Edit view..." +msgstr "Ansicht bearbeiten..." + +#: gitk:651 gitk:2094 gitk:8667 +msgid "Delete view" +msgstr "Ansicht löschen" + +#: gitk:653 +msgid "All files" +msgstr "Alle Dateien" + +#: gitk:657 +msgid "Help" +msgstr "Hilfe" + +#: gitk:658 gitk:1280 +msgid "About gitk" +msgstr "Über gitk" + +#: gitk:659 +msgid "Key bindings" +msgstr "Tastenkürzel" + +#: gitk:716 +msgid "SHA1 ID: " +msgstr "" + +#: gitk:766 +msgid "Find" +msgstr "Suche" + +#: gitk:767 +msgid "next" +msgstr "nächste" + +#: gitk:768 +msgid "prev" +msgstr "vorige" + +#: gitk:769 +msgid "commit" +msgstr "Version" + +#: gitk:772 gitk:774 gitk:2316 gitk:2339 gitk:2363 gitk:4265 gitk:4328 +msgid "containing:" +msgstr "enthaltend:" + +#: gitk:775 gitk:1746 gitk:1751 gitk:2391 +msgid "touching paths:" +msgstr "Pfad betreffend:" + +#: gitk:776 gitk:2396 +msgid "adding/removing string:" +msgstr "String dazu/löschen:" + +#: gitk:787 gitk:789 +msgid "Exact" +msgstr "Exakt" + +#: gitk:789 gitk:2474 gitk:4233 +msgid "IgnCase" +msgstr "Kein Groß/Klein" + +#: gitk:789 gitk:2365 gitk:2472 gitk:4229 +msgid "Regexp" +msgstr "Regexp" + +#: gitk:793 gitk:794 gitk:2493 gitk:2523 gitk:2530 gitk:4339 gitk:4395 +msgid "All fields" +msgstr "Alle Felder" + +#: gitk:794 gitk:2491 gitk:2523 gitk:4295 +msgid "Headline" +msgstr "Überschrift" + +#: gitk:795 gitk:2491 gitk:4295 gitk:4395 gitk:4783 +msgid "Comments" +msgstr "Beschreibung" + +#: gitk:795 gitk:2491 gitk:2495 gitk:2530 gitk:4295 gitk:4719 gitk:5903 +#: gitk:5918 +msgid "Author" +msgstr "Autor" + +#: gitk:795 gitk:2491 gitk:4295 gitk:4721 +msgid "Committer" +msgstr "Eintragender" + +#: gitk:825 +msgid "Search" +msgstr "Suche" + +#: gitk:833 +msgid "Diff" +msgstr "Vergleich" + +#: gitk:835 +msgid "Old version" +msgstr "Alte Version" + +#: gitk:837 +msgid "New version" +msgstr "Neue Version" + +#: gitk:839 +msgid "Lines of context" +msgstr "Kontextzeilen" + +#: gitk:898 +msgid "Patch" +msgstr "" + +#: gitk:901 +msgid "Tree" +msgstr "Baum" + +#: gitk:1018 gitk:1033 gitk:5969 +msgid "Diff this -> selected" +msgstr "Vergleich diese -> gewählte" + +#: gitk:1020 gitk:1035 gitk:5970 +msgid "Diff selected -> this" +msgstr "Vergleich gewählte -> diese" + +#: gitk:1022 gitk:1037 gitk:5971 +msgid "Make patch" +msgstr "Patch erstellen" + +#: gitk:1023 gitk:6109 +msgid "Create tag" +msgstr "Markierung erstellen" + +#: gitk:1024 gitk:6206 +msgid "Write commit to file" +msgstr "Version in Datei schreiben" + +#: gitk:1025 gitk:6260 +msgid "Create new branch" +msgstr "Neuen Zweig erstellen" + +#: gitk:1026 +msgid "Cherry-pick this commit" +msgstr "Diese Version pflücken" + +#: gitk:1028 +msgid "Reset HEAD branch to here" +msgstr "HEAD-Zweig auf diese Version zurücksetzen" + +#: gitk:1044 +msgid "Check out this branch" +msgstr "Auf diesen Zweig umstellen" + +#: gitk:1046 +msgid "Remove this branch" +msgstr "Zweig löschen" + +#: gitk:1052 +msgid "Highlight this too" +msgstr "" + +#: gitk:1054 +msgid "Highlight this only" +msgstr "" + +#: gitk:1281 +msgid "" +"\n" +"Gitk - a commit viewer for git\n" +"\n" +"Copyright © 2005-2006 Paul Mackerras\n" +"\n" +"Use and redistribute under the terms of the GNU General Public License" +msgstr "" + +#: gitk:1290 gitk:1354 gitk:6532 +msgid "Close" +msgstr "Schließen" + +#: gitk:1311 +msgid "Gitk key bindings" +msgstr "" + +#: gitk:1863 +msgid "Gitk view definition" +msgstr "" + +#: gitk:1888 +msgid "Name" +msgstr "Name" + +#: gitk:1891 +msgid "Remember this view" +msgstr "Diese Ansicht speichern" + +#: gitk:1895 +msgid "Commits to include (arguments to git rev-list):" +msgstr "" + +#: gitk:1901 +msgid "Enter files and directories to include, one per line:" +msgstr "" + +#: gitk:1950 +msgid "Error in commit selection arguments:" +msgstr "" + +#: gitk:2001 gitk:2087 gitk:2543 gitk:2557 gitk:3740 gitk:8635 gitk:8636 +msgid "None" +msgstr "Keine" + +#: gitk:2491 gitk:4295 gitk:5905 gitk:5920 +msgid "Date" +msgstr "Datum" + +#: gitk:2491 gitk:4295 +msgid "CDate" +msgstr "Eintragedatum" + +#: gitk:2640 gitk:2645 +msgid "Descendent" +msgstr "" + +#: gitk:2641 +msgid "Not descendent" +msgstr "" + +#: gitk:2648 gitk:2653 +msgid "Ancestor" +msgstr "" + +#: gitk:2649 +msgid "Not ancestor" +msgstr "" + +#: gitk:2883 +msgid "Local changes checked in to index but not committed" +msgstr "" + +#: gitk:2913 +msgid "Local uncommitted changes, not checked in to index" +msgstr "" + +#: gitk:4264 +msgid "Searching" +msgstr "Suchen" + +#: gitk:4723 +msgid "Tags:" +msgstr "Markierungen:" + +#: gitk:4740 gitk:4746 gitk:5898 +msgid "Parent" +msgstr "Eltern" + +#: gitk:4751 +msgid "Child" +msgstr "Kind" + +#: gitk:4760 +msgid "Branch" +msgstr "Zweig" + +#: gitk:4763 +msgid "Follows" +msgstr "" + +#: gitk:4766 +msgid "Precedes" +msgstr "" + +#: gitk:5048 +msgid "Error getting merge diffs:" +msgstr "Fehler beim Laden des Vergleichs:" + +#: gitk:5725 +msgid "Goto:" +msgstr "" + +#: gitk:5727 +msgid "SHA1 ID:" +msgstr "" + +#: gitk:5752 +#, tcl-format +msgid "Short SHA1 id %s is ambiguous" +msgstr "" + +#: gitk:5764 +#, tcl-format +msgid "SHA1 id %s is not known" +msgstr "" + +#: gitk:5766 +#, tcl-format +msgid "Tag/Head %s is not known" +msgstr "" + +#: gitk:5908 +msgid "Children" +msgstr "Kinder" + +#: gitk:5965 +#, tcl-format +msgid "Reset %s branch to here" +msgstr "Zweig »%s« hierher zurücksetzen" + +#: gitk:5996 +msgid "Top" +msgstr "Oben" + +#: gitk:5997 +msgid "From" +msgstr "Von" + +#: gitk:6002 +msgid "To" +msgstr "bis" + +#: gitk:6025 +msgid "Generate patch" +msgstr "Patch erstellen" + +#: gitk:6027 +msgid "From:" +msgstr "Von:" + +#: gitk:6036 +msgid "To:" +msgstr "bis:" + +#: gitk:6045 +msgid "Reverse" +msgstr "Umgekehrt" + +#: gitk:6047 gitk:6220 +msgid "Output file:" +msgstr "" + +#: gitk:6053 +msgid "Generate" +msgstr "Erzeugen" + +#: gitk:6089 +msgid "Error creating patch:" +msgstr "" + +#: gitk:6111 gitk:6208 gitk:6262 +msgid "ID:" +msgstr "" + +#: gitk:6120 +msgid "Tag name:" +msgstr "Markierungsname:" + +#: gitk:6124 gitk:6271 +msgid "Create" +msgstr "Erstellen" + +#: gitk:6139 +msgid "No tag name specified" +msgstr "" + +#: gitk:6143 +#, tcl-format +msgid "Tag \"%s\" already exists" +msgstr "Markierung »%s« existiert bereits." + +#: gitk:6153 +msgid "Error creating tag:" +msgstr "" + +#: gitk:6217 +msgid "Command:" +msgstr "" + +#: gitk:6225 +msgid "Write" +msgstr "Schreiben" + +#: gitk:6241 +msgid "Error writing commit:" +msgstr "" + +#: gitk:6267 +msgid "Name:" +msgstr "Name:" + +#: gitk:6286 +msgid "Please specify a name for the new branch" +msgstr "" + +#: gitk:6315 +#, tcl-format +msgid "Commit %s is already included in branch %s -- really re-apply it?" +msgstr "" + +#: gitk:6320 +msgid "Cherry-picking" +msgstr "Version pflücken" + +#: gitk:6332 +msgid "No changes committed" +msgstr "Keine Änderungen eingetragen" + +#: gitk:6355 +msgid "Confirm reset" +msgstr "Zurücksetzen bestätigen" + +#: gitk:6357 +#, tcl-format +msgid "Reset branch %s to %s?" +msgstr "" + +#: gitk:6361 +msgid "Reset type:" +msgstr "Art des Zurücksetzens:" + +#: gitk:6365 +msgid "Soft: Leave working tree and index untouched" +msgstr "Weich: Arbeitskopie und Bereitstellung unverändert" + +#: gitk:6368 +msgid "Mixed: Leave working tree untouched, reset index" +msgstr "" +"Gemischt: Arbeitskopie unverändert,\n" +"Bereitstellung zurückgesetzt" + +#: gitk:6371 +msgid "" +"Hard: Reset working tree and index\n" +"(discard ALL local changes)" +msgstr "" +"Hart: Arbeitskopie und Bereitstellung\n" +"(Alle lokalen Änderungen werden gelöscht)" + +#: gitk:6387 +msgid "Resetting" +msgstr "Zurücksetzen" + +#: gitk:6444 +msgid "Checking out" +msgstr "" + +#: gitk:6474 +msgid "Cannot delete the currently checked-out branch" +msgstr "" + +#: gitk:6480 +#, tcl-format +msgid "" +"The commits on branch %s aren't on any other branch.\n" +"Really delete branch %s?" +msgstr "" + +#: gitk:6511 +#, tcl-format +msgid "Tags and heads: %s" +msgstr "" + +#: gitk:6525 +msgid "Filter" +msgstr "" + +#: gitk:6820 +msgid "" +"Error reading commit topology information; branch and preceding/following " +"tag information will be incomplete." +msgstr "" + +#: gitk:7804 +msgid "Tag" +msgstr "Markierung" + +#: gitk:7804 +msgid "Id" +msgstr "" + +#: gitk:7844 +msgid "Gitk font chooser" +msgstr "" + +#: gitk:7861 +msgid "B" +msgstr "F" + +#: gitk:7864 +msgid "I" +msgstr "K" + +#: gitk:7959 +msgid "Gitk preferences" +msgstr "Gitk Einstellungen" + +#: gitk:7960 +msgid "Commit list display options" +msgstr "" + +#: gitk:7964 +msgid "Maximum graph width (lines)" +msgstr "" + +#: gitk:7968 +#, tcl-format +msgid "Maximum graph width (% of pane)" +msgstr "" + +#: gitk:7973 +msgid "Show local changes" +msgstr "" + +#: gitk:7978 +msgid "Diff display options" +msgstr "" + +#: gitk:7981 +msgid "Tab spacing" +msgstr "" + +#: gitk:7985 +msgid "Display nearby tags" +msgstr "" + +#: gitk:7990 +msgid "Limit diffs to listed paths" +msgstr "" + +#: gitk:7995 +msgid "Colors: press to choose" +msgstr "" + +#: gitk:7999 +msgid "Background" +msgstr "Vordergrund" + +#: gitk:8003 +msgid "Foreground" +msgstr "Hintergrund" + +#: gitk:8007 +msgid "Diff: old lines" +msgstr "" + +#: gitk:8012 +msgid "Diff: new lines" +msgstr "" + +#: gitk:8017 +msgid "Diff: hunk header" +msgstr "" + +#: gitk:8023 +msgid "Select bg" +msgstr "Hintergrundfarbe Auswählen" + +#: gitk:8027 +msgid "Fonts: press to choose" +msgstr "" + +#: gitk:8030 +msgid "Main font" +msgstr "" + +#: gitk:8031 +msgid "Diff display font" +msgstr "" + +#: gitk:8032 +msgid "User interface font" +msgstr "" + +#: gitk:8050 +#, tcl-format +msgid "Gitk: choose color for %s" +msgstr "" + +#: gitk:8431 +msgid "" +"Sorry, gitk cannot run with this version of Tcl/Tk.\n" +" Gitk requires at least Tcl/Tk 8.4." +msgstr "" + +#: gitk:8516 +msgid "Cannot find a git repository here." +msgstr "" + +#: gitk:8520 +#, tcl-format +msgid "Cannot find the git directory \"%s\"." +msgstr "" + +#: gitk:8559 +#, tcl-format +msgid "Ambiguous argument '%s': both revision and filename" +msgstr "" + +#: gitk:8571 +msgid "Bad arguments to gitk:" +msgstr "" + +#: gitk:8583 +msgid "Couldn't get list of unmerged files:" +msgstr "" + +#: gitk:8599 +msgid "No files selected: --merge specified but no files are unmerged." +msgstr "" + +#: gitk:8602 +msgid "" +"No files selected: --merge specified but no unmerged files are within file " +"limit." +msgstr "" + +#: gitk:8661 +msgid "Command line" +msgstr "Kommandozeile" From b007ee20dcf742d951009bf947f4883cb7f8070a Mon Sep 17 00:00:00 2001 From: Christian Stimming Date: Wed, 7 Nov 2007 18:44:35 +0100 Subject: [PATCH 08/93] [PATCH] gitk i18n: More markup -- various options menus Signed-off-by: Christian Stimming Signed-off-by: Paul Mackerras --- gitk | 92 ++++++++++++++++++++++++++++++------------------------------ 1 file changed, 46 insertions(+), 46 deletions(-) diff --git a/gitk b/gitk index e291577e52..b861f8d0e9 100755 --- a/gitk +++ b/gitk @@ -769,11 +769,11 @@ proc makewindow {} { label .tf.lbar.flab2 -text " [mc "commit"] " -font uifont pack .tf.lbar.flabel .tf.lbar.fnext .tf.lbar.fprev .tf.lbar.flab2 \ -side left -fill y - set gdttype "containing:" + set gdttype [mc "containing:"] set gm [tk_optionMenu .tf.lbar.gdttype gdttype \ - "containing:" \ - "touching paths:" \ - "adding/removing string:"] + [mc "containing:"] \ + [mc "touching paths:"] \ + [mc "adding/removing string:"]] trace add variable gdttype write gdttype_change $gm conf -font uifont .tf.lbar.gdttype conf -font uifont @@ -784,15 +784,15 @@ proc makewindow {} { lappend entries $fstring entry $fstring -width 30 -font textfont -textvariable findstring trace add variable findstring write find_change - set findtype Exact + set findtype [mc "Exact"] set findtypemenu [tk_optionMenu .tf.lbar.findtype \ - findtype Exact IgnCase Regexp] + findtype [mc "Exact"] [mc "IgnCase"] [mc "Regexp"]] trace add variable findtype write findcom_change .tf.lbar.findtype configure -font uifont .tf.lbar.findtype.menu configure -font uifont - set findloc "All fields" - tk_optionMenu .tf.lbar.findloc findloc "All fields" Headline \ - Comments Author Committer + set findloc [mc "All fields"] + tk_optionMenu .tf.lbar.findloc findloc [mc "All fields"] [mc "Headline"] \ + [mc "Comments"] [mc "Author"] [mc "Committer"] trace add variable findloc write find_change .tf.lbar.findloc configure -font uifont .tf.lbar.findloc.menu configure -font uifont @@ -1743,12 +1743,12 @@ proc flist_hl {only} { global flist_menu_file findstring gdttype set x [shellquote $flist_menu_file] - if {$only || $findstring eq {} || $gdttype ne "touching paths:"} { + if {$only || $findstring eq {} || $gdttype ne [mc "touching paths:"]} { set findstring $x } else { append findstring " " $x } - set gdttype "touching paths:" + set gdttype [mc "touching paths:"] } # Functions for adding and removing shell-type quoting @@ -1998,7 +1998,7 @@ proc delview {} { if {$curview == 0} return if {[info exists hlview] && $hlview == $curview} { - set selectedhlview None + set selectedhlview [mc "None"] unset hlview } allviewmenus $curview delete @@ -2084,7 +2084,7 @@ proc showview {n} { clear_display if {[info exists hlview] && $hlview == $n} { unset hlview - set selectedhlview None + set selectedhlview [mc "None"] } catch {unset commitinterest} @@ -2313,7 +2313,7 @@ proc gdttype_change {name ix op} { stopfinding if {$findstring ne {}} { - if {$gdttype eq "containing:"} { + if {$gdttype eq [mc "containing:"]} { if {$highlight_files ne {}} { set highlight_files {} hfiles_change @@ -2336,7 +2336,7 @@ proc find_change {name ix op} { global gdttype findstring highlight_files stopfinding - if {$gdttype eq "containing:"} { + if {$gdttype eq [mc "containing:"]} { findcom_change } else { if {$highlight_files ne $findstring} { @@ -2360,9 +2360,9 @@ proc findcom_change args { catch {unset nhighlights} unbolden unmarkmatches - if {$gdttype ne "containing:" || $findstring eq {}} { + if {$gdttype ne [mc "containing:"] || $findstring eq {}} { set findpattern {} - } elseif {$findtype eq "Regexp"} { + } elseif {$findtype eq [mc "Regexp"]} { set findpattern $findstring } else { set e [string map {"*" "\\*" "?" "\\?" "\[" "\\\[" "\\" "\\\\"} \ @@ -2388,12 +2388,12 @@ proc makepatterns {l} { proc do_file_hl {serial} { global highlight_files filehighlight highlight_paths gdttype fhl_list - if {$gdttype eq "touching paths:"} { + if {$gdttype eq [mc "touching paths:"]} { if {[catch {set paths [shellsplit $highlight_files]}]} return set highlight_paths [makepatterns $paths] highlight_filelist set gdtargs [concat -- $paths] - } elseif {$gdttype eq "adding/removing string:"} { + } elseif {$gdttype eq [mc "adding/removing string:"]} { set gdtargs [list "-S$highlight_files"] } else { # must be "containing:", i.e. we're searching commit info @@ -2469,9 +2469,9 @@ proc readfhighlight {} { proc doesmatch {f} { global findtype findpattern - if {$findtype eq "Regexp"} { + if {$findtype eq [mc "Regexp"]} { return [regexp $findpattern $f] - } elseif {$findtype eq "IgnCase"} { + } elseif {$findtype eq [mc "IgnCase"]} { return [string match -nocase $findpattern $f] } else { return [string match $findpattern $f] @@ -2488,11 +2488,11 @@ proc askfindhighlight {row id} { } set info $commitinfo($id) set isbold 0 - set fldtypes {Headline Author Date Committer CDate Comments} + set fldtypes [list [mc Headline] [mc Author] [mc Date] [mc Committer] [mc CDate] [mc Comments]] foreach f $info ty $fldtypes { - if {($findloc eq "All fields" || $findloc eq $ty) && + if {($findloc eq [mc "All fields"] || $findloc eq $ty) && [doesmatch $f]} { - if {$ty eq "Author"} { + if {$ty eq [mc "Author"]} { set isbold 2 break } @@ -2520,14 +2520,14 @@ proc markrowmatches {row id} { set author [lindex $commitinfo($id) 1] $canv delete match$row $canv2 delete match$row - if {$findloc eq "All fields" || $findloc eq "Headline"} { + if {$findloc eq [mc "All fields"] || $findloc eq [mc "Headline"]} { set m [findmatches $headline] if {$m ne {}} { markmatches $canv $row $headline $linehtag($row) $m \ [$canv itemcget $linehtag($row) -font] $row } } - if {$findloc eq "All fields" || $findloc eq "Author"} { + if {$findloc eq [mc "All fields"] || $findloc eq [mc "Author"]} { set m [findmatches $author] if {$m ne {}} { markmatches $canv2 $row $author $linentag($row) $m \ @@ -2540,7 +2540,7 @@ proc vrel_change {name ix op} { global highlight_related rhighlight_none - if {$highlight_related ne "None"} { + if {$highlight_related ne [mc "None"]} { run drawvisible } } @@ -2554,7 +2554,7 @@ proc rhighlight_sel {a} { set desc_todo [list $a] catch {unset ancestor} set anc_todo [list $a] - if {$highlight_related ne "None"} { + if {$highlight_related ne [mc "None"]} { rhighlight_none run drawvisible } @@ -2637,20 +2637,20 @@ proc askrelhighlight {row id} { if {![info exists selectedline]} return set isbold 0 - if {$highlight_related eq "Descendent" || - $highlight_related eq "Not descendent"} { + if {$highlight_related eq [mc "Descendent"] || + $highlight_related eq [mc "Not descendent"]} { if {![info exists descendent($id)]} { is_descendent $id } - if {$descendent($id) == ($highlight_related eq "Descendent")} { + if {$descendent($id) == ($highlight_related eq [mc "Descendent"])} { set isbold 1 } - } elseif {$highlight_related eq "Ancestor" || - $highlight_related eq "Not ancestor"} { + } elseif {$highlight_related eq [mc "Ancestor"] || + $highlight_related eq [mc "Not ancestor"]} { if {![info exists ancestor($id)]} { is_ancestor $id } - if {$ancestor($id) == ($highlight_related eq "Ancestor")} { + if {$ancestor($id) == ($highlight_related eq [mc "Ancestor"])} { set isbold 1 } } @@ -3737,7 +3737,7 @@ proc drawcmitrow {row} { if {$findpattern ne {} && ![info exists nhighlights($row)]} { askfindhighlight $row $id } - if {$highlight_related ne "None" && ![info exists rhighlights($row)]} { + if {$highlight_related ne [mc "None"] && ![info exists rhighlights($row)]} { askrelhighlight $row $id } if {![info exists iddrawn($id)]} { @@ -4226,11 +4226,11 @@ proc notbusy {what} { proc findmatches {f} { global findtype findstring - if {$findtype == "Regexp"} { + if {$findtype == [mc "Regexp"]} { set matches [regexp -indices -all -inline $findstring $f] } else { set fs $findstring - if {$findtype == "IgnCase"} { + if {$findtype == [mc "IgnCase"]} { set f [string tolower $f] set fs [string tolower $fs] } @@ -4261,8 +4261,8 @@ proc dofind {{dirn 1} {wrap 1}} { set findstartline $selectedline } set findcurline $findstartline - nowbusy finding "Searching" - if {$gdttype ne "containing:" && ![info exists filehighlight]} { + nowbusy finding [mc "Searching"] + if {$gdttype ne [mc "containing:"] && ![info exists filehighlight]} { after cancel do_file_hl $fh_serial do_file_hl $fh_serial } @@ -4292,7 +4292,7 @@ proc findmore {} { if {![info exists find_dirn]} { return 0 } - set fldtypes {Headline Author Date Committer CDate Comments} + set fldtypes [list [mc "Headline"] [mc "Author"] [mc "Date"] [mc "Committer"] [mc "CDate"] [mc "Comments"]] set l $findcurline set moretodo 0 if {$find_dirn > 0} { @@ -4325,7 +4325,7 @@ proc findmore {} { } set found 0 set domore 1 - if {$gdttype eq "containing:"} { + if {$gdttype eq [mc "containing:"]} { for {} {$n > 0} {incr n -1; incr l $find_dirn} { set id [lindex $displayorder $l] # shouldn't happen unless git log doesn't give all the commits... @@ -4336,7 +4336,7 @@ proc findmore {} { } set info $commitinfo($id) foreach f $info ty $fldtypes { - if {($findloc eq "All fields" || $findloc eq $ty) && + if {($findloc eq [mc "All fields"] || $findloc eq $ty) && [doesmatch $f]} { set found 1 break @@ -4392,7 +4392,7 @@ proc findselectline {l} { set markingmatches 1 set findcurline $l selectline $l 1 - if {$findloc == "All fields" || $findloc == "Comments"} { + if {$findloc == [mc "All fields"] || $findloc == [mc "Comments"]} { # highlight the matches in the comments set f [$ctext get 1.0 $commentend] set matches [findmatches $f] @@ -4780,7 +4780,7 @@ proc selectline {l isnew} { $ctext conf -state disabled set commentend [$ctext index "end - 1c"] - init_flist "Comments" + init_flist [mc "Comments"] if {$cmitmode eq "tree"} { gettree $id } elseif {[llength $olds] <= 1} { @@ -8632,8 +8632,8 @@ set firsttabstop 0 set nextviewnum 1 set curview 0 set selectedview 0 -set selectedhlview None -set highlight_related None +set selectedhlview [mc "None"] +set highlight_related [mc "None"] set highlight_files {} set viewfiles(0) {} set viewperm(0) 0 From eadcac921805bc05f5029fc98f2484f52543af0d Mon Sep 17 00:00:00 2001 From: Christian Stimming Date: Wed, 7 Nov 2007 18:47:04 +0100 Subject: [PATCH 09/93] [PATCH] gitk i18n: Recode gitk from latin1 to utf8 so that the (c) copyright character is valid utf8. When using translations, the target language must be encoded in utf-8 because almost all target languages will contain non-ascii characters. For that reason, the non-translated strings should be in utf-8 as well so that there isn't any encoding mixup inside the program. Signed-off-by: Paul Mackerras --- gitk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gitk b/gitk index b861f8d0e9..684e6141eb 100755 --- a/gitk +++ b/gitk @@ -1281,7 +1281,7 @@ proc about {} { message $w.m -text [mc " Gitk - a commit viewer for git -Copyright © 2005-2006 Paul Mackerras +Copyright © 2005-2006 Paul Mackerras Use and redistribute under the terms of the GNU General Public License"] \ -justify center -aspect 400 -border 2 -bg white -relief groove From c45857019c95ee8ffbf843bdb778ced0cfd4f6fb Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Thu, 27 Dec 2007 23:29:53 -0800 Subject: [PATCH 10/93] Documentation/git-submodule.txt: typofix Signed-off-by: Junio C Hamano --- Documentation/git-submodule.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/git-submodule.txt b/Documentation/git-submodule.txt index 3f59705686..7d9a9fe5cd 100644 --- a/Documentation/git-submodule.txt +++ b/Documentation/git-submodule.txt @@ -67,7 +67,7 @@ FILES ----- When initializing submodules, a .gitmodules file in the top-level directory of the containing repository is used to find the url of each submodule. -This file should be formatted in the same way as $GIR_DIR/config. The key +This file should be formatted in the same way as `$GIT_DIR/config`. The key to each submodule url is "submodule.$name.url". See gitlink:gitmodules[5] for details. From 3f4bc3e048280a564e85569549a311f716dae277 Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Fri, 28 Dec 2007 23:25:39 +0100 Subject: [PATCH 11/93] git-sh-setup: document git_editor() and get_author_ident_from_commit() These 2 functions were missing from the manpage. Signed-off-by: Miklos Vajna Signed-off-by: Junio C Hamano --- Documentation/git-sh-setup.txt | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Documentation/git-sh-setup.txt b/Documentation/git-sh-setup.txt index 1ea1faa1b5..505b4c98e1 100644 --- a/Documentation/git-sh-setup.txt +++ b/Documentation/git-sh-setup.txt @@ -44,6 +44,11 @@ set_reflog_action:: end-user action in the reflog, when the script updates a ref. +git_editor:: + runs an editor of user's choice (GIT_EDITOR, core.editor, VISUAL or + EDITOR) on a given file, but error out if no editor is specified + and the terminal is dumb. + is_bare_repository:: outputs `true` or `false` to the standard output stream to indicate if the repository is a bare repository @@ -57,6 +62,10 @@ require_work_tree:: if so. Used by scripts that require working tree (e.g. `checkout`). +get_author_ident_from_commit:: + outputs code for use with eval to set the GIT_AUTHOR_NAME, + GIT_AUTHOR_EMAIL and GIT_AUTHOR_DATE variables for a given commit. + Author ------ From 441ed4131b2d735fea08e4f6277c12b13acebd53 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Fri, 28 Dec 2007 13:58:43 -0800 Subject: [PATCH 12/93] "git pull --tags": error out with a better message. When "git pull --tags" is run without any other arguments, the standard error message "You told me to fetch and merge stuff but there is nothing to merge! You might want to fix your config" is given. While the error may be technically correct, fixing the config would not help, as "git pull --tags" itself tells "git fetch" not to use the configured refspecs. This commit makes "git pull --tags" to issue a different error message to avoid confusion. This is merely an interim solution. In the longer term, it would be a better approach to change the semantics of --tags option to make "git fetch" and "git pull" to: (1) behave as if no --tags was given (so an explicit refspec on the command line overrides configured ones, or no explicit refspecs on the command line takes configured ones); but (2) no auto-following of tags is made even when using configured refspecs; and (3) fetch all tags as not-for-merge entries". Then we would not need to have this separate error message, as the ordinary merge will happen even with the --tags option. Signed-off-by: Junio C Hamano --- git-pull.sh | 66 ++++++++++++++++++++++++++++++++--------------------- 1 file changed, 40 insertions(+), 26 deletions(-) diff --git a/git-pull.sh b/git-pull.sh index 698e82b116..fa97b0f356 100755 --- a/git-pull.sh +++ b/git-pull.sh @@ -72,6 +72,40 @@ do shift done +error_on_no_merge_candidates () { + exec >&2 + for opt + do + case "$opt" in + -t|--t|--ta|--tag|--tags) + echo "Fetching tags only, you probably meant:" + echo " git fetch --tags" + exit 1 + esac + done + + curr_branch=${curr_branch#refs/heads/} + + echo "You asked me to pull without telling me which branch you" + echo "want to merge with, and 'branch.${curr_branch}.merge' in" + echo "your configuration file does not tell me either. Please" + echo "name which branch you want to merge on the command line and" + echo "try again (e.g. 'git pull ')." + echo "See git-pull(1) for details on the refspec." + echo + echo "If you often merge with the same branch, you may want to" + echo "configure the following variables in your configuration" + echo "file:" + echo + echo " branch.${curr_branch}.remote = " + echo " branch.${curr_branch}.merge = " + echo " remote..url = " + echo " remote..fetch = " + echo + echo "See git-config(1) for details." + exit 1 +} + orig_head=$(git rev-parse --verify HEAD 2>/dev/null) git-fetch --update-head-ok "$@" || exit 1 @@ -105,33 +139,13 @@ merge_head=$(sed -e '/ not-for-merge /d' \ case "$merge_head" in '') case $? in - 0) ;; - 1) echo >&2 "You are not currently on a branch; you must explicitly" - echo >&2 "specify which branch you wish to merge:" - echo >&2 " git pull " - exit 1;; - *) exit $?;; + 0) error_on_no_merge_candidates "$@";; + 1) echo >&2 "You are not currently on a branch; you must explicitly" + echo >&2 "specify which branch you wish to merge:" + echo >&2 " git pull " + exit 1;; + *) exit $?;; esac - curr_branch=${curr_branch#refs/heads/} - - echo >&2 "You asked me to pull without telling me which branch you" - echo >&2 "want to merge with, and 'branch.${curr_branch}.merge' in" - echo >&2 "your configuration file does not tell me either. Please" - echo >&2 "name which branch you want to merge on the command line and" - echo >&2 "try again (e.g. 'git pull ')." - echo >&2 "See git-pull(1) for details on the refspec." - echo >&2 - echo >&2 "If you often merge with the same branch, you may want to" - echo >&2 "configure the following variables in your configuration" - echo >&2 "file:" - echo >&2 - echo >&2 " branch.${curr_branch}.remote = " - echo >&2 " branch.${curr_branch}.merge = " - echo >&2 " remote..url = " - echo >&2 " remote..fetch = " - echo >&2 - echo >&2 "See git-config(1) for details." - exit 1 ;; ?*' '?*) if test -z "$orig_head" From f0e8692a091195c8642923fd410553c293895d75 Mon Sep 17 00:00:00 2001 From: Peter Karlsson Date: Thu, 27 Dec 2007 13:34:31 +0100 Subject: [PATCH 13/93] Added Swedish translation. --- po/sv.po | 1895 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1895 insertions(+) create mode 100644 po/sv.po diff --git a/po/sv.po b/po/sv.po new file mode 100644 index 0000000000..58c96c85d2 --- /dev/null +++ b/po/sv.po @@ -0,0 +1,1895 @@ +# Swedish translation of git-gui. +# Copyright (C) 2007 Shawn Pearce, et al. +# This file is distributed under the same license as the git-gui package. +# +# Peter Karlsson , 2007. +msgid "" +msgstr "" +"Project-Id-Version: sv\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2007-11-24 10:36+0100\n" +"PO-Revision-Date: 2007-12-27 13:31CET-1\n" +"Last-Translator: Peter Karlsson \n" +"Language-Team: Swedish \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Generator: KBabel 1.11.4\n" + +#: git-gui.sh:41 git-gui.sh:604 git-gui.sh:618 git-gui.sh:631 git-gui.sh:714 +#: git-gui.sh:733 +msgid "git-gui: fatal error" +msgstr "git-gui: ödesdigert fel" + +#: git-gui.sh:565 +#, tcl-format +msgid "Invalid font specified in %s:" +msgstr "Ogiltigt teckensnitt angivet i %s:" + +#: git-gui.sh:590 +msgid "Main Font" +msgstr "Huvudteckensnitt" + +#: git-gui.sh:591 +msgid "Diff/Console Font" +msgstr "Diff/konsolteckensnitt" + +#: git-gui.sh:605 +msgid "Cannot find git in PATH." +msgstr "Hittar inte git i PATH." + +#: git-gui.sh:632 +msgid "Cannot parse Git version string:" +msgstr "Kan inte tolka versionssträng frÃ¥n Git:" + +#: git-gui.sh:650 +#, tcl-format +msgid "" +"Git version cannot be determined.\n" +"\n" +"%s claims it is version '%s'.\n" +"\n" +"%s requires at least Git 1.5.0 or later.\n" +"\n" +"Assume '%s' is version 1.5.0?\n" +msgstr "" +"Kan inte avgöra Gits version.\n" +"\n" +"%s säger att dess version är \"%s\".\n" +"\n" +"%s kräver minst Git 1.5.0 eller senare.\n" +"\n" +"Anta att \"%s\" är version 1.5.0?\n" + +#: git-gui.sh:888 +msgid "Git directory not found:" +msgstr "Git-katalogen hittades inte:" + +#: git-gui.sh:895 +msgid "Cannot move to top of working directory:" +msgstr "Kunde inte gÃ¥ till början pÃ¥ arbetskatalogen:" + +#: git-gui.sh:902 +msgid "Cannot use funny .git directory:" +msgstr "Kunde inte använda underlig .git-katalog:" + +#: git-gui.sh:907 +msgid "No working directory" +msgstr "Ingen arbetskatalog" + +#: git-gui.sh:1054 +msgid "Refreshing file status..." +msgstr "Uppdaterar filstatus..." + +#: git-gui.sh:1119 +msgid "Scanning for modified files ..." +msgstr "Söker efter ändrade filer..." + +#: git-gui.sh:1294 lib/browser.tcl:245 +msgid "Ready." +msgstr "Redo." + +#: git-gui.sh:1560 +msgid "Unmodified" +msgstr "Oförändrade" + +#: git-gui.sh:1562 +msgid "Modified, not staged" +msgstr "Förändrade, ej köade" + +#: git-gui.sh:1563 git-gui.sh:1568 +msgid "Staged for commit" +msgstr "Köade för incheckning" + +#: git-gui.sh:1564 git-gui.sh:1569 +msgid "Portions staged for commit" +msgstr "Delar köade för incheckning" + +#: git-gui.sh:1565 git-gui.sh:1570 +msgid "Staged for commit, missing" +msgstr "Köade för incheckning, saknade" + +#: git-gui.sh:1567 +msgid "Untracked, not staged" +msgstr "Ej spÃ¥rade, ej köade" + +#: git-gui.sh:1572 +msgid "Missing" +msgstr "Saknade" + +#: git-gui.sh:1573 +msgid "Staged for removal" +msgstr "Köade för borttagning" + +#: git-gui.sh:1574 +msgid "Staged for removal, still present" +msgstr "Köade för borttagning, fortfarande närvarande" + +#: git-gui.sh:1576 git-gui.sh:1577 git-gui.sh:1578 git-gui.sh:1579 +msgid "Requires merge resolution" +msgstr "Kräver avgörande efter sammanslagning" + +#: git-gui.sh:1614 +msgid "Starting gitk... please wait..." +msgstr "Startar gitk... vänta..." + +#: git-gui.sh:1623 +#, tcl-format +msgid "" +"Unable to start gitk:\n" +"\n" +"%s does not exist" +msgstr "" +"Kan inte starta gitk:\n" +"\n" +"%s finns inte" + +#: git-gui.sh:1823 lib/choose_repository.tcl:35 +msgid "Repository" +msgstr "Arkiv" + +#: git-gui.sh:1824 +msgid "Edit" +msgstr "Redigera" + +#: git-gui.sh:1826 lib/choose_rev.tcl:560 +msgid "Branch" +msgstr "Gren" + +#: git-gui.sh:1829 lib/choose_rev.tcl:547 +msgid "Commit@@noun" +msgstr "Incheckning" + +#: git-gui.sh:1832 lib/merge.tcl:121 lib/merge.tcl:150 lib/merge.tcl:168 +msgid "Merge" +msgstr "SlÃ¥ ihop" + +#: git-gui.sh:1833 lib/choose_rev.tcl:556 +msgid "Remote" +msgstr "Fjärr" + +#: git-gui.sh:1842 +msgid "Browse Current Branch's Files" +msgstr "Bläddra i grenens filer" + +#: git-gui.sh:1846 +msgid "Browse Branch Files..." +msgstr "Bläddra filer pÃ¥ gren..." + +#: git-gui.sh:1851 +msgid "Visualize Current Branch's History" +msgstr "Visualisera grenens historik" + +#: git-gui.sh:1855 +msgid "Visualize All Branch History" +msgstr "Visualisera alla grenars historik" + +#: git-gui.sh:1862 +#, tcl-format +msgid "Browse %s's Files" +msgstr "Bläddra i filer för %s" + +#: git-gui.sh:1864 +#, tcl-format +msgid "Visualize %s's History" +msgstr "Visualisera historik för %s" + +#: git-gui.sh:1869 lib/database.tcl:27 lib/database.tcl:67 +msgid "Database Statistics" +msgstr "Databasstatistik" + +#: git-gui.sh:1872 lib/database.tcl:34 +msgid "Compress Database" +msgstr "Komprimera databas" + +#: git-gui.sh:1875 +msgid "Verify Database" +msgstr "Verifiera databas" + +#: git-gui.sh:1882 git-gui.sh:1886 git-gui.sh:1890 lib/shortcut.tcl:7 +#: lib/shortcut.tcl:39 lib/shortcut.tcl:71 +msgid "Create Desktop Icon" +msgstr "Skapa skrivbordsikon" + +#: git-gui.sh:1895 lib/choose_repository.tcl:176 lib/choose_repository.tcl:184 +msgid "Quit" +msgstr "Avsluta" + +#: git-gui.sh:1902 +msgid "Undo" +msgstr "Ã…ngra" + +#: git-gui.sh:1905 +msgid "Redo" +msgstr "Gör om" + +#: git-gui.sh:1909 git-gui.sh:2403 +msgid "Cut" +msgstr "Klipp ut" + +#: git-gui.sh:1912 git-gui.sh:2406 git-gui.sh:2477 git-gui.sh:2549 +#: lib/console.tcl:67 +msgid "Copy" +msgstr "Kopiera" + +#: git-gui.sh:1915 git-gui.sh:2409 +msgid "Paste" +msgstr "Klistra in" + +#: git-gui.sh:1918 git-gui.sh:2412 lib/branch_delete.tcl:26 +#: lib/remote_branch_delete.tcl:38 +msgid "Delete" +msgstr "Ta bort" + +#: git-gui.sh:1922 git-gui.sh:2416 git-gui.sh:2553 lib/console.tcl:69 +msgid "Select All" +msgstr "Markera alla" + +#: git-gui.sh:1931 +msgid "Create..." +msgstr "Skapa..." + +#: git-gui.sh:1937 +msgid "Checkout..." +msgstr "Checka ut..." + +#: git-gui.sh:1943 +msgid "Rename..." +msgstr "Byt namn..." + +#: git-gui.sh:1948 git-gui.sh:2048 +msgid "Delete..." +msgstr "Ta bort..." + +#: git-gui.sh:1953 +msgid "Reset..." +msgstr "Ã…terställ..." + +#: git-gui.sh:1965 git-gui.sh:2350 +msgid "New Commit" +msgstr "Ny incheckning" + +#: git-gui.sh:1973 git-gui.sh:2357 +msgid "Amend Last Commit" +msgstr "Lägg till föregÃ¥ende incheckning" + +#: git-gui.sh:1982 git-gui.sh:2317 lib/remote_branch_delete.tcl:99 +msgid "Rescan" +msgstr "Sök pÃ¥ nytt" + +#: git-gui.sh:1988 +msgid "Stage To Commit" +msgstr "Köa för incheckning" + +#: git-gui.sh:1994 +msgid "Stage Changed Files To Commit" +msgstr "Köa ändrade filer för incheckning" + +#: git-gui.sh:2000 +msgid "Unstage From Commit" +msgstr "Ta bort frÃ¥n incheckningskö" + +#: git-gui.sh:2005 lib/index.tcl:393 +msgid "Revert Changes" +msgstr "Ã…terställ ändringar" + +#: git-gui.sh:2012 git-gui.sh:2329 git-gui.sh:2427 +msgid "Sign Off" +msgstr "Skriv under" + +#: git-gui.sh:2016 git-gui.sh:2333 +msgid "Commit@@verb" +msgstr "Checka in" + +#: git-gui.sh:2027 +msgid "Local Merge..." +msgstr "Lokal sammanslagning..." + +#: git-gui.sh:2032 +msgid "Abort Merge..." +msgstr "Avbryt sammanslagning..." + +#: git-gui.sh:2044 +msgid "Push..." +msgstr "Sänd..." + +#: git-gui.sh:2055 lib/choose_repository.tcl:40 +msgid "Apple" +msgstr "Äpple" + +#: git-gui.sh:2058 git-gui.sh:2080 lib/about.tcl:13 +#: lib/choose_repository.tcl:43 lib/choose_repository.tcl:49 +#, tcl-format +msgid "About %s" +msgstr "Om %s" + +#: git-gui.sh:2062 +msgid "Preferences..." +msgstr "Inställningar..." + +#: git-gui.sh:2070 git-gui.sh:2595 +msgid "Options..." +msgstr "Alternativ..." + +#: git-gui.sh:2076 lib/choose_repository.tcl:46 +msgid "Help" +msgstr "Hjälp" + +#: git-gui.sh:2117 +msgid "Online Documentation" +msgstr "Webbdokumentation" + +#: git-gui.sh:2201 +#, tcl-format +msgid "fatal: cannot stat path %s: No such file or directory" +msgstr "ödesdigert: kunde inte ta status pÃ¥ sökvägen %s: Fil eller katalog saknas" + +#: git-gui.sh:2234 +msgid "Current Branch:" +msgstr "Aktuell gren:" + +#: git-gui.sh:2255 +msgid "Staged Changes (Will Commit)" +msgstr "Köade ändringar (kommer att checkas in)" + +#: git-gui.sh:2274 +msgid "Unstaged Changes" +msgstr "Oköade ändringar" + +#: git-gui.sh:2323 +msgid "Stage Changed" +msgstr "Köa ändrade" + +#: git-gui.sh:2339 lib/transport.tcl:93 lib/transport.tcl:182 +msgid "Push" +msgstr "Sänd" + +#: git-gui.sh:2369 +msgid "Initial Commit Message:" +msgstr "Inledande incheckningsmeddelande:" + +#: git-gui.sh:2370 +msgid "Amended Commit Message:" +msgstr "Utökat incheckningsmeddelande:" + +#: git-gui.sh:2371 +msgid "Amended Initial Commit Message:" +msgstr "Utökat inledande incheckningsmeddelande:" + +#: git-gui.sh:2372 +msgid "Amended Merge Commit Message:" +msgstr "Utökat incheckningsmeddelande för sammanslagning:" + +#: git-gui.sh:2373 +msgid "Merge Commit Message:" +msgstr "Incheckningsmeddelande för sammanslagning:" + +#: git-gui.sh:2374 +msgid "Commit Message:" +msgstr "Incheckningsmeddelande:" + +#: git-gui.sh:2419 git-gui.sh:2557 lib/console.tcl:71 +msgid "Copy All" +msgstr "Kopiera alla" + +#: git-gui.sh:2443 lib/blame.tcl:104 +msgid "File:" +msgstr "Fil:" + +#: git-gui.sh:2545 +msgid "Refresh" +msgstr "Uppdatera" + +#: git-gui.sh:2566 +msgid "Apply/Reverse Hunk" +msgstr "Använd/Ã¥terställ del" + +#: git-gui.sh:2572 +msgid "Decrease Font Size" +msgstr "Minska teckensnittsstorlek" + +#: git-gui.sh:2576 +msgid "Increase Font Size" +msgstr "Öka teckensnittsstorlek" + +#: git-gui.sh:2581 +msgid "Show Less Context" +msgstr "Visa mindre sammanhang" + +#: git-gui.sh:2588 +msgid "Show More Context" +msgstr "Visa mer sammanhang" + +#: git-gui.sh:2602 +msgid "Unstage Hunk From Commit" +msgstr "Ta bort del ur incheckningskö" + +#: git-gui.sh:2604 +msgid "Stage Hunk For Commit" +msgstr "Ställ del i incheckningskö" + +#: git-gui.sh:2623 +msgid "Initializing..." +msgstr "Initierar..." + +#: git-gui.sh:2718 +#, tcl-format +msgid "" +"Possible environment issues exist.\n" +"\n" +"The following environment variables are probably\n" +"going to be ignored by any Git subprocess run\n" +"by %s:\n" +"\n" +msgstr "" +"Det finns möjliga problem med miljövariabler.\n" +"\n" +"Följande miljövariabler kommer troligen att\n" +"ignoreras av alla Git-underprocesser som körs\n" +"av %s:\n" +"\n" + +#: git-gui.sh:2748 +msgid "" +"\n" +"This is due to a known issue with the\n" +"Tcl binary distributed by Cygwin." +msgstr "" +"\n" +"Detta beror pÃ¥ ett känt problem med\n" +"Tcl-binären som följer med Cygwin." + +#: git-gui.sh:2753 +#, tcl-format +msgid "" +"\n" +"\n" +"A good replacement for %s\n" +"is placing values for the user.name and\n" +"user.email settings into your personal\n" +"~/.gitconfig file.\n" +msgstr "" +"\n" +"\n" +"Du kan ersätta %s\n" +"med att lägga in värden för inställningarna\n" +"user.name och user.email i din personliga\n" +"~/.gitconfig-fil.\n" + +#: lib/about.tcl:25 +msgid "git-gui - a graphical user interface for Git." +msgstr "git-gui - ett grafiskt användargränssnitt för Git." + +#: lib/blame.tcl:77 +msgid "File Viewer" +msgstr "Filvisare" + +#: lib/blame.tcl:81 +msgid "Commit:" +msgstr "Incheckning:" + +#: lib/blame.tcl:249 +msgid "Copy Commit" +msgstr "Kopiera incheckning" + +#: lib/blame.tcl:369 +#, tcl-format +msgid "Reading %s..." +msgstr "Läser %s..." + +#: lib/blame.tcl:473 +msgid "Loading copy/move tracking annotations..." +msgstr "Läser spÃ¥rningsanteckningar för kopiering/flyttning..." + +#: lib/blame.tcl:493 +msgid "lines annotated" +msgstr "rader spÃ¥rade" + +#: lib/blame.tcl:674 +msgid "Loading original location annotations..." +msgstr "Läser in spÃ¥rning av originalplacering..." + +#: lib/blame.tcl:677 +msgid "Annotation complete." +msgstr "SpÃ¥rning fullbordad." + +#: lib/blame.tcl:731 +msgid "Loading annotation..." +msgstr "Läser in spÃ¥rning..." + +#: lib/blame.tcl:787 +msgid "Author:" +msgstr "Författare:" + +#: lib/blame.tcl:791 +msgid "Committer:" +msgstr "Incheckare:" + +#: lib/blame.tcl:796 +msgid "Original File:" +msgstr "Ursprunglig fil:" + +#: lib/blame.tcl:910 +msgid "Originally By:" +msgstr "Ursprungligen av:" + +#: lib/blame.tcl:916 +msgid "In File:" +msgstr "I filen:" + +#: lib/blame.tcl:921 +msgid "Copied Or Moved Here By:" +msgstr "Kopierad eller flyttad hit av:" + +#: lib/branch_checkout.tcl:14 lib/branch_checkout.tcl:19 +msgid "Checkout Branch" +msgstr "Checka ut gren" + +#: lib/branch_checkout.tcl:23 +msgid "Checkout" +msgstr "Checka ut" + +#: lib/branch_checkout.tcl:27 lib/branch_create.tcl:35 +#: lib/branch_delete.tcl:32 lib/branch_rename.tcl:30 lib/browser.tcl:281 +#: lib/checkout_op.tcl:522 lib/choose_font.tcl:43 lib/merge.tcl:172 +#: lib/option.tcl:90 lib/remote_branch_delete.tcl:42 lib/transport.tcl:97 +msgid "Cancel" +msgstr "Avbryt" + +#: lib/branch_checkout.tcl:32 lib/browser.tcl:286 +msgid "Revision" +msgstr "Revision" + +#: lib/branch_checkout.tcl:36 lib/branch_create.tcl:69 lib/option.tcl:202 +msgid "Options" +msgstr "Alternativ" + +#: lib/branch_checkout.tcl:39 lib/branch_create.tcl:92 +msgid "Fetch Tracking Branch" +msgstr "Hämta spÃ¥rande gren" + +#: lib/branch_checkout.tcl:44 +msgid "Detach From Local Branch" +msgstr "Koppla bort frÃ¥n lokal gren" + +#: lib/branch_create.tcl:22 +msgid "Create Branch" +msgstr "Skapa gren" + +#: lib/branch_create.tcl:27 +msgid "Create New Branch" +msgstr "Skapa ny gren" + +#: lib/branch_create.tcl:31 lib/choose_repository.tcl:375 +msgid "Create" +msgstr "Skapa" + +#: lib/branch_create.tcl:40 +msgid "Branch Name" +msgstr "Namn pÃ¥ gren" + +#: lib/branch_create.tcl:43 +msgid "Name:" +msgstr "Namn:" + +#: lib/branch_create.tcl:58 +msgid "Match Tracking Branch Name" +msgstr "Använd namn pÃ¥ spÃ¥rad gren" + +#: lib/branch_create.tcl:66 +msgid "Starting Revision" +msgstr "Inledande revision" + +#: lib/branch_create.tcl:72 +msgid "Update Existing Branch:" +msgstr "Uppdatera befintlig gren:" + +#: lib/branch_create.tcl:75 +msgid "No" +msgstr "Nej" + +#: lib/branch_create.tcl:80 +msgid "Fast Forward Only" +msgstr "Endast snabbspolning" + +#: lib/branch_create.tcl:85 lib/checkout_op.tcl:514 +msgid "Reset" +msgstr "Ã…terställ" + +#: lib/branch_create.tcl:97 +msgid "Checkout After Creation" +msgstr "Checka ut när skapad" + +#: lib/branch_create.tcl:131 +msgid "Please select a tracking branch." +msgstr "Välj en gren att spÃ¥ra." + +#: lib/branch_create.tcl:140 +#, tcl-format +msgid "Tracking branch %s is not a branch in the remote repository." +msgstr "Den spÃ¥rade grenen %s är inte en gren i fjärrarkivet." + +#: lib/branch_create.tcl:153 lib/branch_rename.tcl:86 +msgid "Please supply a branch name." +msgstr "Ange ett namn för grenen." + +#: lib/branch_create.tcl:164 lib/branch_rename.tcl:106 +#, tcl-format +msgid "'%s' is not an acceptable branch name." +msgstr "\"%s\" kan inte användas som namn pÃ¥ grenen." + +#: lib/branch_delete.tcl:15 +msgid "Delete Branch" +msgstr "Ta bort gren" + +#: lib/branch_delete.tcl:20 +msgid "Delete Local Branch" +msgstr "Ta bort lokal gren" + +#: lib/branch_delete.tcl:37 +msgid "Local Branches" +msgstr "Lokala grenar" + +#: lib/branch_delete.tcl:52 +msgid "Delete Only If Merged Into" +msgstr "Ta bara bort om sammanslagen med" + +#: lib/branch_delete.tcl:54 +msgid "Always (Do not perform merge test.)" +msgstr "Alltid (utför inte sammanslagningstest)." + +#: lib/branch_delete.tcl:103 +#, tcl-format +msgid "The following branches are not completely merged into %s:" +msgstr "Följande grenar är inte till fullo sammanslagna med %s:" + +#: lib/branch_delete.tcl:115 +msgid "" +"Recovering deleted branches is difficult. \n" +"\n" +" Delete the selected branches?" +msgstr "" +"Det är svÃ¥rt att Ã¥terställa borttagna grenar.\n" +"\n" +" Ta bort valda grenar?" + +#: lib/branch_delete.tcl:141 +#, tcl-format +msgid "" +"Failed to delete branches:\n" +"%s" +msgstr "" +"Kunde inte ta bort grenar:\n" +"%s" + +#: lib/branch_rename.tcl:14 lib/branch_rename.tcl:22 +msgid "Rename Branch" +msgstr "Byt namn pÃ¥ gren" + +#: lib/branch_rename.tcl:26 +msgid "Rename" +msgstr "Byt namn" + +#: lib/branch_rename.tcl:36 +msgid "Branch:" +msgstr "Gren:" + +#: lib/branch_rename.tcl:39 +msgid "New Name:" +msgstr "Nytt namn:" + +#: lib/branch_rename.tcl:75 +msgid "Please select a branch to rename." +msgstr "Välj en gren att byta namn pÃ¥." + +#: lib/branch_rename.tcl:96 lib/checkout_op.tcl:179 +#, tcl-format +msgid "Branch '%s' already exists." +msgstr "Grenen \"%s\" finns redan." + +#: lib/branch_rename.tcl:117 +#, tcl-format +msgid "Failed to rename '%s'." +msgstr "Kunde inte byta namn pÃ¥ \"%s\"." + +#: lib/browser.tcl:17 +msgid "Starting..." +msgstr "Startar..." + +#: lib/browser.tcl:26 +msgid "File Browser" +msgstr "Filbläddrare" + +#: lib/browser.tcl:125 lib/browser.tcl:142 +#, tcl-format +msgid "Loading %s..." +msgstr "Läser %s..." + +#: lib/browser.tcl:186 +msgid "[Up To Parent]" +msgstr "[Upp till förälder]" + +#: lib/browser.tcl:266 lib/browser.tcl:272 +msgid "Browse Branch Files" +msgstr "Bläddra filer pÃ¥ grenen" + +#: lib/browser.tcl:277 lib/choose_repository.tcl:391 +#: lib/choose_repository.tcl:482 lib/choose_repository.tcl:492 +#: lib/choose_repository.tcl:989 +msgid "Browse" +msgstr "Bläddra" + +#: lib/checkout_op.tcl:79 +#, tcl-format +msgid "Fetching %s from %s" +msgstr "Hämtar %s frÃ¥n %s" + +#: lib/checkout_op.tcl:127 +#, tcl-format +msgid "fatal: Cannot resolve %s" +msgstr "ödesdigert: Kunde inte slÃ¥ upp %s" + +#: lib/checkout_op.tcl:140 lib/console.tcl:79 lib/database.tcl:31 +msgid "Close" +msgstr "Stäng" + +#: lib/checkout_op.tcl:169 +#, tcl-format +msgid "Branch '%s' does not exist." +msgstr "Grenen \"%s\" finns inte." + +#: lib/checkout_op.tcl:206 +#, tcl-format +msgid "" +"Branch '%s' already exists.\n" +"\n" +"It cannot fast-forward to %s.\n" +"A merge is required." +msgstr "" +"Grenen \"%s\" finns redan.\n" +"\n" +"Den kan inte snabbspolas till %s.\n" +"En sammanslagning krävs." + +#: lib/checkout_op.tcl:220 +#, tcl-format +msgid "Merge strategy '%s' not supported." +msgstr "Sammanslagningsstrategin \"%s\" stöds inte." + +#: lib/checkout_op.tcl:239 +#, tcl-format +msgid "Failed to update '%s'." +msgstr "Misslyckades med att uppdatera \"%s\"." + +#: lib/checkout_op.tcl:251 +msgid "Staging area (index) is already locked." +msgstr "KöomrÃ¥det (index) är redan lÃ¥st." + +#: lib/checkout_op.tcl:266 +msgid "" +"Last scanned state does not match repository state.\n" +"\n" +"Another Git program has modified this repository since the last scan. A " +"rescan must be performed before the current branch can be changed.\n" +"\n" +"The rescan will be automatically started now.\n" +msgstr "" +"Det senaste inlästa tillstÃ¥ndet motsvarar inte tillstÃ¥ndet i arkivet.\n" +"\n" +"Ett annat Git-program har ändrat arkivet sedan senaste avsökningen. Du " +"mÃ¥ste utföra en ny sökning innan den aktuella grenen kan ändras.\n" +"\n" +"Sökningen kommer att startas automatiskt nu.\n" + +#: lib/checkout_op.tcl:322 +#, tcl-format +msgid "Updating working directory to '%s'..." +msgstr "Uppdaterar arbetskatalogen till \"%s\"..." + +#: lib/checkout_op.tcl:353 +#, tcl-format +msgid "Aborted checkout of '%s' (file level merging is required)." +msgstr "Avbryter utcheckning av \"%s\" (sammanslagning pÃ¥ filnivÃ¥ krävs)." + +#: lib/checkout_op.tcl:354 +msgid "File level merge required." +msgstr "Sammanslagning pÃ¥ filnivÃ¥ krävs." + +#: lib/checkout_op.tcl:358 +#, tcl-format +msgid "Staying on branch '%s'." +msgstr "Stannar pÃ¥ grenen \"%s\"." + +#: lib/checkout_op.tcl:429 +msgid "" +"You are no longer on a local branch.\n" +"\n" +"If you wanted to be on a branch, create one now starting from 'This Detached " +"Checkout'." +msgstr "" +"Du är inte längre pÃ¥ en lokal gren.\n" +"\n" +"Om du ville vara pÃ¥ en gren skapar du en nu, baserad pÃ¥ \"Denna " +"frÃ¥nkopplade utcheckning\"." + +#: lib/checkout_op.tcl:446 +#, tcl-format +msgid "Checked out '%s'." +msgstr "Checkade ut \"%s\"." + +#: lib/checkout_op.tcl:478 +#, tcl-format +msgid "Resetting '%s' to '%s' will lose the following commits:" +msgstr "Om du Ã¥terställer \"%s\" till \"%s\" fÃ¥r följande incheckningar förlorade:" + +#: lib/checkout_op.tcl:500 +msgid "Recovering lost commits may not be easy." +msgstr "Det kanske inte är sÃ¥ enkelt att Ã¥terskapa förlorade incheckningar." + +#: lib/checkout_op.tcl:505 +#, tcl-format +msgid "Reset '%s'?" +msgstr "Ã…terställa \"%s\"?" + +#: lib/checkout_op.tcl:510 lib/merge.tcl:164 +msgid "Visualize" +msgstr "Visualisera" + +#: lib/checkout_op.tcl:578 +#, tcl-format +msgid "" +"Failed to set current branch.\n" +"\n" +"This working directory is only partially switched. We successfully updated " +"your files, but failed to update an internal Git file.\n" +"\n" +"This should not have occurred. %s will now close and give up." +msgstr "" +"Kunde inte ställa in aktuell gren.\n" +"\n" +"Arbetskatalogen har bara växlats delvis. Vi uppdaterade filerna " +"utan problem, men kunde inte uppdatera en intern fil i Git.\n" +"\n" +"Detta skulle inte ha hänt. %s kommer nu stängas och ge upp." + +#: lib/choose_font.tcl:39 +msgid "Select" +msgstr "Välj" + +#: lib/choose_font.tcl:53 +msgid "Font Family" +msgstr "Teckensnittsfamilj" + +#: lib/choose_font.tcl:73 +msgid "Font Size" +msgstr "Storlek" + +#: lib/choose_font.tcl:90 +msgid "Font Example" +msgstr "Exempel" + +#: lib/choose_font.tcl:101 +msgid "" +"This is example text.\n" +"If you like this text, it can be your font." +msgstr "" +"Detta är en exempeltext.\n" +"Om du tycker om den här texten kan den vara ditt teckensnitt." + +#: lib/choose_repository.tcl:27 +msgid "Git Gui" +msgstr "Git Gui" + +#: lib/choose_repository.tcl:80 lib/choose_repository.tcl:380 +msgid "Create New Repository" +msgstr "Skapa nytt arkiv" + +#: lib/choose_repository.tcl:86 +msgid "New..." +msgstr "Nytt..." + +#: lib/choose_repository.tcl:93 lib/choose_repository.tcl:468 +msgid "Clone Existing Repository" +msgstr "Klona befintligt arkiv" + +#: lib/choose_repository.tcl:99 +msgid "Clone..." +msgstr "Klona..." + +#: lib/choose_repository.tcl:106 lib/choose_repository.tcl:978 +msgid "Open Existing Repository" +msgstr "Öppna befintligt arkiv" + +#: lib/choose_repository.tcl:112 +msgid "Open..." +msgstr "Öppna..." + +#: lib/choose_repository.tcl:125 +msgid "Recent Repositories" +msgstr "Senaste arkiven" + +#: lib/choose_repository.tcl:131 +msgid "Open Recent Repository:" +msgstr "Öppna tidigare arkiv:" + +#: lib/choose_repository.tcl:294 +#, tcl-format +msgid "Location %s already exists." +msgstr "Platsen %s finns redan." + +#: lib/choose_repository.tcl:300 lib/choose_repository.tcl:307 +#: lib/choose_repository.tcl:314 +#, tcl-format +msgid "Failed to create repository %s:" +msgstr "Kunde inte skapa arkivet %s:" + +#: lib/choose_repository.tcl:385 lib/choose_repository.tcl:486 +msgid "Directory:" +msgstr "Katalog:" + +#: lib/choose_repository.tcl:415 lib/choose_repository.tcl:544 +#: lib/choose_repository.tcl:1013 +msgid "Git Repository" +msgstr "Gitarkiv" + +#: lib/choose_repository.tcl:430 lib/choose_repository.tcl:437 +#, tcl-format +msgid "Directory %s already exists." +msgstr "Katalogen %s finns redan." + +#: lib/choose_repository.tcl:442 +#, tcl-format +msgid "File %s already exists." +msgstr "Filen %s finns redan." + +#: lib/choose_repository.tcl:463 +msgid "Clone" +msgstr "Klona" + +#: lib/choose_repository.tcl:476 +msgid "URL:" +msgstr "Webbadress:" + +#: lib/choose_repository.tcl:496 +msgid "Clone Type:" +msgstr "Typ av klon:" + +#: lib/choose_repository.tcl:502 +msgid "Standard (Fast, Semi-Redundant, Hardlinks)" +msgstr "Standard (snabb, semiredundant, hÃ¥rda länkar)" + +#: lib/choose_repository.tcl:508 +msgid "Full Copy (Slower, Redundant Backup)" +msgstr "Full kopia (lÃ¥ngsammare, redundant säkerhetskopia)" + +#: lib/choose_repository.tcl:514 +msgid "Shared (Fastest, Not Recommended, No Backup)" +msgstr "Delad (snabbast, rekommenderas ej, ingen säkerhetskopia)" + +#: lib/choose_repository.tcl:550 lib/choose_repository.tcl:597 +#: lib/choose_repository.tcl:738 lib/choose_repository.tcl:808 +#: lib/choose_repository.tcl:1019 lib/choose_repository.tcl:1027 +#, tcl-format +msgid "Not a Git repository: %s" +msgstr "Inte ett Gitarkiv: %s" + +#: lib/choose_repository.tcl:586 +msgid "Standard only available for local repository." +msgstr "Standard är endast tillgängligt för lokala arkiv." + +#: lib/choose_repository.tcl:590 +msgid "Shared only available for local repository." +msgstr "Delat är endast tillgängligt för lokala arkiv." + +#: lib/choose_repository.tcl:617 +msgid "Failed to configure origin" +msgstr "Kunde inte konfigurera ursprung" + +#: lib/choose_repository.tcl:629 +msgid "Counting objects" +msgstr "Räknar objekt" + +#: lib/choose_repository.tcl:630 +msgid "buckets" +msgstr "hinkar" + +#: lib/choose_repository.tcl:654 +#, tcl-format +msgid "Unable to copy objects/info/alternates: %s" +msgstr "Kunde inte kopiera objekt/info/alternativ: %s" + +#: lib/choose_repository.tcl:690 +#, tcl-format +msgid "Nothing to clone from %s." +msgstr "Ingenting att klona frÃ¥n %s." + +#: lib/choose_repository.tcl:692 lib/choose_repository.tcl:906 +#: lib/choose_repository.tcl:918 +msgid "The 'master' branch has not been initialized." +msgstr "Grenen \"master\" har inte initierats." + +#: lib/choose_repository.tcl:705 +msgid "Hardlinks are unavailable. Falling back to copying." +msgstr "HÃ¥rda länkar är inte tillgängliga. Faller tillbaka pÃ¥ kopiering." + +#: lib/choose_repository.tcl:717 +#, tcl-format +msgid "Cloning from %s" +msgstr "Klonar frÃ¥n %s" + +#: lib/choose_repository.tcl:748 +msgid "Copying objects" +msgstr "Kopierar objekt" + +#: lib/choose_repository.tcl:749 +msgid "KiB" +msgstr "KiB" + +#: lib/choose_repository.tcl:773 +#, tcl-format +msgid "Unable to copy object: %s" +msgstr "Kunde inte kopiera objekt: %s" + +#: lib/choose_repository.tcl:783 +msgid "Linking objects" +msgstr "Länkar objekt" + +#: lib/choose_repository.tcl:784 +msgid "objects" +msgstr "objekt" + +#: lib/choose_repository.tcl:792 +#, tcl-format +msgid "Unable to hardlink object: %s" +msgstr "Kunde inte hÃ¥rdlänka objekt: %s" + +#: lib/choose_repository.tcl:847 +msgid "Cannot fetch branches and objects. See console output for details." +msgstr "Kunde inte hämta grenar och objekt. Se konsolutdata för detaljer." + +#: lib/choose_repository.tcl:858 +msgid "Cannot fetch tags. See console output for details." +msgstr "Kunde inte hämta taggar. Se konsolutdata för detaljer." + +#: lib/choose_repository.tcl:882 +msgid "Cannot determine HEAD. See console output for details." +msgstr "Kunde inte avgöra HEAD. Se konsolutdata för detaljer." + +#: lib/choose_repository.tcl:891 +#, tcl-format +msgid "Unable to cleanup %s" +msgstr "Kunde inte städa upp %s" + +#: lib/choose_repository.tcl:897 +msgid "Clone failed." +msgstr "Kloning misslyckades." + +#: lib/choose_repository.tcl:904 +msgid "No default branch obtained." +msgstr "Hämtade ingen standardgren." + +#: lib/choose_repository.tcl:915 +#, tcl-format +msgid "Cannot resolve %s as a commit." +msgstr "Kunde inte slÃ¥ upp %s till nÃ¥gon incheckning." + +#: lib/choose_repository.tcl:927 +msgid "Creating working directory" +msgstr "Skapar arbetskatalog" + +#: lib/choose_repository.tcl:928 lib/index.tcl:65 lib/index.tcl:127 +#: lib/index.tcl:193 +msgid "files" +msgstr "filer" + +#: lib/choose_repository.tcl:957 +msgid "Initial file checkout failed." +msgstr "Inledande filutcheckning misslyckades." + +#: lib/choose_repository.tcl:973 +msgid "Open" +msgstr "Öppna" + +#: lib/choose_repository.tcl:983 +msgid "Repository:" +msgstr "Arkiv:" + +#: lib/choose_repository.tcl:1033 +#, tcl-format +msgid "Failed to open repository %s:" +msgstr "Kunde inte öppna arkivet %s:" + +#: lib/choose_rev.tcl:53 +msgid "This Detached Checkout" +msgstr "Denna frÃ¥nkopplade utcheckning" + +#: lib/choose_rev.tcl:60 +msgid "Revision Expression:" +msgstr "Revisionsuttryck:" + +#: lib/choose_rev.tcl:74 +msgid "Local Branch" +msgstr "Lokal gren" + +#: lib/choose_rev.tcl:79 +msgid "Tracking Branch" +msgstr "SpÃ¥rande gren" + +#: lib/choose_rev.tcl:84 lib/choose_rev.tcl:537 +msgid "Tag" +msgstr "Tagg" + +#: lib/choose_rev.tcl:317 +#, tcl-format +msgid "Invalid revision: %s" +msgstr "Ogiltig revision: %s" + +#: lib/choose_rev.tcl:338 +msgid "No revision selected." +msgstr "Ingen revision vald." + +#: lib/choose_rev.tcl:346 +msgid "Revision expression is empty." +msgstr "Revisionsuttrycket är tomt." + +#: lib/choose_rev.tcl:530 +msgid "Updated" +msgstr "Uppdaterad" + +#: lib/choose_rev.tcl:558 +msgid "URL" +msgstr "Webbadress" + +#: lib/commit.tcl:9 +msgid "" +"There is nothing to amend.\n" +"\n" +"You are about to create the initial commit. There is no commit before this " +"to amend.\n" +msgstr "" +"Det finns ingenting att utöka.\n" +"\n" +"Du hÃ¥ller pÃ¥ att skapa den inledande incheckningen. Det finns ingen tidigare " +"incheckning att utöka.\n" + +#: lib/commit.tcl:18 +msgid "" +"Cannot amend while merging.\n" +"\n" +"You are currently in the middle of a merge that has not been fully " +"completed. You cannot amend the prior commit unless you first abort the " +"current merge activity.\n" +msgstr "" +"Kan inte utöka vid sammanslagning.\n" +"\n" +"Du är i mitten av en sammanslagning som inte är fullbordad. Du kan " +"inte utöka tidigare incheckningar om du inte först avbryter den " +"pÃ¥gÃ¥ende sammanslagningen.\n" + +#: lib/commit.tcl:49 +msgid "Error loading commit data for amend:" +msgstr "Fel vid inläsning av incheckningsdata för utökning:" + +#: lib/commit.tcl:76 +msgid "Unable to obtain your identity:" +msgstr "Kunde inte hämta din identitet:" + +#: lib/commit.tcl:81 +msgid "Invalid GIT_COMMITTER_IDENT:" +msgstr "Felaktig GIT_COMMITTER_IDENT:" + +#: lib/commit.tcl:133 +msgid "" +"Last scanned state does not match repository state.\n" +"\n" +"Another Git program has modified this repository since the last scan. A " +"rescan must be performed before another commit can be created.\n" +"\n" +"The rescan will be automatically started now.\n" +msgstr "" +"Det senaste inlästa tillstÃ¥ndet motsvarar inte tillstÃ¥ndet i arkivet.\n" +"\n" +"Ett annat Git-program har ändrat arkivet sedan senaste avsökningen. Du " +"mÃ¥ste utföra en ny sökning innan du kan göra en ny incheckning.\n" +"\n" +"Sökningen kommer att startas automatiskt nu.\n" + +#: lib/commit.tcl:154 +#, tcl-format +msgid "" +"Unmerged files cannot be committed.\n" +"\n" +"File %s has merge conflicts. You must resolve them and stage the file " +"before committing.\n" +msgstr "" +"Osammanslagna filer kan inte checkas in.\n" +"\n" +"Filen %s har sammanslagningskonflikter. Du mÃ¥ste lösa dem och köa filen " +"innan du checkar in den.\n" + +#: lib/commit.tcl:162 +#, tcl-format +msgid "" +"Unknown file state %s detected.\n" +"\n" +"File %s cannot be committed by this program.\n" +msgstr "" +"Okänd filstatus %s upptäckt.\n" +"\n" +"Filen %s kan inte checkas in av programmet.\n" + +#: lib/commit.tcl:170 +msgid "" +"No changes to commit.\n" +"\n" +"You must stage at least 1 file before you can commit.\n" +msgstr "" +"Inga ändringar att checka in.\n" +"\n" +"Du mÃ¥ste köa Ã¥tminstone en fil innan du kan checka in.\n" + +#: lib/commit.tcl:183 +msgid "" +"Please supply a commit message.\n" +"\n" +"A good commit message has the following format:\n" +"\n" +"- First line: Describe in one sentence what you did.\n" +"- Second line: Blank\n" +"- Remaining lines: Describe why this change is good.\n" +msgstr "" +"Ange ett incheckningsmeddelande.\n" +"\n" +"Ett bra incheckningsmeddelande har följande format:\n" +"\n" +"- Första raden: Beskriv i en mening vad du gjorde.\n" +"- Andra raden: Tom\n" +"- Följande rader: Beskriv varför det här är en bra ändring.\n" + +#: lib/commit.tcl:257 +msgid "write-tree failed:" +msgstr "write-tree misslyckades:" + +#: lib/commit.tcl:275 +#, tcl-format +msgid "Commit %s appears to be corrupt" +msgstr "Incheckningen %s verkar vara trasig" + +#: lib/commit.tcl:279 +msgid "" +"No changes to commit.\n" +"\n" +"No files were modified by this commit and it was not a merge commit.\n" +"\n" +"A rescan will be automatically started now.\n" +msgstr "" +"Inga ändringar att checka in.\n" +"\n" +"Inga filer ändrades av incheckningen och det var inte en sammanslagning.\n" +"\n" +"En sökning kommer att startas automatiskt nu.\n" + +#: lib/commit.tcl:286 +msgid "No changes to commit." +msgstr "Inga ändringar att checka in." + +#: lib/commit.tcl:303 +#, tcl-format +msgid "warning: Tcl does not support encoding '%s'." +msgstr "varning: Tcl stöder inte teckenkodningen \"%s\"." + +#: lib/commit.tcl:317 +msgid "commit-tree failed:" +msgstr "commit-tree misslyckades:" + +#: lib/commit.tcl:339 +msgid "update-ref failed:" +msgstr "update-ref misslyckades:" + +#: lib/commit.tcl:430 +#, tcl-format +msgid "Created commit %s: %s" +msgstr "Skapade incheckningen %s: %s" + +#: lib/console.tcl:57 +msgid "Working... please wait..." +msgstr "Arbetar... vänta..." + +#: lib/console.tcl:183 +msgid "Success" +msgstr "Lyckades" + +#: lib/console.tcl:196 +msgid "Error: Command Failed" +msgstr "Fel: Kommando misslyckades" + +#: lib/database.tcl:43 +msgid "Number of loose objects" +msgstr "Antal lösa objekt" + +#: lib/database.tcl:44 +msgid "Disk space used by loose objects" +msgstr "Diskutrymme använt av lösa objekt" + +#: lib/database.tcl:45 +msgid "Number of packed objects" +msgstr "Antal packade objekt" + +#: lib/database.tcl:46 +msgid "Number of packs" +msgstr "Antal paket" + +#: lib/database.tcl:47 +msgid "Disk space used by packed objects" +msgstr "Diskutrymme använt av packade objekt" + +#: lib/database.tcl:48 +msgid "Packed objects waiting for pruning" +msgstr "Packade objekt som väntar pÃ¥ städning" + +#: lib/database.tcl:49 +msgid "Garbage files" +msgstr "Skräpfiler" + +#: lib/database.tcl:72 +msgid "Compressing the object database" +msgstr "Komprimerar objektdatabasen" + +#: lib/database.tcl:83 +msgid "Verifying the object database with fsck-objects" +msgstr "Verifierar objektdatabasen med fsck-objects" + +#: lib/database.tcl:108 +#, tcl-format +msgid "" +"This repository currently has approximately %i loose objects.\n" +"\n" +"To maintain optimal performance it is strongly recommended that you compress " +"the database when more than %i loose objects exist.\n" +"\n" +"Compress the database now?" +msgstr "" +"Arkivet har för närvarande omkring %i lösa objekt.\n" +"\n" +"För att bibehÃ¥lla optimal prestanda rekommenderas det Ã¥ det bestämdaste att " +"du komprimerar databasen när den innehÃ¥ller mer än %i lösa objekt.\n" +"\n" +"Komprimera databasen nu?" + +#: lib/date.tcl:25 +#, tcl-format +msgid "Invalid date from Git: %s" +msgstr "Ogiltigt datum frÃ¥n Git: %s" + +#: lib/diff.tcl:42 +#, tcl-format +msgid "" +"No differences detected.\n" +"\n" +"%s has no changes.\n" +"\n" +"The modification date of this file was updated by another application, but " +"the content within the file was not changed.\n" +"\n" +"A rescan will be automatically started to find other files which may have " +"the same state." +msgstr "" +"Hittade inga skillnader.\n" +"\n" +"%s innehÃ¥ller inga ändringar.\n" +"\n" +"Modifieringsdatum för filen uppdaterades av ett annat program, men innehÃ¥llet " +"i filen har inte ändrats.\n" +"\n" +"En sökning kommer automatiskt att startas för att hitta andra filer som kan " +"vara i samma tillstÃ¥nd." + +#: lib/diff.tcl:81 +#, tcl-format +msgid "Loading diff of %s..." +msgstr "Läser differens för %s..." + +#: lib/diff.tcl:114 lib/diff.tcl:184 +#, tcl-format +msgid "Unable to display %s" +msgstr "Kan inte visa %s" + +#: lib/diff.tcl:115 +msgid "Error loading file:" +msgstr "Fel vid läsning av fil:" + +#: lib/diff.tcl:122 +msgid "Git Repository (subproject)" +msgstr "Gitarkiv (underprojekt)" + +#: lib/diff.tcl:134 +msgid "* Binary file (not showing content)." +msgstr "* Binärfil (visar inte innehÃ¥llet)." + +#: lib/diff.tcl:185 +msgid "Error loading diff:" +msgstr "Fel vid inläsning av differens:" + +#: lib/diff.tcl:302 +msgid "Failed to unstage selected hunk." +msgstr "Kunde inte ta bort den valda delen frÃ¥n kön." + +#: lib/diff.tcl:309 +msgid "Failed to stage selected hunk." +msgstr "Kunde inte lägga till den valda delen till kön." + +#: lib/error.tcl:12 lib/error.tcl:102 +msgid "error" +msgstr "fel" + +#: lib/error.tcl:28 +msgid "warning" +msgstr "varning" + +#: lib/error.tcl:81 +msgid "You must correct the above errors before committing." +msgstr "Du mÃ¥ste rätta till felen ovan innan du checkar in." + +#: lib/index.tcl:6 +msgid "Unable to unlock the index." +msgstr "Kunde inte lÃ¥sa upp indexet." + +#: lib/index.tcl:15 +msgid "Index Error" +msgstr "Indexfel" + +#: lib/index.tcl:21 +msgid "" +"Updating the Git index failed. A rescan will be automatically started to " +"resynchronize git-gui." +msgstr "" +"Misslyckades med att uppdatera Gitindexet. En omsökning kommer att startas " +"automatiskt för att synkronisera om git-gui." + +#: lib/index.tcl:27 +msgid "Continue" +msgstr "Forstätt" + +#: lib/index.tcl:31 +msgid "Unlock Index" +msgstr "LÃ¥s upp index" + +#: lib/index.tcl:282 +#, tcl-format +msgid "Unstaging %s from commit" +msgstr "Tar bort %s för incheckningskön" + +#: lib/index.tcl:326 +#, tcl-format +msgid "Adding %s" +msgstr "Lägger till %s" + +#: lib/index.tcl:381 +#, tcl-format +msgid "Revert changes in file %s?" +msgstr "Ã…terställ ändringarna i filen %s?" + +#: lib/index.tcl:383 +#, tcl-format +msgid "Revert changes in these %i files?" +msgstr "Ã…terställ ändringarna i dessa %i filer?" + +#: lib/index.tcl:389 +msgid "Any unstaged changes will be permanently lost by the revert." +msgstr "Alla oköade ändringar kommer permanent gÃ¥ förlorade vid Ã¥terställningen." + +#: lib/index.tcl:392 +msgid "Do Nothing" +msgstr "Gör ingenting" + +#: lib/merge.tcl:13 +msgid "" +"Cannot merge while amending.\n" +"\n" +"You must finish amending this commit before starting any type of merge.\n" +msgstr "" +"Kan inte slÃ¥ ihop vid utökning.\n" +"\n" +"Du mÃ¥ste föra färdig utökningen av incheckningen innan du pÃ¥börjar nÃ¥gon " +"slags sammanslagning.\n" + +#: lib/merge.tcl:27 +msgid "" +"Last scanned state does not match repository state.\n" +"\n" +"Another Git program has modified this repository since the last scan. A " +"rescan must be performed before a merge can be performed.\n" +"\n" +"The rescan will be automatically started now.\n" +msgstr "" +"Det senaste inlästa tillstÃ¥ndet motsvarar inte tillstÃ¥ndet i arkivet.\n" +"\n" +"Ett annat Git-program har ändrat arkivet sedan senaste avsökningen. Du " +"mÃ¥ste utföra en ny sökning innan du kan utföra en sammanslagning.\n" +"\n" +"Sökningen kommer att startas automatiskt nu.\n" + +#: lib/merge.tcl:44 +#, tcl-format +msgid "" +"You are in the middle of a conflicted merge.\n" +"\n" +"File %s has merge conflicts.\n" +"\n" +"You must resolve them, stage the file, and commit to complete the current " +"merge. Only then can you begin another merge.\n" +msgstr "" +"Du är mitt i en sammanslagning med konflikter.\n" +"\n" +"Filen %s har sammanslagningskonflikter.\n" +"\n" +"Du mÃ¥ste lösa dem, köa filen och checka in för att fullborda den aktuella " +"sammanslagningen. När du gjort det kan du pÃ¥börja en ny sammanslagning.\n" + +#: lib/merge.tcl:54 +#, tcl-format +msgid "" +"You are in the middle of a change.\n" +"\n" +"File %s is modified.\n" +"\n" +"You should complete the current commit before starting a merge. Doing so " +"will help you abort a failed merge, should the need arise.\n" +msgstr "" +"Du är mitt i en ändring.\n" +"\n" +"Filen %s har ändringar.\n" +"\n" +"Du bör fullborda den aktuella incheckningen innan du pÃ¥börjar en " +"sammanslagning. Om du gör det blir det enklare att avbryta en misslyckad " +"sammanslagning, om det skulle vara nödvändigt.\n" + +#: lib/merge.tcl:106 +#, tcl-format +msgid "%s of %s" +msgstr "%s av %s" + +#: lib/merge.tcl:119 +#, tcl-format +msgid "Merging %s and %s" +msgstr "SlÃ¥r ihop %s och %s" + +#: lib/merge.tcl:131 +msgid "Merge completed successfully." +msgstr "Sammanslagningen avslutades framgÃ¥ngsrikt." + +#: lib/merge.tcl:133 +msgid "Merge failed. Conflict resolution is required." +msgstr "Sammanslagningen misslyckades. Du mÃ¥ste lösa konflikterna." + +#: lib/merge.tcl:158 +#, tcl-format +msgid "Merge Into %s" +msgstr "SlÃ¥ ihop i %s" + +#: lib/merge.tcl:177 +msgid "Revision To Merge" +msgstr "Revisioner att slÃ¥ ihop" + +#: lib/merge.tcl:212 +msgid "" +"Cannot abort while amending.\n" +"\n" +"You must finish amending this commit.\n" +msgstr "" +"Kan inte avbryta vid utökning.\n" +"\n" +"Du mÃ¥ste göra dig färdig med att utöka incheckningen.\n" + +#: lib/merge.tcl:222 +msgid "" +"Abort merge?\n" +"\n" +"Aborting the current merge will cause *ALL* uncommitted changes to be lost.\n" +"\n" +"Continue with aborting the current merge?" +msgstr "" +"Avbryt sammanslagning?\n" +"\n" +"Om du avbryter sammanslagningen kommer *ALLA* ej incheckade ändringar att " +"gÃ¥ förlorade.\n" +"\n" +"GÃ¥ vidare med att avbryta den aktuella sammanslagningen?" + +#: lib/merge.tcl:228 +msgid "" +"Reset changes?\n" +"\n" +"Resetting the changes will cause *ALL* uncommitted changes to be lost.\n" +"\n" +"Continue with resetting the current changes?" +msgstr "" +"Ã…terställ ändringar?\n" +"\n" +"Om du Ã¥terställer ändringarna kommer *ALLA* ej incheckade ändringar att " +"gÃ¥ förlorade.\n" +"\n" +"GÃ¥ vidare med att Ã¥terställa de aktuella ändringarna?" + +#: lib/merge.tcl:239 +msgid "Aborting" +msgstr "Avbryter" + +#: lib/merge.tcl:266 +msgid "Abort failed." +msgstr "Misslyckades avbryta." + +#: lib/merge.tcl:268 +msgid "Abort completed. Ready." +msgstr "Avbrytning fullbordad. Redo." + +#: lib/option.tcl:82 +msgid "Restore Defaults" +msgstr "Ã…terställ standardvärden" + +#: lib/option.tcl:86 +msgid "Save" +msgstr "Spara" + +#: lib/option.tcl:96 +#, tcl-format +msgid "%s Repository" +msgstr "Arkivet %s" + +#: lib/option.tcl:97 +msgid "Global (All Repositories)" +msgstr "Globalt (alla arkiv)" + +#: lib/option.tcl:103 +msgid "User Name" +msgstr "Användarnamn" + +#: lib/option.tcl:104 +msgid "Email Address" +msgstr "E-postadress" + +#: lib/option.tcl:106 +msgid "Summarize Merge Commits" +msgstr "Summera sammanslagningsincheckningar" + +#: lib/option.tcl:107 +msgid "Merge Verbosity" +msgstr "Pratsamhet för sammanslagningar" + +#: lib/option.tcl:108 +msgid "Show Diffstat After Merge" +msgstr "Visa diffstatistik efter sammanslagning" + +#: lib/option.tcl:110 +msgid "Trust File Modification Timestamps" +msgstr "Lita pÃ¥ filändringstidsstämplar" + +#: lib/option.tcl:111 +msgid "Prune Tracking Branches During Fetch" +msgstr "Städa spÃ¥rade grenar vid hämtning" + +#: lib/option.tcl:112 +msgid "Match Tracking Branches" +msgstr "Matcha spÃ¥rade grenar" + +#: lib/option.tcl:113 +msgid "Number of Diff Context Lines" +msgstr "Antal rader sammanhang i differenser" + +#: lib/option.tcl:114 +msgid "New Branch Name Template" +msgstr "Mall för namn pÃ¥ nya grenar" + +#: lib/option.tcl:176 +msgid "Change Font" +msgstr "Byt teckensnitt" + +#: lib/option.tcl:180 +#, tcl-format +msgid "Choose %s" +msgstr "Välj %s" + +#: lib/option.tcl:186 +msgid "pt." +msgstr "p." + +#: lib/option.tcl:200 +msgid "Preferences" +msgstr "Inställningar" + +#: lib/option.tcl:235 +msgid "Failed to completely save options:" +msgstr "Misslyckades med att helt spara alternativ:" + +#: lib/remote_branch_delete.tcl:29 lib/remote_branch_delete.tcl:34 +msgid "Delete Remote Branch" +msgstr "Ta bort fjärrgren" + +#: lib/remote_branch_delete.tcl:47 +msgid "From Repository" +msgstr "FrÃ¥n arkiv" + +#: lib/remote_branch_delete.tcl:50 lib/transport.tcl:123 +msgid "Remote:" +msgstr "Fjärr:" + +#: lib/remote_branch_delete.tcl:66 lib/transport.tcl:138 +msgid "Arbitrary URL:" +msgstr "Godtycklig webbadress:" + +#: lib/remote_branch_delete.tcl:84 +msgid "Branches" +msgstr "Grenar" + +#: lib/remote_branch_delete.tcl:109 +msgid "Delete Only If" +msgstr "Ta endast bort om" + +#: lib/remote_branch_delete.tcl:111 +msgid "Merged Into:" +msgstr "Sammanslagen i:" + +#: lib/remote_branch_delete.tcl:119 +msgid "Always (Do not perform merge checks)" +msgstr "Alltid (utför inte sammanslagningstest)" + +#: lib/remote_branch_delete.tcl:152 +msgid "A branch is required for 'Merged Into'." +msgstr "En gren krävs för \"Sammanslagen i\"." + +#: lib/remote_branch_delete.tcl:184 +#, tcl-format +msgid "" +"The following branches are not completely merged into %s:\n" +"\n" +" - %s" +msgstr "" +"Följande grenar har inte helt slagits samman i %s:\n" +"\n" +" - %s" + +#: lib/remote_branch_delete.tcl:189 +#, tcl-format +msgid "" +"One or more of the merge tests failed because you have not fetched the " +"necessary commits. Try fetching from %s first." +msgstr "" +"En eller flera av sammanslagningstesterna misslyckades eftersom du inte " +"har hämtat de nödvändiga incheckningarna. Försök hämta frÃ¥n %s först." + +#: lib/remote_branch_delete.tcl:207 +msgid "Please select one or more branches to delete." +msgstr "Välj en eller flera grenar att ta bort." + +#: lib/remote_branch_delete.tcl:216 +msgid "" +"Recovering deleted branches is difficult.\n" +"\n" +"Delete the selected branches?" +msgstr "" +"Det kan vara svÃ¥rt att Ã¥terställa grenar.\n" +"\n" +"Ta bort de valda grenarna?" + +#: lib/remote_branch_delete.tcl:226 +#, tcl-format +msgid "Deleting branches from %s" +msgstr "Tar bort grenar frÃ¥n %s" + +#: lib/remote_branch_delete.tcl:286 +msgid "No repository selected." +msgstr "Inget arkiv markerat." + +#: lib/remote_branch_delete.tcl:291 +#, tcl-format +msgid "Scanning %s..." +msgstr "Söker %s..." + +#: lib/remote.tcl:165 +msgid "Prune from" +msgstr "Ta bort frÃ¥n" + +#: lib/remote.tcl:170 +msgid "Fetch from" +msgstr "Hämta frÃ¥n" + +#: lib/remote.tcl:213 +msgid "Push to" +msgstr "Sänd till" + +#: lib/shortcut.tcl:20 lib/shortcut.tcl:61 +msgid "Cannot write shortcut:" +msgstr "Kan inte skriva genväg:" + +#: lib/shortcut.tcl:136 +msgid "Cannot write icon:" +msgstr "Kan inte skriva ikon:" + +#: lib/status_bar.tcl:83 +#, tcl-format +msgid "%s ... %*i of %*i %s (%3i%%)" +msgstr "%s... %*i av %*i %s (%3i%%)" + +#: lib/transport.tcl:6 +#, tcl-format +msgid "fetch %s" +msgstr "hämta %s" + +#: lib/transport.tcl:7 +#, tcl-format +msgid "Fetching new changes from %s" +msgstr "Hämtar nya ändringar frÃ¥n %s" + +#: lib/transport.tcl:18 +#, tcl-format +msgid "remote prune %s" +msgstr "fjärrborttagning %s" + +#: lib/transport.tcl:19 +#, tcl-format +msgid "Pruning tracking branches deleted from %s" +msgstr "Tar bort spÃ¥rande grenar som tagits bort frÃ¥n %s" + +#: lib/transport.tcl:25 lib/transport.tcl:71 +#, tcl-format +msgid "push %s" +msgstr "sänd %s" + +#: lib/transport.tcl:26 +#, tcl-format +msgid "Pushing changes to %s" +msgstr "Sänder ändringar till %s" + +#: lib/transport.tcl:72 +#, tcl-format +msgid "Pushing %s %s to %s" +msgstr "Sänder %s %s till %s" + +#: lib/transport.tcl:89 +msgid "Push Branches" +msgstr "Sänder grenar" + +#: lib/transport.tcl:103 +msgid "Source Branches" +msgstr "Källgrenar" + +#: lib/transport.tcl:120 +msgid "Destination Repository" +msgstr "Destinationsarkiv" + +#: lib/transport.tcl:158 +msgid "Transfer Options" +msgstr "Överföringsalternativ" + +#: lib/transport.tcl:160 +msgid "Force overwrite existing branch (may discard changes)" +msgstr "Tvinga överskrivning av befintlig gren (kan kasta bort ändringar)" + +#: lib/transport.tcl:164 +msgid "Use thin pack (for slow network connections)" +msgstr "Använd tunt paket (för lÃ¥ngsamma nätverksanslutningar)" + +#: lib/transport.tcl:168 +msgid "Include tags" +msgstr "Ta med taggar" + From a6d5888fa1bb24ef34ce36f0e684d13a58eba908 Mon Sep 17 00:00:00 2001 From: Bernt Hansen Date: Thu, 27 Dec 2007 21:15:56 -0500 Subject: [PATCH 14/93] git-gui: Make commit log messages end with a newline Concatenating commit log messages from multiple commits works better when all of the commits end with a clean line break. Its good to be strict in what you create, and lenient in what you accept, and since we're creating here, we should always try to Do The Right Thing(tm). Signed-off-by: Bernt Hansen Signed-off-by: Shawn O. Pearce --- lib/commit.tcl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/commit.tcl b/lib/commit.tcl index b2d2d53086..1c0586c409 100644 --- a/lib/commit.tcl +++ b/lib/commit.tcl @@ -303,7 +303,7 @@ A rescan will be automatically started now. puts stderr [mc "warning: Tcl does not support encoding '%s'." $enc] fconfigure $msg_wt -encoding utf-8 } - puts -nonewline $msg_wt $msg + puts $msg_wt $msg close $msg_wt # -- Create the commit. From d6ed263fc7458e97ad032837ffdab6013d039543 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gr=C3=A9goire=20Barbier?= Date: Sun, 30 Dec 2007 18:15:51 +0100 Subject: [PATCH 15/93] Fix double-free() in http-push.c:remote_exists() Signed-off-by: Junio C Hamano --- http-push.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/http-push.c b/http-push.c index 64be904921..55d0c944ae 100644 --- a/http-push.c +++ b/http-push.c @@ -1979,7 +1979,6 @@ static int remote_exists(const char *path) if (start_active_slot(slot)) { run_active_slot(slot); - free(url); if (results.http_code == 404) ret = 0; else if (results.curl_result == CURLE_OK) @@ -1987,7 +1986,6 @@ static int remote_exists(const char *path) else fprintf(stderr, "HEAD HTTP error %ld\n", results.http_code); } else { - free(url); fprintf(stderr, "Unable to start HEAD request\n"); } From 8ad1065e580c03035c583e2d237cc5b76f90cee4 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sun, 30 Dec 2007 12:37:59 -0800 Subject: [PATCH 16/93] git-rebase -i behaves better on commits with incomplete messages The commit message template when squashing multiple commits is prepared by concatenating the messages of existing commits together. If the messages from some of them end with incomplete lines, this would result in a suboptimal message template. Make sure that we add a terminating LF after each commit message. Signed-off-by: Junio C Hamano --- git-rebase--interactive.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh index 090c3e5143..d0d83c35e6 100755 --- a/git-rebase--interactive.sh +++ b/git-rebase--interactive.sh @@ -215,15 +215,17 @@ make_squash_message () { COUNT=$(($(sed -n "s/^# This is [^0-9]*\([1-9][0-9]*\).*/\1/p" \ < "$SQUASH_MSG" | tail -n 1)+1)) echo "# This is a combination of $COUNT commits." - sed -n "2,\$p" < "$SQUASH_MSG" + sed -e 1d -e '2,/^./{ + /^$/d + }' <"$SQUASH_MSG" else COUNT=2 echo "# This is a combination of two commits." echo "# The first commit's message is:" echo git cat-file commit HEAD | sed -e '1,/^$/d' - echo fi + echo echo "# This is the $(nth_string $COUNT) commit message:" echo git cat-file commit $1 | sed -e '1,/^$/d' From ab11903225270be7001b8c92f6ac4e165eaf4ecf Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sun, 30 Dec 2007 12:51:42 -0800 Subject: [PATCH 17/93] git-rebase -i: clean-up error check codepath. After replaying a single change, the code performed a number of checks, but some of them were for sanity checking, failures from which should make the command abort, and others were checks to see if it should make a new commit object. Stringing them together with "&&" was wrong. Signed-off-by: Junio C Hamano --- git-rebase--interactive.sh | 29 +++++++++++++++++++---------- 1 file changed, 19 insertions(+), 10 deletions(-) diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh index d0d83c35e6..acdcc5417a 100755 --- a/git-rebase--interactive.sh +++ b/git-rebase--interactive.sh @@ -365,17 +365,26 @@ do test -d "$DOTEST" || die "No interactive rebase running" - # commit if necessary - git rev-parse --verify HEAD > /dev/null && - git update-index --refresh && - git diff-files --quiet && - ! git diff-index --cached --quiet HEAD -- && - . "$DOTEST"/author-script && { - test ! -f "$DOTEST"/amend || git reset --soft HEAD^ - } && - export GIT_AUTHOR_NAME GIT_AUTHOR_EMAIL GIT_AUTHOR_DATE && - if ! git commit --no-verify -F "$DOTEST"/message -e + # Sanity check + git rev-parse --verify HEAD >/dev/null || + die "Cannot read HEAD" + git update-index --refresh && git diff-files --quiet || + die "Working tree is dirty" + + # do we have anything to commit? + if git diff-index --cached --quiet HEAD -- then + : Nothing to commit -- skip this + else + . "$DOTEST"/author-script || + die "Cannot find the author identity" + if test -f "$DOTEST"/amend + then + git reset --soft HEAD^ || + die "Cannot rewind the HEAD" + fi + export GIT_AUTHOR_NAME GIT_AUTHOR_EMAIL GIT_AUTHOR_DATE && + git commit --no-verify -F "$DOTEST"/message -e || die "Could not commit staged changes." fi From a495e5a9080080dd2a9a02c5b3f27f1d48a3f0cd Mon Sep 17 00:00:00 2001 From: Paul Mackerras Date: Mon, 31 Dec 2007 12:49:13 +1100 Subject: [PATCH 18/93] gitk: Recode de.po to UTF-8 Somehow de.po got recoded to latin-1 in the process of committing it. This recodes it back to UTF-8. Signed-off-by: Paul Mackerras --- po/de.po | 54 +++++++++++++++++++++++++++--------------------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/po/de.po b/po/de.po index a4fdf9a6b9..19d048b683 100644 --- a/po/de.po +++ b/po/de.po @@ -33,7 +33,7 @@ msgstr "Git log Ausgabe kann nicht erkannt werden:" #: gitk:375 gitk:2155 msgid "No commits selected" -msgstr "Keine Versionen ausgewählt." +msgstr "Keine Versionen ausgewählt." #: gitk:486 msgid "No commit information available" @@ -90,7 +90,7 @@ msgstr "Ansicht bearbeiten..." #: gitk:651 gitk:2094 gitk:8667 msgid "Delete view" -msgstr "Ansicht löschen" +msgstr "Ansicht löschen" #: gitk:653 msgid "All files" @@ -102,11 +102,11 @@ msgstr "Hilfe" #: gitk:658 gitk:1280 msgid "About gitk" -msgstr "Über gitk" +msgstr "Über gitk" #: gitk:659 msgid "Key bindings" -msgstr "Tastenkürzel" +msgstr "Tastenkürzel" #: gitk:716 msgid "SHA1 ID: " @@ -118,7 +118,7 @@ msgstr "Suche" #: gitk:767 msgid "next" -msgstr "nächste" +msgstr "nächste" #: gitk:768 msgid "prev" @@ -138,7 +138,7 @@ msgstr "Pfad betreffend:" #: gitk:776 gitk:2396 msgid "adding/removing string:" -msgstr "String dazu/löschen:" +msgstr "String dazu/löschen:" #: gitk:787 gitk:789 msgid "Exact" @@ -146,7 +146,7 @@ msgstr "Exakt" #: gitk:789 gitk:2474 gitk:4233 msgid "IgnCase" -msgstr "Kein Groß/Klein" +msgstr "Kein Groß/Klein" #: gitk:789 gitk:2365 gitk:2472 gitk:4229 msgid "Regexp" @@ -158,7 +158,7 @@ msgstr "Alle Felder" #: gitk:794 gitk:2491 gitk:2523 gitk:4295 msgid "Headline" -msgstr "Überschrift" +msgstr "Überschrift" #: gitk:795 gitk:2491 gitk:4295 gitk:4395 gitk:4783 msgid "Comments" @@ -203,11 +203,11 @@ msgstr "Baum" #: gitk:1018 gitk:1033 gitk:5969 msgid "Diff this -> selected" -msgstr "Vergleich diese -> gewählte" +msgstr "Vergleich diese -> gewählte" #: gitk:1020 gitk:1035 gitk:5970 msgid "Diff selected -> this" -msgstr "Vergleich gewählte -> diese" +msgstr "Vergleich gewählte -> diese" #: gitk:1022 gitk:1037 gitk:5971 msgid "Make patch" @@ -227,11 +227,11 @@ msgstr "Neuen Zweig erstellen" #: gitk:1026 msgid "Cherry-pick this commit" -msgstr "Diese Version pflücken" +msgstr "Diese Version pflücken" #: gitk:1028 msgid "Reset HEAD branch to here" -msgstr "HEAD-Zweig auf diese Version zurücksetzen" +msgstr "HEAD-Zweig auf diese Version zurücksetzen" #: gitk:1044 msgid "Check out this branch" @@ -239,7 +239,7 @@ msgstr "Auf diesen Zweig umstellen" #: gitk:1046 msgid "Remove this branch" -msgstr "Zweig löschen" +msgstr "Zweig löschen" #: gitk:1052 msgid "Highlight this too" @@ -254,14 +254,14 @@ msgid "" "\n" "Gitk - a commit viewer for git\n" "\n" -"Copyright © 2005-2006 Paul Mackerras\n" +"Copyright © 2005-2006 Paul Mackerras\n" "\n" "Use and redistribute under the terms of the GNU General Public License" msgstr "" #: gitk:1290 gitk:1354 gitk:6532 msgid "Close" -msgstr "Schließen" +msgstr "Schließen" #: gitk:1311 msgid "Gitk key bindings" @@ -389,7 +389,7 @@ msgstr "Kinder" #: gitk:5965 #, tcl-format msgid "Reset %s branch to here" -msgstr "Zweig »%s« hierher zurücksetzen" +msgstr "Zweig »%s« hierher zurücksetzen" #: gitk:5996 msgid "Top" @@ -450,7 +450,7 @@ msgstr "" #: gitk:6143 #, tcl-format msgid "Tag \"%s\" already exists" -msgstr "Markierung »%s« existiert bereits." +msgstr "Markierung »%s« existiert bereits." #: gitk:6153 msgid "Error creating tag:" @@ -483,15 +483,15 @@ msgstr "" #: gitk:6320 msgid "Cherry-picking" -msgstr "Version pflücken" +msgstr "Version pflücken" #: gitk:6332 msgid "No changes committed" -msgstr "Keine Änderungen eingetragen" +msgstr "Keine Änderungen eingetragen" #: gitk:6355 msgid "Confirm reset" -msgstr "Zurücksetzen bestätigen" +msgstr "Zurücksetzen bestätigen" #: gitk:6357 #, tcl-format @@ -500,17 +500,17 @@ msgstr "" #: gitk:6361 msgid "Reset type:" -msgstr "Art des Zurücksetzens:" +msgstr "Art des Zurücksetzens:" #: gitk:6365 msgid "Soft: Leave working tree and index untouched" -msgstr "Weich: Arbeitskopie und Bereitstellung unverändert" +msgstr "Weich: Arbeitskopie und Bereitstellung unverändert" #: gitk:6368 msgid "Mixed: Leave working tree untouched, reset index" msgstr "" -"Gemischt: Arbeitskopie unverändert,\n" -"Bereitstellung zurückgesetzt" +"Gemischt: Arbeitskopie unverändert,\n" +"Bereitstellung zurückgesetzt" #: gitk:6371 msgid "" @@ -518,11 +518,11 @@ msgid "" "(discard ALL local changes)" msgstr "" "Hart: Arbeitskopie und Bereitstellung\n" -"(Alle lokalen Änderungen werden gelöscht)" +"(Alle lokalen Änderungen werden gelöscht)" #: gitk:6387 msgid "Resetting" -msgstr "Zurücksetzen" +msgstr "Zurücksetzen" #: gitk:6444 msgid "Checking out" @@ -637,7 +637,7 @@ msgstr "" #: gitk:8023 msgid "Select bg" -msgstr "Hintergrundfarbe Auswählen" +msgstr "Hintergrundfarbe Auswählen" #: gitk:8027 msgid "Fonts: press to choose" From f18b1c55e5b7478524c15685cd643555fc919f3f Mon Sep 17 00:00:00 2001 From: "J. Bruce Fields" Date: Fri, 21 Dec 2007 19:57:16 -0500 Subject: [PATCH 19/93] Documentation: fix remote..skipDefaultUpdate description Fix the subcommand name. Signed-off-by: J. Bruce Fields --- Documentation/config.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/config.txt b/Documentation/config.txt index 83bc33c421..6f2343fbc0 100644 --- a/Documentation/config.txt +++ b/Documentation/config.txt @@ -658,7 +658,7 @@ remote..push:: remote..skipDefaultUpdate:: If true, this remote will be skipped by default when updating - using the remote subcommand of gitlink:git-remote[1]. + using the update subcommand of gitlink:git-remote[1]. remote..receivepack:: The default program to execute on the remote side when pushing. See From 57283291b55cdc4ab726231073450d185beb361a Mon Sep 17 00:00:00 2001 From: Gustaf Hendeby Date: Mon, 31 Dec 2007 14:31:35 +0100 Subject: [PATCH 20/93] Documentation/user-manual.txt: fix typo Signed-off-by: Gustaf Hendeby Signed-off-by: J. Bruce Fields --- Documentation/user-manual.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/user-manual.txt b/Documentation/user-manual.txt index 159de30e19..bee0d61ab7 100644 --- a/Documentation/user-manual.txt +++ b/Documentation/user-manual.txt @@ -74,7 +74,7 @@ version is called a <>. Those snapshots aren't necessarily all arranged in a single line from oldest to newest; instead, work may simultaneously proceed along -parallel lines of development, called >, which may +parallel lines of development, called <>, which may merge and diverge. A single git repository can track development on multiple branches. It From 02e5ba4ae63729c28704280f1b8cfcb205c06960 Mon Sep 17 00:00:00 2001 From: Jeff King Date: Tue, 1 Jan 2008 01:17:34 -0500 Subject: [PATCH 21/93] config: handle lack of newline at end of file better The config parsing routines use the static global 'config_file' to store the FILE* pointing to the current config file being parsed. The function get_next_char() automatically converts an EOF on this file to a newline for the convenience of its callers, and it sets config_file to NULL to indicate that EOF was reached. This throws away useful information, though, since some routines want to call ftell on 'config_file' to find out exactly _where_ the routine ended. In the case of a key ending at EOF boundary, we ended up segfaulting in some cases (changing that key or adding another key in its section), or failing to provide the necessary newline (adding a new section). This patch adds a new flag to indicate EOF and uses that instead of setting config_file to NULL. It also makes sure to add newlines where necessary for truncated input. All three included tests fail without the patch. Signed-off-by: Junio C Hamano --- config.c | 14 +++++++++----- t/t1303-wacky-config.sh | 37 +++++++++++++++++++++++++++++++++++++ 2 files changed, 46 insertions(+), 5 deletions(-) create mode 100755 t/t1303-wacky-config.sh diff --git a/config.c b/config.c index 80db92990a..857deb6c85 100644 --- a/config.c +++ b/config.c @@ -13,6 +13,7 @@ static FILE *config_file; static const char *config_file_name; static int config_linenr; +static int config_file_eof; static int zlib_compression_seen; static int get_next_char(void) @@ -34,7 +35,7 @@ static int get_next_char(void) if (c == '\n') config_linenr++; if (c == EOF) { - config_file = NULL; + config_file_eof = 1; c = '\n'; } } @@ -118,7 +119,7 @@ static int get_value(config_fn_t fn, char *name, unsigned int len) /* Get the full name */ for (;;) { c = get_next_char(); - if (c == EOF) + if (config_file_eof) break; if (!iskeychar(c)) break; @@ -182,7 +183,7 @@ static int get_base_var(char *name) for (;;) { int c = get_next_char(); - if (c == EOF) + if (config_file_eof) return -1; if (c == ']') return baselen; @@ -205,8 +206,7 @@ static int git_parse_file(config_fn_t fn) for (;;) { int c = get_next_char(); if (c == '\n') { - /* EOF? */ - if (!config_file) + if (config_file_eof) return 0; comment = 0; continue; @@ -469,6 +469,7 @@ int git_config_from_file(config_fn_t fn, const char *filename) config_file = f; config_file_name = filename; config_linenr = 1; + config_file_eof = 0; ret = git_parse_file(fn); fclose(f); config_file_name = NULL; @@ -918,6 +919,9 @@ int git_config_set_multivar(const char* key, const char* value, contents, contents_sz, store.offset[i]-2, &new_line); + if (copy_end > 0 && contents[copy_end-1] != '\n') + new_line = 1; + /* write the first part of the config */ if (copy_end > copy_begin) { if (write_in_full(fd, contents + copy_begin, diff --git a/t/t1303-wacky-config.sh b/t/t1303-wacky-config.sh new file mode 100755 index 0000000000..99985dcd79 --- /dev/null +++ b/t/t1303-wacky-config.sh @@ -0,0 +1,37 @@ +#!/bin/sh + +test_description='Test wacky input to git config' +. ./test-lib.sh + +setup() { + (printf "[section]\n" && + printf " key = foo") >.git/config +} + +check() { + echo "$2" >expected + git config --get "$1" >actual + git diff actual expected +} + +test_expect_success 'modify same key' ' + setup && + git config section.key bar && + check section.key bar +' + +test_expect_success 'add key in same section' ' + setup && + git config section.other bar && + check section.key foo && + check section.other bar +' + +test_expect_success 'add key in different section' ' + setup && + git config section2.key bar && + check section.key foo && + check section2.key bar +' + +test_done From 49b9362fd35d45dc94ea15006c4bb88671b8da7d Mon Sep 17 00:00:00 2001 From: Jeff King Date: Mon, 31 Dec 2007 02:13:52 -0500 Subject: [PATCH 22/93] git-reset: refuse to do hard reset in a bare repository It makes no sense since there is no working tree. A soft reset should be fine, though. Signed-off-by: Jeff King Signed-off-by: Junio C Hamano --- builtin-reset.c | 3 +++ t/t7103-reset-bare.sh | 28 ++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+) create mode 100755 t/t7103-reset-bare.sh diff --git a/builtin-reset.c b/builtin-reset.c index 713c2d5346..10dba60c39 100644 --- a/builtin-reset.c +++ b/builtin-reset.c @@ -244,6 +244,9 @@ int cmd_reset(int argc, const char **argv, const char *prefix) if (reset_type == NONE) reset_type = MIXED; /* by default */ + if (reset_type == HARD && is_bare_repository()) + die("hard reset makes no sense in a bare repository"); + /* Soft reset does not touch the index file nor the working tree * at all, but requires them in a good order. Other resets reset * the index file to the tree object we are switching to. */ diff --git a/t/t7103-reset-bare.sh b/t/t7103-reset-bare.sh new file mode 100755 index 0000000000..b25a77f910 --- /dev/null +++ b/t/t7103-reset-bare.sh @@ -0,0 +1,28 @@ +#!/bin/sh + +test_description='git-reset in a bare repository' +. ./test-lib.sh + +test_expect_success 'setup non-bare' ' + echo one >file && + git add file && + git commit -m one && + echo two >file && + git commit -a -m two +' + +test_expect_success 'setup bare' ' + git clone --bare . bare.git && + cd bare.git +' + +test_expect_success 'hard reset is not allowed' ' + ! git reset --hard HEAD^ +' + +test_expect_success 'soft reset is allowed' ' + git reset --soft HEAD^ && + test "`git show --pretty=format:%s | head -n 1`" = "one" +' + +test_done From 5f7b202a7fa8ffbf076c456106750b2bb7732ba4 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Tue, 1 Jan 2008 22:33:20 -0800 Subject: [PATCH 23/93] lock_any_ref_for_update(): reject wildcard return from check_ref_format Recent check_ref_format() returns -3 as well as -1 (general error) and -2 (less than two levels). The caller was explicitly checking for -1, to allow "HEAD" but still needed to disallow bogus refs. This introduces symbolic constants for the return values from check_ref_format() to make them read better and more meaningful. Normal ref creation codepath can still treat non-zero return values as errors. Signed-off-by: Junio C Hamano --- refs.c | 27 ++++++++++++++++++--------- refs.h | 5 ++++- 2 files changed, 22 insertions(+), 10 deletions(-) diff --git a/refs.c b/refs.c index 759924d0c9..7484a46d68 100644 --- a/refs.c +++ b/refs.c @@ -613,32 +613,37 @@ int check_ref_format(const char *ref) while ((ch = *cp++) == '/') ; /* tolerate duplicated slashes */ if (!ch) - return -1; /* should not end with slashes */ + /* should not end with slashes */ + return CHECK_REF_FORMAT_ERROR; /* we are at the beginning of the path component */ if (ch == '.') - return -1; + return CHECK_REF_FORMAT_ERROR; bad_type = bad_ref_char(ch); if (bad_type) { - return (bad_type == 2 && !*cp) ? -3 : -1; + return (bad_type == 2 && !*cp) + ? CHECK_REF_FORMAT_WILDCARD + : CHECK_REF_FORMAT_ERROR; } /* scan the rest of the path component */ while ((ch = *cp++) != 0) { bad_type = bad_ref_char(ch); if (bad_type) { - return (bad_type == 2 && !*cp) ? -3 : -1; + return (bad_type == 2 && !*cp) + ? CHECK_REF_FORMAT_WILDCARD + : CHECK_REF_FORMAT_ERROR; } if (ch == '/') break; if (ch == '.' && *cp == '.') - return -1; + return CHECK_REF_FORMAT_ERROR; } level++; if (!ch) { if (level < 2) - return -2; /* at least of form "heads/blah" */ - return 0; + return CHECK_REF_FORMAT_ONELEVEL; + return CHECK_REF_FORMAT_OK; } } } @@ -816,9 +821,13 @@ struct ref_lock *lock_ref_sha1(const char *ref, const unsigned char *old_sha1) struct ref_lock *lock_any_ref_for_update(const char *ref, const unsigned char *old_sha1, int flags) { - if (check_ref_format(ref) == -1) + switch (check_ref_format(ref)) { + case CHECK_REF_FORMAT_ERROR: + case CHECK_REF_FORMAT_WILDCARD: return NULL; - return lock_ref_sha1_basic(ref, old_sha1, flags, NULL); + default: + return lock_ref_sha1_basic(ref, old_sha1, flags, NULL); + } } static struct lock_file packlock; diff --git a/refs.h b/refs.h index 9dc8aa01d1..9cd16f8295 100644 --- a/refs.h +++ b/refs.h @@ -52,7 +52,10 @@ int for_each_reflog_ent(const char *ref, each_reflog_ent_fn fn, void *cb_data); */ extern int for_each_reflog(each_ref_fn, void *); -/** Returns 0 if target has the right format for a ref. **/ +#define CHECK_REF_FORMAT_OK 0 +#define CHECK_REF_FORMAT_ERROR (-1) +#define CHECK_REF_FORMAT_ONELEVEL (-2) +#define CHECK_REF_FORMAT_WILDCARD (-3) extern int check_ref_format(const char *target); /** rename ref, return 0 on success **/ From 99a6a97b1bf866d7050e8afb137b4b29507f0caa Mon Sep 17 00:00:00 2001 From: Johannes Schindelin Date: Sat, 29 Dec 2007 20:22:14 +0100 Subject: [PATCH 24/93] Optimize prefixcmp() Certain codepaths (notably "git log --pretty=format...") use prefixcmp() extensively, with very short prefixes. In those cases, calling strlen() is a wasteful operation, so avoid it. Initial patch by Marco Costalba. Signed-off-by: Johannes Schindelin Signed-off-by: Junio C Hamano --- git-compat-util.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/git-compat-util.h b/git-compat-util.h index 79eb10eacb..7059cbdab7 100644 --- a/git-compat-util.h +++ b/git-compat-util.h @@ -398,7 +398,11 @@ static inline int sane_case(int x, int high) static inline int prefixcmp(const char *str, const char *prefix) { - return strncmp(str, prefix, strlen(prefix)); + for (; ; str++, prefix++) + if (!*prefix) + return 0; + else if (*str != *prefix) + return (unsigned char)*prefix - (unsigned char)*str; } static inline int strtoul_ui(char const *s, int base, unsigned int *result) From eab827072d1e197eb6ccb6f75e7fe86143735f1e Mon Sep 17 00:00:00 2001 From: Martin Koegler Date: Wed, 2 Jan 2008 08:39:21 +0100 Subject: [PATCH 25/93] receive-pack: check object type of sha1 before using them as commits Signed-off-by: Martin Koegler Signed-off-by: Junio C Hamano --- receive-pack.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/receive-pack.c b/receive-pack.c index fba4cf8235..d0a563df64 100644 --- a/receive-pack.c +++ b/receive-pack.c @@ -178,11 +178,21 @@ static const char *update(struct command *cmd) if (deny_non_fast_forwards && !is_null_sha1(new_sha1) && !is_null_sha1(old_sha1) && !prefixcmp(name, "refs/heads/")) { + struct object *old_object, *new_object; struct commit *old_commit, *new_commit; struct commit_list *bases, *ent; - old_commit = (struct commit *)parse_object(old_sha1); - new_commit = (struct commit *)parse_object(new_sha1); + old_object = parse_object(old_sha1); + new_object = parse_object(new_sha1); + + if (!old_object || !new_object || + old_object->type != OBJ_COMMIT || + new_object->type != OBJ_COMMIT) { + error("bad sha1 objects for %s", name); + return "bad ref"; + } + old_commit = (struct commit *)old_object; + new_commit = (struct commit *)new_object; bases = get_merge_bases(old_commit, new_commit, 1); for (ent = bases; ent; ent = ent->next) if (!hashcmp(old_sha1, ent->item->object.sha1)) From 7dfa16b9dc89c14c8e351cb70d775a21e87d5c23 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Wed, 2 Jan 2008 10:09:49 -0800 Subject: [PATCH 26/93] git-svn: allow dcommit --no-rebase to commit multiple, dependent changes Signed-off-by: Eric Wong Signed-off-by: Junio C Hamano --- git-svn.perl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/git-svn.perl b/git-svn.perl index c51f1e7391..9b1113a336 100755 --- a/git-svn.perl +++ b/git-svn.perl @@ -418,7 +418,7 @@ sub cmd_dcommit { warn "Attempting to commit more than one change while ", "--no-rebase is enabled.\n", "If these changes depend on each other, re-running ", - "without --no-rebase will be required." + "without --no-rebase may be required." } while (1) { my $d = shift @$linear_refs or last; @@ -453,6 +453,7 @@ sub cmd_dcommit { $parents->{$d}; } $_fetch_all ? $gs->fetch_all : $gs->fetch; + $last_rev = $cmt_rev; next if $_no_rebase; # we always want to rebase against the current HEAD, @@ -512,7 +513,6 @@ sub cmd_dcommit { $parents = \%p; $linear_refs = \@l; } - $last_rev = $cmt_rev; } } unlink $gs->{index}; From 321b1842dceb94bbaa00b9f75c7c2fe6bf6fad1c Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Wed, 2 Jan 2008 10:10:03 -0800 Subject: [PATCH 27/93] git-svn: unlink index files that were globbed, too commit 3157dd9e89a71e80673d0bc21b5c0630f3b1fe68 (git-svn: unlink internal index files after operations) introduced unlinking index files after fetching. However, this missed indices for refs that were created by globbing branches and tags. This will track all refs we ever touch during a fetch and unlink them at exit time. Signed-off-by: Eric Wong Signed-off-by: Junio C Hamano --- git-svn.perl | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/git-svn.perl b/git-svn.perl index 9b1113a336..2c97b05885 100755 --- a/git-svn.perl +++ b/git-svn.perl @@ -1283,8 +1283,11 @@ BEGIN { } } -my %LOCKFILES; -END { unlink keys %LOCKFILES if %LOCKFILES } +my (%LOCKFILES, %INDEX_FILES); +END { + unlink keys %LOCKFILES if %LOCKFILES; + unlink keys %INDEX_FILES if %INDEX_FILES; +} sub resolve_local_globs { my ($url, $fetch, $glob_spec) = @_; @@ -1376,7 +1379,6 @@ sub fetch_all { ($base, $head) = parse_revision_argument($base, $head); $ra->gs_fetch_loop_common($base, $head, \@gs, \@globs); - unlink $_->{index} foreach @gs; } sub read_all_remotes { @@ -3945,6 +3947,7 @@ sub gs_fetch_loop_common { if ($log_entry) { $gs->do_git_commit($log_entry); } + $INDEX_FILES{$gs->{index}} = 1; } foreach my $g (@$globs) { my $k = "svn-remote.$g->{remote}." . From 257f3020f69f3222cdefc1d84b148fb35b2c4f5b Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Wed, 2 Jan 2008 11:14:40 -0800 Subject: [PATCH 28/93] Update callers of check_ref_format() This updates send-pack and fast-import to use symbolic constants for checking the return values from check_ref_format(), and also futureproof the logic in lock_any_ref_for_update() to explicitly name the case that is usually considered an error but is Ok for this particular use. Signed-off-by: Junio C Hamano --- builtin-send-pack.c | 10 ++++++---- fast-import.c | 5 +++-- refs.c | 6 +++--- 3 files changed, 12 insertions(+), 9 deletions(-) diff --git a/builtin-send-pack.c b/builtin-send-pack.c index 25ae1fe860..8afb1d0bca 100644 --- a/builtin-send-pack.c +++ b/builtin-send-pack.c @@ -541,10 +541,12 @@ static void verify_remote_names(int nr_heads, const char **heads) remote = remote ? (remote + 1) : heads[i]; switch (check_ref_format(remote)) { case 0: /* ok */ - case -2: /* ok but a single level -- that is fine for - * a match pattern. - */ - case -3: /* ok but ends with a pattern-match character */ + case CHECK_REF_FORMAT_ONELEVEL: + /* ok but a single level -- that is fine for + * a match pattern. + */ + case CHECK_REF_FORMAT_WILDCARD: + /* ok but ends with a pattern-match character */ continue; } die("remote part of refspec is not a valid name in %s", diff --git a/fast-import.c b/fast-import.c index 4646c056f3..74597c901c 100644 --- a/fast-import.c +++ b/fast-import.c @@ -642,8 +642,9 @@ static struct branch *new_branch(const char *name) if (b) die("Invalid attempt to create duplicate branch: %s", name); switch (check_ref_format(name)) { - case 0: break; /* its valid */ - case -2: break; /* valid, but too few '/', allow anyway */ + case 0: break; /* its valid */ + case CHECK_REF_FORMAT_ONELEVEL: + break; /* valid, but too few '/', allow anyway */ default: die("Branch name doesn't conform to GIT standards: %s", name); } diff --git a/refs.c b/refs.c index 7484a46d68..58f6d17397 100644 --- a/refs.c +++ b/refs.c @@ -822,10 +822,10 @@ struct ref_lock *lock_ref_sha1(const char *ref, const unsigned char *old_sha1) struct ref_lock *lock_any_ref_for_update(const char *ref, const unsigned char *old_sha1, int flags) { switch (check_ref_format(ref)) { - case CHECK_REF_FORMAT_ERROR: - case CHECK_REF_FORMAT_WILDCARD: - return NULL; default: + return NULL; + case 0: + case CHECK_REF_FORMAT_ONELEVEL: return lock_ref_sha1_basic(ref, old_sha1, flags, NULL); } } From 698a68be7b0df6dd8d0880e0e2167cad8688a6ad Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Thu, 3 Jan 2008 01:23:12 -0800 Subject: [PATCH 29/93] Uninline prefixcmp() Now the routine is an open-coded loop that avoids an extra strlen() in the previous implementation, it got a bit too big to be inlined. Uninlining it makes code footprint smaller but the result still retains the avoidance of strlen() cost. Signed-off-by: Junio C Hamano --- git-compat-util.h | 11 ++--------- strbuf.c | 9 +++++++++ 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/git-compat-util.h b/git-compat-util.h index 7059cbdab7..b6ef5442b7 100644 --- a/git-compat-util.h +++ b/git-compat-util.h @@ -122,6 +122,8 @@ extern void set_die_routine(void (*routine)(const char *err, va_list params) NOR extern void set_error_routine(void (*routine)(const char *err, va_list params)); extern void set_warn_routine(void (*routine)(const char *warn, va_list params)); +extern int prefixcmp(const char *str, const char *prefix); + #ifdef NO_MMAP #ifndef PROT_READ @@ -396,15 +398,6 @@ static inline int sane_case(int x, int high) return x; } -static inline int prefixcmp(const char *str, const char *prefix) -{ - for (; ; str++, prefix++) - if (!*prefix) - return 0; - else if (*str != *prefix) - return (unsigned char)*prefix - (unsigned char)*str; -} - static inline int strtoul_ui(char const *s, int base, unsigned int *result) { unsigned long ul; diff --git a/strbuf.c b/strbuf.c index b9b194b320..5efcfc8860 100644 --- a/strbuf.c +++ b/strbuf.c @@ -1,5 +1,14 @@ #include "cache.h" +int prefixcmp(const char *str, const char *prefix) +{ + for (; ; str++, prefix++) + if (!*prefix) + return 0; + else if (*str != *prefix) + return (unsigned char)*prefix - (unsigned char)*str; +} + /* * Used as the default ->buf value, so that people can always assume * buf is non NULL and ->buf is NUL terminated even for a freshly From 790296fd8863d649054096191d33bacbbf5c2115 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Thu, 3 Jan 2008 15:18:07 +0100 Subject: [PATCH 30/93] Fix grammar nits in documentation and in code comments. Signed-off-by: Jim Meyering Signed-off-by: Junio C Hamano --- Documentation/i18n.txt | 2 +- builtin-blame.c | 2 +- ident.c | 2 +- merge-recursive.c | 2 +- setup.c | 2 +- sha1_file.c | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Documentation/i18n.txt b/Documentation/i18n.txt index b95f99be6c..1e188e6e74 100644 --- a/Documentation/i18n.txt +++ b/Documentation/i18n.txt @@ -22,7 +22,7 @@ does not forbid it. However, there are a few things to keep in mind. . `git-commit-tree` (hence, `git-commit` which uses it) issues - an warning if the commit log message given to it does not look + a warning if the commit log message given to it does not look like a valid UTF-8 string, unless you explicitly say your project uses a legacy encoding. The way to say this is to have i18n.commitencoding in `.git/config` file, like this: diff --git a/builtin-blame.c b/builtin-blame.c index d98caaf217..9b4c02e87f 100644 --- a/builtin-blame.c +++ b/builtin-blame.c @@ -606,7 +606,7 @@ static void add_blame_entry(struct scoreboard *sb, struct blame_entry *e) /* * src typically is on-stack; we want to copy the information in it to - * an malloced blame_entry that is already on the linked list of the + * a malloced blame_entry that is already on the linked list of the * scoreboard. The origin of dst loses a refcnt while the origin of src * gains one. */ diff --git a/ident.c b/ident.c index 892d77ac93..b839dcf5f0 100644 --- a/ident.c +++ b/ident.c @@ -152,7 +152,7 @@ static int copy(char *buf, size_t size, int offset, const char *src) /* * Copy the rest to the buffer, but avoid the special * characters '\n' '<' and '>' that act as delimiters on - * a identification line + * an identification line */ for (i = 0; i < len; i++) { c = *src++; diff --git a/merge-recursive.c b/merge-recursive.c index 33ccc40ecd..b34177d20f 100644 --- a/merge-recursive.c +++ b/merge-recursive.c @@ -289,7 +289,7 @@ static int get_files_dirs(struct tree *tree) } /* - * Returns a index_entry instance which doesn't have to correspond to + * Returns an index_entry instance which doesn't have to correspond to * a real cache entry in Git's index. */ static struct stage_data *insert_stage_data(const char *path, diff --git a/setup.c b/setup.c index b59dbe7f51..adede16a4d 100644 --- a/setup.c +++ b/setup.c @@ -140,7 +140,7 @@ const char **get_pathspec(const char *prefix, const char **pathspec) * Test if it looks like we're at a git directory. * We want to see: * - * - either a objects/ directory _or_ the proper + * - either an objects/ directory _or_ the proper * GIT_OBJECT_DIRECTORY environment variable * - a refs/ directory * - either a HEAD symlink or a HEAD file that is formatted as diff --git a/sha1_file.c b/sha1_file.c index b0c24356ae..6583797ce5 100644 --- a/sha1_file.c +++ b/sha1_file.c @@ -148,7 +148,7 @@ static void fill_sha1_path(char *pathbuf, const unsigned char *sha1) /* * NOTE! This returns a statically allocated buffer, so you have to be - * careful about using it. Do a "xstrdup()" if you need to save the + * careful about using it. Do an "xstrdup()" if you need to save the * filename. * * Also note that this returns the location for creating. Reading From 95bf4bd4f7280312571e642339f3571310d0d660 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Thu, 3 Jan 2008 19:04:37 -0800 Subject: [PATCH 31/93] git-clean: make "Would remove ..." path relative to cwd again The rewrite changed the output to use the path relative to the top of the work tree without a good reason. This fixes it. Signed-off-by: Junio C Hamano --- builtin-clean.c | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/builtin-clean.c b/builtin-clean.c index ae30d4e76c..6cad8eaf25 100644 --- a/builtin-clean.c +++ b/builtin-clean.c @@ -34,6 +34,7 @@ int cmd_clean(int argc, const char **argv, const char *prefix) struct dir_struct dir; const char *path, *base; static const char **pathspec; + int prefix_offset = 0; char *seen = NULL; struct option options[] = { OPT__QUIET(&quiet), @@ -71,6 +72,8 @@ int cmd_clean(int argc, const char **argv, const char *prefix) if (!ignored) setup_standard_excludes(&dir); + if (prefix) + prefix_offset = strlen(prefix); pathspec = get_pathspec(prefix, argv); read_cache(); @@ -132,26 +135,32 @@ int cmd_clean(int argc, const char **argv, const char *prefix) if (S_ISDIR(st.st_mode)) { strbuf_addstr(&directory, ent->name); if (show_only && (remove_directories || matches)) { - printf("Would remove %s\n", directory.buf); + printf("Would remove %s\n", + directory.buf + prefix_offset); } else if (quiet && (remove_directories || matches)) { remove_dir_recursively(&directory, 0); } else if (remove_directories || matches) { - printf("Removing %s\n", directory.buf); + printf("Removing %s\n", + directory.buf + prefix_offset); remove_dir_recursively(&directory, 0); } else if (show_only) { - printf("Would not remove %s\n", directory.buf); + printf("Would not remove %s\n", + directory.buf + prefix_offset); } else { - printf("Not removing %s\n", directory.buf); + printf("Not removing %s\n", + directory.buf + prefix_offset); } strbuf_reset(&directory); } else { if (pathspec && !matches) continue; if (show_only) { - printf("Would remove %s\n", ent->name); + printf("Would remove %s\n", + ent->name + prefix_offset); continue; } else if (!quiet) { - printf("Removing %s\n", ent->name); + printf("Removing %s\n", + ent->name + prefix_offset); } unlink(ent->name); } From 872c930dcb048c1a2b50e6ce881c521dcee15e23 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Fri, 4 Jan 2008 18:37:41 +0100 Subject: [PATCH 32/93] Don't access line[-1] for a zero-length "line" from fgets. A NUL byte at beginning of file, or just after a newline would provoke an invalid buf[-1] access in a few places. * builtin-grep.c (cmd_grep): Don't access buf[-1]. * builtin-pack-objects.c (get_object_list): Likewise. * builtin-rev-list.c (read_revisions_from_stdin): Likewise. * bundle.c (read_bundle_header): Likewise. * server-info.c (read_pack_info_file): Likewise. * transport.c (insert_packed_refs): Likewise. Signed-off-by: Jim Meyering Signed-off-by: Junio C Hamano --- builtin-grep.c | 2 +- builtin-pack-objects.c | 2 +- builtin-rev-list.c | 2 +- bundle.c | 2 +- server-info.c | 2 +- transport.c | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/builtin-grep.c b/builtin-grep.c index f1ff8dc556..0d6cc7361f 100644 --- a/builtin-grep.c +++ b/builtin-grep.c @@ -644,7 +644,7 @@ int cmd_grep(int argc, const char **argv, const char *prefix) die("'%s': %s", argv[1], strerror(errno)); while (fgets(buf, sizeof(buf), patterns)) { int len = strlen(buf); - if (buf[len-1] == '\n') + if (len && buf[len-1] == '\n') buf[len-1] = 0; /* ignore empty line like grep does */ if (!buf[0]) diff --git a/builtin-pack-objects.c b/builtin-pack-objects.c index e0ce114be7..a39cb82c9b 100644 --- a/builtin-pack-objects.c +++ b/builtin-pack-objects.c @@ -2013,7 +2013,7 @@ static void get_object_list(int ac, const char **av) while (fgets(line, sizeof(line), stdin) != NULL) { int len = strlen(line); - if (line[len - 1] == '\n') + if (len && line[len - 1] == '\n') line[--len] = 0; if (!len) break; diff --git a/builtin-rev-list.c b/builtin-rev-list.c index 1cb5f67119..de80158fd4 100644 --- a/builtin-rev-list.c +++ b/builtin-rev-list.c @@ -520,7 +520,7 @@ static void read_revisions_from_stdin(struct rev_info *revs) while (fgets(line, sizeof(line), stdin) != NULL) { int len = strlen(line); - if (line[len - 1] == '\n') + if (len && line[len - 1] == '\n') line[--len] = 0; if (!len) break; diff --git a/bundle.c b/bundle.c index 9b9b9166df..be204d8a22 100644 --- a/bundle.c +++ b/bundle.c @@ -48,7 +48,7 @@ int read_bundle_header(const char *path, struct bundle_header *header) : &header->references; char delim; - if (buffer[len - 1] == '\n') + if (len && buffer[len - 1] == '\n') buffer[len - 1] = '\0'; if (get_sha1_hex(buffer + offset, sha1)) { warning("unrecognized header: %s", buffer); diff --git a/server-info.c b/server-info.c index a051e49a9e..c1c073b2f0 100644 --- a/server-info.c +++ b/server-info.c @@ -101,7 +101,7 @@ static int read_pack_info_file(const char *infofile) while (fgets(line, sizeof(line), fp)) { int len = strlen(line); - if (line[len-1] == '\n') + if (len && line[len-1] == '\n') line[--len] = 0; if (!len) diff --git a/transport.c b/transport.c index 4e151a9e87..babaa21398 100644 --- a/transport.c +++ b/transport.c @@ -118,7 +118,7 @@ static void insert_packed_refs(const char *packed_refs, struct ref **list) if (hexval(buffer[0]) > 0xf) continue; len = strlen(buffer); - if (buffer[len - 1] == '\n') + if (len && buffer[len - 1] == '\n') buffer[--len] = '\0'; if (len < 41) continue; From 061d6b9a7bfcf88ff3895aa1be8424ae1647cbca Mon Sep 17 00:00:00 2001 From: Martin Koegler Date: Fri, 4 Jan 2008 20:37:17 +0100 Subject: [PATCH 33/93] receive-pack: reject invalid refnames Signed-off-by: Martin Koegler Signed-off-by: Junio C Hamano --- receive-pack.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/receive-pack.c b/receive-pack.c index d0a563df64..3267495832 100644 --- a/receive-pack.c +++ b/receive-pack.c @@ -165,7 +165,8 @@ static const char *update(struct command *cmd) unsigned char *new_sha1 = cmd->new_sha1; struct ref_lock *lock; - if (!prefixcmp(name, "refs/") && check_ref_format(name + 5)) { + /* only refs/... are allowed */ + if (prefixcmp(name, "refs/") || check_ref_format(name + 5)) { error("refusing to create funny ref '%s' remotely", name); return "funny refname"; } From 9a1805a8726ee41f25be2e0f2d5f38f1150d38e4 Mon Sep 17 00:00:00 2001 From: Jeff King Date: Fri, 4 Jan 2008 03:59:34 -0500 Subject: [PATCH 34/93] add a "basic" diff config callback The diff porcelain uses git_diff_ui_config to set porcelain-ish config options, like automatically turning on color. The plumbing specifically avoids calling this function, since it doesn't want things like automatic color or rename detection. However, some diff options should be set for both plumbing and porcelain. For example, one can still turn on color in git-diff-files using the --color command line option. This means we want the color config from color.diff.* (so that once color is on, we use the user's preferred scheme), but _not_ the color.diff variable. We split the diff config into "ui" and "basic", where "basic" is suitable for use by plumbing (so _most_ things affecting the output should still go into the "ui" part). Signed-off-by: Jeff King Signed-off-by: Junio C Hamano --- builtin-diff-files.c | 2 +- builtin-diff-index.c | 2 +- builtin-diff-tree.c | 2 +- diff.c | 6 ++++++ diff.h | 1 + 5 files changed, 10 insertions(+), 3 deletions(-) diff --git a/builtin-diff-files.c b/builtin-diff-files.c index 9c04111656..4abe3c28fb 100644 --- a/builtin-diff-files.c +++ b/builtin-diff-files.c @@ -21,7 +21,7 @@ int cmd_diff_files(int argc, const char **argv, const char *prefix) prefix = setup_git_directory_gently(&nongit); init_revisions(&rev, prefix); - git_config(git_default_config); /* no "diff" UI options */ + git_config(git_diff_basic_config); /* no "diff" UI options */ rev.abbrev = 0; if (!setup_diff_no_index(&rev, argc, argv, nongit, prefix)) diff --git a/builtin-diff-index.c b/builtin-diff-index.c index 0f2390a20a..2b955deb91 100644 --- a/builtin-diff-index.c +++ b/builtin-diff-index.c @@ -17,7 +17,7 @@ int cmd_diff_index(int argc, const char **argv, const char *prefix) int result; init_revisions(&rev, prefix); - git_config(git_default_config); /* no "diff" UI options */ + git_config(git_diff_basic_config); /* no "diff" UI options */ rev.abbrev = 0; argc = setup_revisions(argc, argv, &rev, NULL); diff --git a/builtin-diff-tree.c b/builtin-diff-tree.c index ebc50efbd2..832797ff3b 100644 --- a/builtin-diff-tree.c +++ b/builtin-diff-tree.c @@ -68,7 +68,7 @@ int cmd_diff_tree(int argc, const char **argv, const char *prefix) int read_stdin = 0; init_revisions(opt, prefix); - git_config(git_default_config); /* no "diff" UI options */ + git_config(git_diff_basic_config); /* no "diff" UI options */ nr_sha1 = 0; opt->abbrev = 0; opt->diff = 1; diff --git a/diff.c b/diff.c index 5bdc111378..44aa477c41 100644 --- a/diff.c +++ b/diff.c @@ -178,6 +178,12 @@ int git_diff_ui_config(const char *var, const char *value) return parse_funcname_pattern(var, ep, value); } } + + return git_diff_basic_config(var, value); +} + +int git_diff_basic_config(const char *var, const char *value) +{ if (!prefixcmp(var, "diff.color.") || !prefixcmp(var, "color.diff.")) { int slot = parse_diff_color_slot(var, 11); color_parse(value, var, diff_colors[slot]); diff --git a/diff.h b/diff.h index beccf85962..073d5cbf1b 100644 --- a/diff.h +++ b/diff.h @@ -172,6 +172,7 @@ extern void diff_unmerge(struct diff_options *, #define DIFF_SETUP_USE_CACHE 2 #define DIFF_SETUP_USE_SIZE_CACHE 4 +extern int git_diff_basic_config(const char *var, const char *value); extern int git_diff_ui_config(const char *var, const char *value); extern void diff_setup(struct diff_options *); extern int diff_opt_parse(struct diff_options *, const char **, int); From e467193ff3f57171c5c3232b4ba3595970efbfb5 Mon Sep 17 00:00:00 2001 From: Jeff King Date: Fri, 4 Jan 2008 04:16:14 -0500 Subject: [PATCH 35/93] diff: load funcname patterns in "basic" config The funcname patterns influence the "comment" on @@ lines of the diff. They are safe to use with plumbing since they don't fundamentally change the meaning of the diff in any way. Since all diff users call either diff_ui_config or diff_basic_config, we can get rid of the lazy reading of the config. Signed-off-by: Jeff King Signed-off-by: Junio C Hamano --- diff.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/diff.c b/diff.c index 44aa477c41..4a908b28af 100644 --- a/diff.c +++ b/diff.c @@ -174,8 +174,6 @@ int git_diff_ui_config(const char *var, const char *value) if (ep != var + 4) { if (!strcmp(ep, ".command")) return parse_lldiff_command(var, ep, value); - if (!strcmp(ep, ".funcname")) - return parse_funcname_pattern(var, ep, value); } } @@ -190,6 +188,14 @@ int git_diff_basic_config(const char *var, const char *value) return 0; } + if (!prefixcmp(var, "diff.")) { + const char *ep = strrchr(var, '.'); + if (ep != var + 4) { + if (!strcmp(ep, ".funcname")) + return parse_funcname_pattern(var, ep, value); + } + } + return git_default_config(var, value); } @@ -1160,7 +1166,6 @@ static const char *funcname_pattern(const char *ident) { struct funcname_pattern *pp; - read_config_if_needed(); for (pp = funcname_pattern_list; pp; pp = pp->next) if (!strcmp(ident, pp->name)) return pp->pattern; From cae6c25a7fdd7a316318c2efdc48e63cce36a68c Mon Sep 17 00:00:00 2001 From: Jeff King Date: Fri, 4 Jan 2008 04:45:31 -0500 Subject: [PATCH 36/93] diff: remove lazy config loading There is no point to this. Either: 1. The program has already loaded git_diff_ui_config, in which case this is a noop. 2. The program didn't, which means it is plumbing that does not _want_ git_diff_ui_config to be loaded. Signed-off-by: Jeff King Signed-off-by: Junio C Hamano --- diff.c | 9 --------- 1 file changed, 9 deletions(-) diff --git a/diff.c b/diff.c index 4a908b28af..2c78d74a42 100644 --- a/diff.c +++ b/diff.c @@ -59,14 +59,6 @@ static struct ll_diff_driver { char *cmd; } *user_diff, **user_diff_tail; -static void read_config_if_needed(void) -{ - if (!user_diff_tail) { - user_diff_tail = &user_diff; - git_config(git_diff_ui_config); - } -} - /* * Currently there is only "diff..command" variable; * because there are "diff.color." variables, we are parsing @@ -1822,7 +1814,6 @@ static const char *external_diff_attr(const char *name) !ATTR_UNSET(value)) { struct ll_diff_driver *drv; - read_config_if_needed(); for (drv = user_diff; drv; drv = drv->next) if (!strcmp(drv->name, value)) return drv->cmd; From cf9d58e4f388dc173b86143fbfe0eac114e3ed2f Mon Sep 17 00:00:00 2001 From: Marco Costalba Date: Fri, 4 Jan 2008 10:53:32 +0100 Subject: [PATCH 37/93] Document git-reset defaults to HEAD if no commit is given Signed-off by: Marco Costalba Signed-off-by: Junio C Hamano --- Documentation/git-reset.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/git-reset.txt b/Documentation/git-reset.txt index 050e4eadbb..69722d14d3 100644 --- a/Documentation/git-reset.txt +++ b/Documentation/git-reset.txt @@ -9,7 +9,7 @@ SYNOPSIS -------- [verse] 'git-reset' [--mixed | --soft | --hard] [-q] [] -'git-reset' [--mixed] [-q] [--] ... +'git-reset' [--mixed] [-q] [] [--] ... DESCRIPTION ----------- @@ -49,7 +49,7 @@ OPTIONS Be quiet, only report errors. :: - Commit to make the current HEAD. + Commit to make the current HEAD. If not given defaults to HEAD. Examples -------- From 7ee906694c28ab7281492d5114d2afabd964bd41 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Fri, 4 Jan 2008 22:22:55 -0800 Subject: [PATCH 38/93] t/t7600: avoid GNUism in grep Using \+ to mean "one or more" in grep without -E is a GNU extension outside POSIX. Avoid it. Signed-off-by: Junio C Hamano --- t/t7600-merge.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/t/t7600-merge.sh b/t/t7600-merge.sh index 6424c6e2c0..50c51c82fa 100755 --- a/t/t7600-merge.sh +++ b/t/t7600-merge.sh @@ -371,7 +371,7 @@ test_expect_success 'override config option -n' ' git merge --summary c2 >diffstat.txt && verify_merge file result.1-5 msg.1-5 && verify_parents $c1 $c2 && - if ! grep -e "^ file | \+2 +-$" diffstat.txt + if ! grep -e "^ file | *2 +-$" diffstat.txt then echo "[OOPS] diffstat was not generated" fi @@ -386,7 +386,7 @@ test_expect_success 'override config option --summary' ' git merge -n c2 >diffstat.txt && verify_merge file result.1-5 msg.1-5 && verify_parents $c1 $c2 && - if grep -e "^ file | \+2 +-$" diffstat.txt + if grep -e "^ file | *2 +-$" diffstat.txt then echo "[OOPS] diffstat was generated" false From 90ed6c0576156d356aa35ee79aaf85825f9566f6 Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Sat, 5 Jan 2008 05:06:48 +0100 Subject: [PATCH 39/93] t/t7001: avoid unnecessary ERE when using grep As pointed out by Junio, it's unnecessary to use "grep -E" and ".+" when we can just use "grep" and "..*". Signed-off-by: Miklos Vajna Signed-off-by: Junio C Hamano --- t/t7001-mv.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/t/t7001-mv.sh b/t/t7001-mv.sh index 8b43fb5a27..b730c900b1 100755 --- a/t/t7001-mv.sh +++ b/t/t7001-mv.sh @@ -22,7 +22,7 @@ test_expect_success \ test_expect_success \ 'checking the commit' \ 'git diff-tree -r -M --name-status HEAD^ HEAD | \ - grep -E "^R100.+path0/COPYING.+path1/COPYING"' + grep "^R100..*path0/COPYING..*path1/COPYING"' test_expect_success \ 'moving the file back into subdirectory' \ @@ -36,7 +36,7 @@ test_expect_success \ test_expect_success \ 'checking the commit' \ 'git diff-tree -r -M --name-status HEAD^ HEAD | \ - grep -E "^R100.+path1/COPYING.+path0/COPYING"' + grep "^R100..*path1/COPYING..*path0/COPYING"' test_expect_success \ 'adding another file' \ @@ -55,9 +55,9 @@ test_expect_success \ test_expect_success \ 'checking the commit' \ 'git diff-tree -r -M --name-status HEAD^ HEAD | \ - grep -E "^R100.+path0/COPYING.+path2/COPYING" && + grep "^R100..*path0/COPYING..*path2/COPYING" && git diff-tree -r -M --name-status HEAD^ HEAD | \ - grep -E "^R100.+path0/README.+path2/README"' + grep "^R100..*path0/README..*path2/README"' test_expect_success \ 'succeed when source is a prefix of destination' \ @@ -74,9 +74,9 @@ test_expect_success \ test_expect_success \ 'checking the commit' \ 'git diff-tree -r -M --name-status HEAD^ HEAD | \ - grep -E "^R100.+path2/COPYING.+path1/path2/COPYING" && + grep "^R100..*path2/COPYING..*path1/path2/COPYING" && git diff-tree -r -M --name-status HEAD^ HEAD | \ - grep -E "^R100.+path2/README.+path1/path2/README"' + grep "^R100..*path2/README..*path1/path2/README"' test_expect_failure \ 'do not move directory over existing directory' \ From 0feb4d1c99ef4188123ff38d702bcbdd483c3702 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Fri, 4 Jan 2008 22:28:13 -0800 Subject: [PATCH 40/93] t/t{3600,3800,5401}: do not use egrep when grep would do There is nothing _wrong_ with egrep per se, but this way we would have less dependency on external tools. Signed-off-by: Junio C Hamano --- t/t3600-rm.sh | 2 +- t/t3800-mktag.sh | 2 +- t/t5401-update-hooks.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/t/t3600-rm.sh b/t/t3600-rm.sh index 5c001aa489..b1ee622ef7 100755 --- a/t/t3600-rm.sh +++ b/t/t3600-rm.sh @@ -127,7 +127,7 @@ test_expect_success '"rm" command printed' ' git add test-file && git commit -m "add file for rm test" && git rm test-file > rm-output && - test `egrep "^rm " rm-output | wc -l` = 1 && + test `grep "^rm " rm-output | wc -l` = 1 && rm -f test-file rm-output && git commit -m "remove file from rm test" ' diff --git a/t/t3800-mktag.sh b/t/t3800-mktag.sh index 261f199a0c..e5f3073f88 100755 --- a/t/t3800-mktag.sh +++ b/t/t3800-mktag.sh @@ -15,7 +15,7 @@ check_verify_failure () { test_expect_success \ "$1" \ 'git-mktag message || - egrep -q -f expect.pat message' + grep -q -f expect.pat message' } ########################################################### diff --git a/t/t5401-update-hooks.sh b/t/t5401-update-hooks.sh index c5dd30d0a4..3eea3069eb 100755 --- a/t/t5401-update-hooks.sh +++ b/t/t5401-update-hooks.sh @@ -129,7 +129,7 @@ STDOUT post-update STDERR post-update EOF test_expect_success 'send-pack stderr contains hook messages' ' - egrep ^STD send.err >actual && + grep ^STD send.err >actual && git diff - actual Date: Fri, 4 Jan 2008 22:45:08 -0800 Subject: [PATCH 41/93] t/t3800: do not use a temporary file to hold expected result. It is a good practice to write program output to a temporary file during the test, as it would allow easier postmortem when the tested program does break. But there is no benefit in writing the expected output out to the temporary. This actually fixes a bug in check_verify_failure() routine. The intention of the test seems to make sure the "git mktag" command fails, and it spits out the expected error message. But if the command did not fail as expected, the shell function as originally written would not have detected the failure. Signed-off-by: Junio C Hamano --- t/t3800-mktag.sh | 89 ++++++++++++++---------------------------------- 1 file changed, 25 insertions(+), 64 deletions(-) diff --git a/t/t3800-mktag.sh b/t/t3800-mktag.sh index e5f3073f88..f2803206f1 100755 --- a/t/t3800-mktag.sh +++ b/t/t3800-mktag.sh @@ -12,10 +12,11 @@ test_description='git-mktag: tag object verify test' # given in the expect.pat file. check_verify_failure () { - test_expect_success \ - "$1" \ - 'git-mktag message || - grep -q -f expect.pat message' + expect="$2" + test_expect_success "$1" ' + ( ! git-mktag message ) && + grep -q "$expect" message + ' } ########################################################### @@ -33,11 +34,8 @@ cat >tag.sig <expect.pat <expect.pat <expect.pat <expect.pat <tag.sig printf "type tagsssssssssssssssssssssssssssssss" >>tag.sig -cat >expect.pat <expect.pat <expect.pat <expect.pat <expect.pat <expect.pat <expect.pat <expect.pat < Date: Fri, 4 Jan 2008 19:59:26 +0100 Subject: [PATCH 42/93] git-am: Run git gc only once and not for every patch. With "too many unreachable loose objects" git gc --auto will always trigger. This clutters the output of git am and thus git rebase. Signed-off-by: Michael Stefaniuc Signed-off-by: Junio C Hamano --- git-am.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/git-am.sh b/git-am.sh index 65c634f77a..5f0f241ad0 100755 --- a/git-am.sh +++ b/git-am.sh @@ -469,9 +469,9 @@ do "$GIT_DIR"/hooks/post-applypatch fi - git gc --auto - go_next done +git gc --auto + rm -fr "$dotest" From d6da3cdeb70e8819f68fe3c91d3457e53ab365d4 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Fri, 4 Jan 2008 23:13:47 -0800 Subject: [PATCH 43/93] Update draft release notes for 1.5.4 Signed-off-by: Junio C Hamano --- Documentation/RelNotes-1.5.4.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Documentation/RelNotes-1.5.4.txt b/Documentation/RelNotes-1.5.4.txt index e6fbcdb2e1..c6953ea515 100644 --- a/Documentation/RelNotes-1.5.4.txt +++ b/Documentation/RelNotes-1.5.4.txt @@ -114,6 +114,9 @@ Updates since v1.5.3 * "git reset" is now built-in and its output can be squelched with -q. + * "git reset --hard" does not make any sense in a bare + repository, but did not error out; fixed. + * "git send-email" can optionally talk over ssmtp and use SMTP-AUTH. * "git rebase" learned --whitespace option. @@ -344,6 +347,6 @@ series. -- exec >/var/tmp/1 -O=v1.5.4-rc1-36-g49e6be5 +O=v1.5.4-rc2-37-ge0cd252 echo O=`git describe refs/heads/master` git shortlog --no-merges $O..refs/heads/master ^refs/heads/maint From 7c390d90e8b6322948f45cecc658d62813c0d5ae Mon Sep 17 00:00:00 2001 From: Marco Costalba Date: Sat, 5 Jan 2008 09:57:24 +0100 Subject: [PATCH 44/93] git-stash: use stdout instead of stderr for non error messages Some scripts and libraries check stderr to detect a failing command, instead of checking the exit code. Because the output from git-status is not primarily for machine consumption, it would not hurt to send these messages to stdout instead and it will make it easier to drive the command for such callers. Signed-off-by: Marco Costalba Signed-off-by: Junio C Hamano --- git-stash.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/git-stash.sh b/git-stash.sh index 06cb177ec6..4d5e5c0be7 100755 --- a/git-stash.sh +++ b/git-stash.sh @@ -86,7 +86,7 @@ save_stash () { if no_changes then - echo >&2 'No local changes to save' + echo 'No local changes to save' exit 0 fi test -f "$GIT_DIR/logs/$ref_stash" || @@ -99,7 +99,7 @@ save_stash () { git update-ref -m "$stash_msg" $ref_stash $w_commit || die "Cannot save the current status" - printf >&2 'Saved working directory and index state "%s"\n' "$stash_msg" + printf 'Saved working directory and index state "%s"\n' "$stash_msg" } have_stash () { @@ -229,7 +229,7 @@ create) if test $# -eq 0 then save_stash && - echo >&2 '(To restore them type "git stash apply")' && + echo '(To restore them type "git stash apply")' && git-reset --hard else usage From b039f0a62d513226352f9bd745374629f8579b0c Mon Sep 17 00:00:00 2001 From: Paul Mackerras Date: Sun, 6 Jan 2008 15:54:46 +1100 Subject: [PATCH 45/93] gitk: Restore some widget options whose defaults changed in Tk 8.5 The default options for panedwindows in Tk 8.5 make the sash virtually invisible -- the handle is not shown and the relief is flat. This puts the defaults back to showing the handle and a raised relief on the sash, as in Tk 8.4. This uses the option command to do this, and also uses the option command to set the default font for various UI elements to the UI font ("uifont"). Signed-off-by: Paul Mackerras --- gitk | 105 +++++++++++++++++++++++++---------------------------------- 1 file changed, 45 insertions(+), 60 deletions(-) diff --git a/gitk b/gitk index 684e6141eb..4a923afdf3 100755 --- a/gitk +++ b/gitk @@ -613,6 +613,19 @@ proc confirm_popup msg { return $confirm_ok } +proc setoptions {} { + option add *Panedwindow.showHandle 1 startupFile + option add *Panedwindow.sashRelief raised startupFile + option add *Button.font uifont startupFile + option add *Checkbutton.font uifont startupFile + option add *Radiobutton.font uifont startupFile + option add *Menu.font uifont startupFile + option add *Menubutton.font uifont startupFile + option add *Label.font uifont startupFile + option add *Message.font uifont startupFile + option add *Entry.font uifont startupFile +} + proc makewindow {} { global canv canv2 canv3 linespc charspc ctext cflist global tabstop @@ -631,19 +644,16 @@ proc makewindow {} { menu .bar .bar add cascade -label [mc "File"] -menu .bar.file - .bar configure -font uifont menu .bar.file .bar.file add command -label [mc "Update"] -command updatecommits .bar.file add command -label [mc "Reread references"] -command rereadrefs .bar.file add command -label [mc "List references"] -command showrefs .bar.file add command -label [mc "Quit"] -command doquit - .bar.file configure -font uifont menu .bar.edit .bar add cascade -label [mc "Edit"] -menu .bar.edit .bar.edit add command -label [mc "Preferences"] -command doprefs - .bar.edit configure -font uifont - menu .bar.view -font uifont + menu .bar.view .bar add cascade -label [mc "View"] -menu .bar.view .bar.view add command -label [mc "New view..."] -command {newview 0} .bar.view add command -label [mc "Edit view..."] -command editview \ @@ -657,7 +667,7 @@ proc makewindow {} { .bar add cascade -label [mc "Help"] -menu .bar.help .bar.help add command -label [mc "About gitk"] -command about .bar.help add command -label [mc "Key bindings"] -command keys - .bar.help configure -font uifont + .bar.help configure . configure -menu .bar # the gui has upper and lower half, parts of a paned window. @@ -714,7 +724,7 @@ proc makewindow {} { set entries $sha1entry set sha1but .tf.bar.sha1label button $sha1but -text [mc "SHA1 ID: "] -state disabled -relief flat \ - -command gotocommit -width 8 -font uifont + -command gotocommit -width 8 $sha1but conf -disabledforeground [$sha1but cget -foreground] pack .tf.bar.sha1label -side left entry $sha1entry -width 40 -font textfont -textvariable sha1string @@ -746,7 +756,7 @@ proc makewindow {} { # Status label and progress bar set statusw .tf.bar.status - label $statusw -width 15 -relief sunken -font uifont + label $statusw -width 15 -relief sunken pack $statusw -side left -padx 5 set h [expr {[font metrics uifont -linespace] + 2}] set progresscanv .tf.bar.progress @@ -763,10 +773,10 @@ proc makewindow {} { set progupdatepending 0 # build up the bottom bar of upper window - label .tf.lbar.flabel -text "[mc "Find"] " -font uifont - button .tf.lbar.fnext -text [mc "next"] -command {dofind 1 1} -font uifont - button .tf.lbar.fprev -text [mc "prev"] -command {dofind -1 1} -font uifont - label .tf.lbar.flab2 -text " [mc "commit"] " -font uifont + label .tf.lbar.flabel -text "[mc "Find"] " + button .tf.lbar.fnext -text [mc "next"] -command {dofind 1 1} + button .tf.lbar.fprev -text [mc "prev"] -command {dofind -1 1} + label .tf.lbar.flab2 -text " [mc "commit"] " pack .tf.lbar.flabel .tf.lbar.fnext .tf.lbar.fprev .tf.lbar.flab2 \ -side left -fill y set gdttype [mc "containing:"] @@ -775,8 +785,6 @@ proc makewindow {} { [mc "touching paths:"] \ [mc "adding/removing string:"]] trace add variable gdttype write gdttype_change - $gm conf -font uifont - .tf.lbar.gdttype conf -font uifont pack .tf.lbar.gdttype -side left -fill y set findstring {} @@ -788,14 +796,10 @@ proc makewindow {} { set findtypemenu [tk_optionMenu .tf.lbar.findtype \ findtype [mc "Exact"] [mc "IgnCase"] [mc "Regexp"]] trace add variable findtype write findcom_change - .tf.lbar.findtype configure -font uifont - .tf.lbar.findtype.menu configure -font uifont set findloc [mc "All fields"] tk_optionMenu .tf.lbar.findloc findloc [mc "All fields"] [mc "Headline"] \ [mc "Comments"] [mc "Author"] [mc "Committer"] trace add variable findloc write find_change - .tf.lbar.findloc configure -font uifont - .tf.lbar.findloc.menu configure -font uifont pack .tf.lbar.findloc -side right pack .tf.lbar.findtype -side right pack $fstring -side left -expand 1 -fill x @@ -822,22 +826,20 @@ proc makewindow {} { frame .bleft.top frame .bleft.mid - button .bleft.top.search -text [mc "Search"] -command dosearch \ - -font uifont + button .bleft.top.search -text [mc "Search"] -command dosearch pack .bleft.top.search -side left -padx 5 set sstring .bleft.top.sstring entry $sstring -width 20 -font textfont -textvariable searchstring lappend entries $sstring trace add variable searchstring write incrsearch pack $sstring -side left -expand 1 -fill x - radiobutton .bleft.mid.diff -text [mc "Diff"] -font uifont \ + radiobutton .bleft.mid.diff -text [mc "Diff"] \ -command changediffdisp -variable diffelide -value {0 0} - radiobutton .bleft.mid.old -text [mc "Old version"] -font uifont \ + radiobutton .bleft.mid.old -text [mc "Old version"] \ -command changediffdisp -variable diffelide -value {0 1} - radiobutton .bleft.mid.new -text [mc "New version"] -font uifont \ + radiobutton .bleft.mid.new -text [mc "New version"] \ -command changediffdisp -variable diffelide -value {1 0} - label .bleft.mid.labeldiffcontext -text " [mc "Lines of context"]: " \ - -font uifont + label .bleft.mid.labeldiffcontext -text " [mc "Lines of context"]: " pack .bleft.mid.diff .bleft.mid.old .bleft.mid.new -side left spinbox .bleft.mid.diffcontext -width 5 -font textfont \ -from 1 -increment 1 -to 10000000 \ @@ -897,10 +899,8 @@ proc makewindow {} { frame .bright.mode radiobutton .bright.mode.patch -text [mc "Patch"] \ -command reselectline -variable cmitmode -value "patch" - .bright.mode.patch configure -font uifont radiobutton .bright.mode.tree -text [mc "Tree"] \ -command reselectline -variable cmitmode -value "tree" - .bright.mode.tree configure -font uifont grid .bright.mode.patch .bright.mode.tree -sticky ew pack .bright.mode -side top -fill x set cflist .bright.cfiles @@ -1286,17 +1286,14 @@ Copyright © 2005-2006 Paul Mackerras Use and redistribute under the terms of the GNU General Public License"] \ -justify center -aspect 400 -border 2 -bg white -relief groove pack $w.m -side top -fill x -padx 2 -pady 2 - $w.m configure -font uifont button $w.ok -text [mc "Close"] -command "destroy $w" -default active pack $w.ok -side bottom - $w.ok configure -font uifont bind $w "focus $w.ok" bind $w "destroy $w" bind $w "destroy $w" } proc keys {} { - global uifont set w .keys if {[winfo exists $w]} { raise $w @@ -1350,10 +1347,8 @@ f Scroll diff view to next file "] \ -justify left -bg white -border 2 -relief groove pack $w.m -side top -fill both -padx 2 -pady 2 - $w.m configure -font uifont button $w.ok -text [mc "Close"] -command "destroy $w" -default active pack $w.ok -side bottom - $w.ok configure -font uifont bind $w "focus $w.ok" bind $w "destroy $w" bind $w "destroy $w" @@ -1848,7 +1843,7 @@ proc shellsplit {str} { # Code to implement multiple views proc newview {ishighlight} { - global nextviewnum newviewname newviewperm uifont newishighlight + global nextviewnum newviewname newviewperm newishighlight global newviewargs revtreeargs set newishighlight $ishighlight @@ -1881,23 +1876,22 @@ proc editview {} { proc vieweditor {top n title} { global newviewname newviewperm viewfiles - global uifont toplevel $top wm title $top $title - label $top.nl -text [mc "Name"] -font uifont - entry $top.name -width 20 -textvariable newviewname($n) -font uifont + label $top.nl -text [mc "Name"] + entry $top.name -width 20 -textvariable newviewname($n) grid $top.nl $top.name -sticky w -pady 5 - checkbutton $top.perm -text [mc "Remember this view"] -variable newviewperm($n) \ - -font uifont + checkbutton $top.perm -text [mc "Remember this view"] \ + -variable newviewperm($n) grid $top.perm - -pady 5 -sticky w - message $top.al -aspect 1000 -font uifont \ + message $top.al -aspect 1000 \ -text [mc "Commits to include (arguments to git rev-list):"] grid $top.al - -sticky w -pady 5 entry $top.args -width 50 -textvariable newviewargs($n) \ - -background white -font uifont + -background white grid $top.args - -sticky ew -padx 5 - message $top.l -aspect 1000 -font uifont \ + message $top.l -aspect 1000 \ -text [mc "Enter files and directories to include, one per line:"] grid $top.l - -sticky w text $top.t -width 40 -height 10 -background white -font uifont @@ -1911,10 +1905,8 @@ proc vieweditor {top n title} { } grid $top.t - -sticky ew -padx 5 frame $top.buts - button $top.buts.ok -text [mc "OK"] -command [list newviewok $top $n] \ - -font uifont - button $top.buts.can -text [mc "Cancel"] -command [list destroy $top] \ - -font uifont + button $top.buts.ok -text [mc "OK"] -command [list newviewok $top $n] + button $top.buts.can -text [mc "Cancel"] -command [list destroy $top] grid $top.buts.ok $top.buts.can grid columnconfigure $top.buts 0 -weight 1 -uniform a grid columnconfigure $top.buts 1 -weight 1 -uniform a @@ -6522,15 +6514,14 @@ proc showrefs {} { grid $top.list $top.ysb -sticky nsew grid $top.xsb x -sticky ew frame $top.f - label $top.f.l -text "[mc "Filter"]: " -font uifont - entry $top.f.e -width 20 -textvariable reflistfilter -font uifont + label $top.f.l -text "[mc "Filter"]: " + entry $top.f.e -width 20 -textvariable reflistfilter set reflistfilter "*" trace add variable reflistfilter write reflistfilter_change pack $top.f.e -side right -fill x -expand 1 pack $top.f.l -side left grid $top.f - -sticky ew -pady 2 - button $top.close -command [list destroy $top] -text [mc "Close"] \ - -font uifont + button $top.close -command [list destroy $top] -text [mc "Close"] grid $top.close - grid columnconfigure $top 0 -weight 1 grid rowconfigure $top 0 -weight 1 @@ -7842,7 +7833,7 @@ proc choosefont {font which} { eval font config sample [font actual $font] toplevel $top wm title $top [mc "Gitk font chooser"] - label $top.l -textvariable fontparam(which) -font uifont + label $top.l -textvariable fontparam(which) pack $top.l -side top set fontlist [lsort [font families]] frame $top.f @@ -7872,10 +7863,8 @@ proc choosefont {font which} { bind $top.c [list centertext $top.c] pack $top.c -side top -fill x frame $top.buts - button $top.buts.ok -text [mc "OK"] -command fontok -default active \ - -font uifont - button $top.buts.can -text [mc "Cancel"] -command fontcan -default normal \ - -font uifont + button $top.buts.ok -text [mc "OK"] -command fontok -default active + button $top.buts.can -text [mc "Cancel"] -command fontcan -default normal grid $top.buts.ok $top.buts.can grid columnconfigure $top.buts 0 -weight 1 -uniform a grid columnconfigure $top.buts 1 -weight 1 -uniform a @@ -7943,7 +7932,7 @@ proc doprefs {} { global maxwidth maxgraphpct global oldprefs prefstop showneartags showlocalchanges global bgcolor fgcolor ctext diffcolors selectbgcolor - global uifont tabstop limitdiffs + global tabstop limitdiffs set top .gitkprefs set prefstop $top @@ -7958,7 +7947,6 @@ proc doprefs {} { toplevel $top wm title $top [mc "Gitk preferences"] label $top.ldisp -text [mc "Commit list display options"] - $top.ldisp configure -font uifont grid $top.ldisp - -sticky w -pady 10 label $top.spacer -text " " label $top.maxwidthl -text [mc "Maximum graph width (lines)"] \ @@ -7976,7 +7964,6 @@ proc doprefs {} { grid x $top.showlocal -sticky w label $top.ddisp -text [mc "Diff display options"] - $top.ddisp configure -font uifont grid $top.ddisp - -sticky w -pady 10 label $top.tabstopl -text [mc "Tab spacing"] -font optionfont spinbox $top.tabstop -from 1 -to 20 -width 4 -textvariable tabstop @@ -7993,7 +7980,6 @@ proc doprefs {} { grid x $top.ldiff -sticky w label $top.cdisp -text [mc "Colors: press to choose"] - $top.cdisp configure -font uifont grid $top.cdisp - -sticky w -pady 10 label $top.bg -padx 40 -relief sunk -background $bgcolor button $top.bgbut -text [mc "Background"] -font optionfont \ @@ -8025,7 +8011,6 @@ proc doprefs {} { grid x $top.selbgbut $top.selbgsep -sticky w label $top.cfont -text [mc "Fonts: press to choose"] - $top.cfont configure -font uifont grid $top.cfont - -sticky w -pady 10 mkfontdisp mainfont $top [mc "Main font"] mkfontdisp textfont $top [mc "Diff display font"] @@ -8033,9 +8018,7 @@ proc doprefs {} { frame $top.buts button $top.buts.ok -text [mc "OK"] -command prefsok -default active - $top.buts.ok configure -font uifont button $top.buts.can -text [mc "Cancel"] -command prefscan -default normal - $top.buts.can configure -font uifont grid $top.buts.ok $top.buts.can grid columnconfigure $top.buts 0 -weight 1 -uniform a grid columnconfigure $top.buts 1 -weight 1 -uniform a @@ -8511,6 +8494,8 @@ eval font create textfontbold [fontflags textfont 1] parsefont uifont $uifont eval font create uifont [fontflags uifont] +setoptions + # check that we can find a .git directory somewhere... if {[catch {set gitdir [gitdir]}]} { show_error {} . [mc "Cannot find a git repository here."] From 3023dc690f98f83b64cc6f2a9cc015bf2b01964a Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sat, 5 Jan 2008 01:35:54 -0800 Subject: [PATCH 46/93] git-stash clear: refuse to work with extra parameter for now Because it is so tempting to expect "git stash clear stash@{4}" to remove the fourth element in the stash while leaving other elements intact, we should not blindly throw away everything upon seeing such a command. This may change when we start using "git reflog delete" to selectively nuke a single (or multiple, for that matter) stash entries with such a command line. Signed-off-by: Junio C Hamano --- git-stash.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/git-stash.sh b/git-stash.sh index 4d5e5c0be7..b00f888169 100755 --- a/git-stash.sh +++ b/git-stash.sh @@ -20,6 +20,10 @@ no_changes () { } clear_stash () { + if test $# != 0 + then + die "git stash clear with parameters is unimplemented" + fi if current=$(git rev-parse --verify $ref_stash 2>/dev/null) then git update-ref -d $ref_stash $current @@ -216,7 +220,8 @@ apply) apply_stash "$@" ;; clear) - clear_stash + shift + clear_stash "$@" ;; create) if test $# -gt 0 && test "$1" = create From a6d97d49e23382027efff8a8e90e69e0572620c6 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sat, 5 Jan 2008 12:09:55 -0800 Subject: [PATCH 47/93] git-rev-parse --symbolic-full-name The plumbing level can understand that the user meant "refs/heads/master" when the user says "master" or "heads/master", but there is no easy way for the scripts to figure it out without duplicating the dwim_ref() logic. Signed-off-by: Junio C Hamano --- Documentation/git-rev-parse.txt | 7 +++++++ builtin-rev-parse.c | 37 ++++++++++++++++++++++++++++++--- 2 files changed, 41 insertions(+), 3 deletions(-) diff --git a/Documentation/git-rev-parse.txt b/Documentation/git-rev-parse.txt index 329fce0aab..0cedc13728 100644 --- a/Documentation/git-rev-parse.txt +++ b/Documentation/git-rev-parse.txt @@ -70,6 +70,13 @@ OPTIONS possible '{caret}' prefix); this option makes them output in a form as close to the original input as possible. +--symbolic-full-name:: + This is similar to \--symbolic, but it omits input that + are not refs (i.e. branch or tag names; or more + explicitly disambiguating "heads/master" form, when you + want to name the "master" branch when there is an + unfortunately named tag "master"), and show them as full + refnames (e.g. "refs/heads/master"). --all:: Show all refs found in `$GIT_DIR/refs`. diff --git a/builtin-rev-parse.c b/builtin-rev-parse.c index 20d1789e01..b9af1a5a55 100644 --- a/builtin-rev-parse.c +++ b/builtin-rev-parse.c @@ -21,6 +21,9 @@ static const char *def; #define NORMAL 0 #define REVERSED 1 static int show_type = NORMAL; + +#define SHOW_SYMBOLIC_ASIS 1 +#define SHOW_SYMBOLIC_FULL 2 static int symbolic; static int abbrev; static int output_sq; @@ -103,8 +106,32 @@ static void show_rev(int type, const unsigned char *sha1, const char *name) if (type != show_type) putchar('^'); - if (symbolic && name) - show(name); + if (symbolic && name) { + if (symbolic == SHOW_SYMBOLIC_FULL) { + unsigned char discard[20]; + char *full; + + switch (dwim_ref(name, strlen(name), discard, &full)) { + case 0: + /* + * Not found -- not a ref. We could + * emit "name" here, but symbolic-full + * users are interested in finding the + * refs spelled in full, and they would + * need to filter non-refs if we did so. + */ + break; + case 1: /* happy */ + show(full); + break; + default: /* ambiguous */ + error("refname '%s' is ambiguous", name); + break; + } + } else { + show(name); + } + } else if (abbrev) show(find_unique_abbrev(sha1, abbrev)); else @@ -421,7 +448,11 @@ int cmd_rev_parse(int argc, const char **argv, const char *prefix) continue; } if (!strcmp(arg, "--symbolic")) { - symbolic = 1; + symbolic = SHOW_SYMBOLIC_ASIS; + continue; + } + if (!strcmp(arg, "--symbolic-full-name")) { + symbolic = SHOW_SYMBOLIC_FULL; continue; } if (!strcmp(arg, "--all")) { From 418fa3a5c9111e675d8fcd3271315c38cdb1f16b Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sat, 5 Jan 2008 12:18:43 -0800 Subject: [PATCH 48/93] filter-branch: work correctly with ambiguous refnames 'git-filter-branch branch' could fail producing the error: "Which ref do you want to rewrite?" if existed another branch or tag, which name was 'branch-something' or 'something/branch'. [jc: original report and fix were done between Dmitry Potapov and Dscho; I rewrote it using "rev-parse --symbolic-full-name"] Signed-off-by: Junio C Hamano --- git-filter-branch.sh | 22 +++------------------- 1 file changed, 3 insertions(+), 19 deletions(-) diff --git a/git-filter-branch.sh b/git-filter-branch.sh index ae29f47e41..ebf05ca600 100755 --- a/git-filter-branch.sh +++ b/git-filter-branch.sh @@ -209,25 +209,9 @@ ORIG_GIT_INDEX_FILE="$GIT_INDEX_FILE" GIT_WORK_TREE=. export GIT_DIR GIT_WORK_TREE -# These refs should be updated if their heads were rewritten - -git rev-parse --revs-only --symbolic "$@" | -while read ref -do - # normalize ref - case "$ref" in - HEAD) - ref="$(git symbolic-ref "$ref")" - ;; - refs/*) - ;; - *) - ref="$(git for-each-ref --format='%(refname)' | - grep /"$ref")" - esac - - git check-ref-format "$ref" && echo "$ref" -done > "$tempdir"/heads +# The refs should be updated if their heads were rewritten +git rev-parse --no-flags --revs-only --symbolic-full-name "$@" | +sed -e '/^^/d' >"$tempdir"/heads test -s "$tempdir"/heads || die "Which ref do you want to rewrite?" From 5682694a3c1f272f230301f2b11a834a141d1efe Mon Sep 17 00:00:00 2001 From: Mark Levedahl Date: Sat, 5 Jan 2008 17:32:21 -0500 Subject: [PATCH 49/93] Documentation/Makefile - honor $DESTDIR for quick-install target Signed-off-by: Mark Levedahl Signed-off-by: Junio C Hamano --- Documentation/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/Makefile b/Documentation/Makefile index c4486d3d47..c641174189 100644 --- a/Documentation/Makefile +++ b/Documentation/Makefile @@ -224,6 +224,6 @@ install-webdoc : html sh ./install-webdoc.sh $(WEBDOC_DEST) quick-install: - sh ./install-doc-quick.sh $(DOC_REF) $(mandir) + sh ./install-doc-quick.sh $(DOC_REF) $(DESTDIR)$(mandir) .PHONY: .FORCE-GIT-VERSION-FILE From f7ab5c793707082d41e19093f536cdc0d45d8830 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sun, 6 Jan 2008 04:21:07 -0800 Subject: [PATCH 50/93] custom pretty format: tolerate empty e-mail address When e-mail address is empty (e.g. "A U Thor <>"), --pretty=format misparsed the commit header and did not pick up the date field correctly. Noticed by Marco, fixed slightly differently with additional sanity check and with a test. Signed-off-by: Junio C Hamano --- pretty.c | 16 ++++++++++++---- t/t6006-rev-list-format.sh | 10 ++++++++++ 2 files changed, 22 insertions(+), 4 deletions(-) diff --git a/pretty.c b/pretty.c index 5b1078beb6..b987ff245b 100644 --- a/pretty.c +++ b/pretty.c @@ -292,7 +292,18 @@ static void format_person_part(struct strbuf *sb, char part, /* parse name */ for (end = 0; end < len && msg[end] != '<'; end++) ; /* do nothing */ + /* + * If it does not even have a '<' and '>', that is + * quite a bogus commit author and we discard it; + * this is in line with add_user_info() that is used + * in the normal codepath. When end points at the '<' + * that we found, it should have matching '>' later, + * which means start (beginning of email address) must + * be strictly below len. + */ start = end + 1; + if (start >= len - 1) + return; while (end > 0 && isspace(msg[end - 1])) end--; if (part == 'n') { /* name */ @@ -300,11 +311,8 @@ static void format_person_part(struct strbuf *sb, char part, return; } - if (start >= len) - return; - /* parse email */ - for (end = start + 1; end < len && msg[end] != '>'; end++) + for (end = start; end < len && msg[end] != '>'; end++) ; /* do nothing */ if (end >= len) diff --git a/t/t6006-rev-list-format.sh b/t/t6006-rev-list-format.sh index 1e4541afea..0dc915ea67 100755 --- a/t/t6006-rev-list-format.sh +++ b/t/t6006-rev-list-format.sh @@ -139,4 +139,14 @@ commit 131a310eb913d107dd3c09a65d1651175898735d commit 86c75cfd708a0e5868dc876ed5b8bb66c80b4873 EOF +test_expect_success 'empty email' ' + test_tick && + C=$(GIT_AUTHOR_EMAIL= git commit-tree HEAD^{tree} failure + false + } +' + test_done From 4c785e50debe13c4cdc3cfae7c6bc4977f6eef3d Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sat, 5 Jan 2008 19:09:09 -0800 Subject: [PATCH 51/93] Documentation: remove gitman.info with "make clean" Signed-off-by: Junio C Hamano --- Documentation/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Documentation/Makefile b/Documentation/Makefile index c641174189..7b0685b7b2 100644 --- a/Documentation/Makefile +++ b/Documentation/Makefile @@ -145,7 +145,8 @@ cmd-list.made: cmd-list.perl ../command-list.txt $(MAN1_TXT) git.7 git.html: git.txt clean: - $(RM) *.xml *.xml+ *.html *.html+ *.1 *.5 *.7 *.texi *.texi+ git.info + $(RM) *.xml *.xml+ *.html *.html+ *.1 *.5 *.7 + $(RM) *.texi *.texi+ git.info gitman.info $(RM) howto-index.txt howto/*.html doc.dep $(RM) technical/api-*.html technical/api-index.txt $(RM) $(cmds_txt) *.made From 5f8bee5859a82144fc03feee2cc99288eb923d9d Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sat, 5 Jan 2008 19:10:35 -0800 Subject: [PATCH 52/93] Documentation: fix "gitlink::foobar[s]" They should be spelled with a single colon. Signed-off-by: Junio C Hamano --- Documentation/git-index-pack.txt | 2 +- Documentation/git-name-rev.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/git-index-pack.txt b/Documentation/git-index-pack.txt index bf5c2bddf4..042c217fa0 100644 --- a/Documentation/git-index-pack.txt +++ b/Documentation/git-index-pack.txt @@ -43,7 +43,7 @@ OPTIONS a default name determined from the pack content. If is not specified consider using --keep to prevent a race condition between this process and - gitlink::git-repack[1]. + gitlink:git-repack[1]. --fix-thin:: It is possible for gitlink:git-pack-objects[1] to build diff --git a/Documentation/git-name-rev.txt b/Documentation/git-name-rev.txt index 306e1a4956..fa2c5fdd4b 100644 --- a/Documentation/git-name-rev.txt +++ b/Documentation/git-name-rev.txt @@ -38,7 +38,7 @@ OPTIONS Instead of printing both the SHA-1 and the name, print only the name. If given with --tags the usual tag prefix of "tags/" is also omitted from the name, matching the output - of gitlink::git-describe[1] more closely. This option + of gitlink:git-describe[1] more closely. This option cannot be combined with --stdin. EXAMPLE From 5162e69732d13dd079919a389a6ace8878aad716 Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Sat, 29 Dec 2007 00:20:38 -0600 Subject: [PATCH 53/93] Documentation: rename gitlink macro to linkgit Between AsciiDoc 8.2.2 and 8.2.3, the following change was made to the stock Asciidoc configuration: @@ -149,7 +153,10 @@ # Inline macros. # Backslash prefix required for escape processing. # (?s) re flag for line spanning. -(?su)[\\]?(?P\w(\w|-)*?):(?P\S*?)(\[(?P.*?)\])= + +# Explicit so they can be nested. +(?su)[\\]?(?P(http|https|ftp|file|mailto|callto|image|link)):(?P\S*?)(\[(?P.*?)\])= + # Anchor: [[[id]]]. Bibliographic anchor. (?su)[\\]?\[\[\[(?P[\w][\w-]*?)\]\]\]=anchor3 # Anchor: [[id,xreflabel]] This default regex now matches explicit values, and unfortunately in this case gitlink was being matched by just 'link', causing the wrong inline macro template to be applied. By renaming the macro, we can avoid being matched by the wrong regex. Signed-off-by: Dan McGee Signed-off-by: Junio C Hamano --- Documentation/asciidoc.conf | 8 +- Documentation/blame-options.txt | 2 +- Documentation/cmd-list.perl | 2 +- Documentation/config.txt | 126 ++++++------ Documentation/cvs-migration.txt | 10 +- Documentation/diff-options.txt | 4 +- Documentation/everyday.txt | 48 ++--- Documentation/fetch-options.txt | 2 +- Documentation/git-add.txt | 16 +- Documentation/git-am.txt | 16 +- Documentation/git-annotate.txt | 4 +- Documentation/git-apply.txt | 12 +- Documentation/git-archimport.txt | 2 +- Documentation/git-archive.txt | 2 +- Documentation/git-bisect.txt | 2 +- Documentation/git-blame.txt | 8 +- Documentation/git-branch.txt | 12 +- Documentation/git-bundle.txt | 10 +- Documentation/git-cat-file.txt | 4 +- Documentation/git-check-attr.txt | 4 +- Documentation/git-check-ref-format.txt | 6 +- Documentation/git-checkout-index.txt | 2 +- Documentation/git-checkout.txt | 4 +- Documentation/git-cherry-pick.txt | 4 +- Documentation/git-cherry.txt | 2 +- Documentation/git-citool.txt | 6 +- Documentation/git-clean.txt | 4 +- Documentation/git-clone.txt | 2 +- Documentation/git-commit-tree.txt | 6 +- Documentation/git-commit.txt | 30 +-- Documentation/git-config.txt | 2 +- Documentation/git-count-objects.txt | 2 +- Documentation/git-cvsexportcommit.txt | 2 +- Documentation/git-cvsimport.txt | 4 +- Documentation/git-cvsserver.txt | 4 +- Documentation/git-daemon.txt | 2 +- Documentation/git-describe.txt | 2 +- Documentation/git-diff-files.txt | 2 +- Documentation/git-diff-index.txt | 2 +- Documentation/git-diff-tree.txt | 2 +- Documentation/git-diff.txt | 8 +- Documentation/git-fast-export.txt | 12 +- Documentation/git-fast-import.txt | 18 +- Documentation/git-fetch-pack.txt | 4 +- Documentation/git-fetch.txt | 4 +- Documentation/git-filter-branch.txt | 16 +- Documentation/git-fmt-merge-msg.txt | 4 +- Documentation/git-format-patch.txt | 8 +- Documentation/git-fsck-objects.txt | 2 +- Documentation/git-fsck.txt | 2 +- Documentation/git-gc.txt | 14 +- Documentation/git-get-tar-commit-id.txt | 4 +- Documentation/git-grep.txt | 2 +- Documentation/git-gui.txt | 4 +- Documentation/git-hash-object.txt | 2 +- Documentation/git-help.txt | 6 +- Documentation/git-http-fetch.txt | 2 +- Documentation/git-http-push.txt | 2 +- Documentation/git-imap-send.txt | 2 +- Documentation/git-index-pack.txt | 10 +- Documentation/git-init-db.txt | 2 +- Documentation/git-init.txt | 2 +- Documentation/git-instaweb.txt | 2 +- Documentation/git-log.txt | 10 +- Documentation/git-lost-found.txt | 4 +- Documentation/git-ls-files.txt | 8 +- Documentation/git-ls-remote.txt | 4 +- Documentation/git-ls-tree.txt | 2 +- Documentation/git-mailinfo.txt | 4 +- Documentation/git-mailsplit.txt | 2 +- Documentation/git-merge-base.txt | 2 +- Documentation/git-merge-file.txt | 4 +- Documentation/git-merge-index.txt | 2 +- Documentation/git-merge-one-file.txt | 2 +- Documentation/git-merge-tree.txt | 2 +- Documentation/git-merge.txt | 8 +- Documentation/git-mergetool.txt | 4 +- Documentation/git-mktag.txt | 2 +- Documentation/git-mktree.txt | 2 +- Documentation/git-mv.txt | 2 +- Documentation/git-name-rev.txt | 4 +- Documentation/git-pack-objects.txt | 10 +- Documentation/git-pack-redundant.txt | 8 +- Documentation/git-pack-refs.txt | 2 +- Documentation/git-parse-remote.txt | 2 +- Documentation/git-patch-id.txt | 2 +- Documentation/git-peek-remote.txt | 2 +- Documentation/git-prune-packed.txt | 6 +- Documentation/git-prune.txt | 2 +- Documentation/git-pull.txt | 10 +- Documentation/git-push.txt | 4 +- Documentation/git-quiltimport.txt | 2 +- Documentation/git-read-tree.txt | 8 +- Documentation/git-rebase.txt | 10 +- Documentation/git-receive-pack.txt | 4 +- Documentation/git-reflog.txt | 8 +- Documentation/git-relink.txt | 2 +- Documentation/git-remote.txt | 12 +- Documentation/git-repack.txt | 14 +- Documentation/git-repo-config.txt | 2 +- Documentation/git-request-pull.txt | 2 +- Documentation/git-rerere.txt | 4 +- Documentation/git-reset.txt | 8 +- Documentation/git-rev-list.txt | 20 +- Documentation/git-rev-parse.txt | 2 +- Documentation/git-revert.txt | 4 +- Documentation/git-rm.txt | 4 +- Documentation/git-send-email.txt | 2 +- Documentation/git-send-pack.txt | 6 +- Documentation/git-sh-setup.txt | 2 +- Documentation/git-shell.txt | 2 +- Documentation/git-shortlog.txt | 2 +- Documentation/git-show-branch.txt | 2 +- Documentation/git-show-index.txt | 2 +- Documentation/git-show-ref.txt | 6 +- Documentation/git-show.txt | 8 +- Documentation/git-stash.txt | 10 +- Documentation/git-status.txt | 6 +- Documentation/git-stripspace.txt | 2 +- Documentation/git-submodule.txt | 6 +- Documentation/git-svn.txt | 12 +- Documentation/git-symbolic-ref.txt | 2 +- Documentation/git-tag.txt | 2 +- Documentation/git-tar-tree.txt | 2 +- Documentation/git-unpack-file.txt | 2 +- Documentation/git-unpack-objects.txt | 2 +- Documentation/git-update-index.txt | 12 +- Documentation/git-update-ref.txt | 2 +- Documentation/git-update-server-info.txt | 2 +- Documentation/git-upload-archive.txt | 2 +- Documentation/git-upload-pack.txt | 2 +- Documentation/git-var.txt | 8 +- Documentation/git-verify-pack.txt | 2 +- Documentation/git-verify-tag.txt | 2 +- Documentation/git-whatchanged.txt | 2 +- Documentation/git-write-tree.txt | 2 +- Documentation/git.txt | 20 +- Documentation/gitattributes.txt | 10 +- Documentation/gitcli.txt | 2 +- Documentation/gitignore.txt | 6 +- Documentation/gitk.txt | 6 +- Documentation/gitmodules.txt | 6 +- Documentation/glossary.txt | 18 +- Documentation/repository-layout.txt | 10 +- Documentation/tutorial-2.txt | 2 +- Documentation/tutorial.txt | 24 +-- Documentation/urls.txt | 2 +- Documentation/user-manual.conf | 2 +- Documentation/user-manual.txt | 246 +++++++++++------------ 149 files changed, 603 insertions(+), 603 deletions(-) diff --git a/Documentation/asciidoc.conf b/Documentation/asciidoc.conf index 99d8874aa0..10c1a151a4 100644 --- a/Documentation/asciidoc.conf +++ b/Documentation/asciidoc.conf @@ -1,6 +1,6 @@ -## gitlink: macro +## linkgit: macro # -# Usage: gitlink:command[manpage-section] +# Usage: linkgit:command[manpage-section] # # Note, {0} is the manpage section, while {target} is the command. # @@ -15,7 +15,7 @@ endsb=] tilde=~ ifdef::backend-docbook[] -[gitlink-inlinemacro] +[linkgit-inlinemacro] {0%{target}} {0#} {0#{target}{0}} @@ -61,6 +61,6 @@ endif::backend-docbook[] endif::doctype-manpage[] ifdef::backend-xhtml11[] -[gitlink-inlinemacro] +[linkgit-inlinemacro] {target}{0?({0})} endif::backend-xhtml11[] diff --git a/Documentation/blame-options.txt b/Documentation/blame-options.txt index 17379f0576..ea1007bfb0 100644 --- a/Documentation/blame-options.txt +++ b/Documentation/blame-options.txt @@ -39,7 +39,7 @@ of lines before or after the line given by . Show raw timestamp (Default: off). -S :: - Use revs from revs-file instead of calling gitlink:git-rev-list[1]. + Use revs from revs-file instead of calling linkgit:git-rev-list[1]. -p, --porcelain:: Show in a format designed for machine consumption. diff --git a/Documentation/cmd-list.perl b/Documentation/cmd-list.perl index c2d55cdb5e..04f99778d8 100755 --- a/Documentation/cmd-list.perl +++ b/Documentation/cmd-list.perl @@ -27,7 +27,7 @@ sub format_one { die "No description found in $name.txt"; } if (my ($verify_name, $text) = ($description =~ /^($name) - (.*)/)) { - print $out "gitlink:$name\[1\]::\n\t"; + print $out "linkgit:$name\[1\]::\n\t"; if ($attr =~ / deprecated /) { print $out "(deprecated) "; } diff --git a/Documentation/config.txt b/Documentation/config.txt index e1eaee9971..d44bc7ac4c 100644 --- a/Documentation/config.txt +++ b/Documentation/config.txt @@ -115,7 +115,7 @@ porcelain configuration variables in the respective porcelain documentation. core.fileMode:: If false, the executable bit differences between the index and the working copy are ignored; useful on broken filesystems like FAT. - See gitlink:git-update-index[1]. True by default. + See linkgit:git-update-index[1]. True by default. core.quotepath:: The commands that output paths (e.g. `ls-files`, @@ -141,8 +141,8 @@ core.autocrlf:: core.symlinks:: If false, symbolic links are checked out as small plain files that - contain the link text. gitlink:git-update-index[1] and - gitlink:git-add[1] will not change the recorded type to regular + contain the link text. linkgit:git-update-index[1] and + linkgit:git-add[1] will not change the recorded type to regular file. Useful on filesystems like FAT that do not support symbolic links. True by default. @@ -163,7 +163,7 @@ core.ignoreStat:: The working copy files are assumed to stay unchanged until you mark them otherwise manually - Git will not detect the file changes by lstat() calls. This is useful on systems where those are very - slow, such as Microsoft Windows. See gitlink:git-update-index[1]. + slow, such as Microsoft Windows. See linkgit:git-update-index[1]. False by default. core.preferSymlinkRefs:: @@ -176,10 +176,10 @@ core.bare:: If true this repository is assumed to be 'bare' and has no working directory associated with it. If this is the case a number of commands that require a working directory will be - disabled, such as gitlink:git-add[1] or gitlink:git-merge[1]. + disabled, such as linkgit:git-add[1] or linkgit:git-merge[1]. + -This setting is automatically guessed by gitlink:git-clone[1] or -gitlink:git-init[1] when the repository was created. By default a +This setting is automatically guessed by linkgit:git-clone[1] or +linkgit:git-init[1] when the repository was created. By default a repository that ends in "/.git" is assumed to be not bare (bare = false), while all other repositories are assumed to be bare (bare = true). @@ -216,7 +216,7 @@ core.sharedRepository:: group-writable). When 'all' (or 'world' or 'everybody'), the repository will be readable by all users, additionally to being group-shareable. When 'umask' (or 'false'), git will use permissions - reported by umask(2). See gitlink:git-init[1]. False by default. + reported by umask(2). See linkgit:git-init[1]. False by default. core.warnAmbiguousRefs:: If true, git will warn you if the ref name you passed it is ambiguous @@ -281,7 +281,7 @@ core.excludesfile:: In addition to '.gitignore' (per-directory) and '.git/info/exclude', git looks into this file for patterns of files which are not meant to be tracked. See - gitlink:gitignore[5]. + linkgit:gitignore[5]. core.editor:: Commands such as `commit` and `tag` that lets you edit @@ -310,7 +310,7 @@ core.whitespace:: space characters as an error (not enabled by default). alias.*:: - Command aliases for the gitlink:git[1] command wrapper - e.g. + Command aliases for the linkgit:git[1] command wrapper - e.g. after defining "alias.last = cat-file commit HEAD", the invocation "git last" is equivalent to "git cat-file commit HEAD". To avoid confusion and troubles with script usage, aliases that @@ -326,11 +326,11 @@ it will be treated as a shell command. For example, defining apply.whitespace:: Tells `git-apply` how to handle whitespaces, in the same way - as the '--whitespace' option. See gitlink:git-apply[1]. + as the '--whitespace' option. See linkgit:git-apply[1]. branch.autosetupmerge:: Tells `git-branch` and `git-checkout` to setup new branches - so that gitlink:git-pull[1] will appropriately merge from that + so that linkgit:git-pull[1] will appropriately merge from that remote branch. Note that even if this option is not set, this behavior can be chosen per-branch using the `--track` and `--no-track` options. This option defaults to false. @@ -356,7 +356,7 @@ branch..merge:: branch..mergeoptions:: Sets default options for merging into branch . The syntax and - supported options are equal to that of gitlink:git-merge[1], but + supported options are equal to that of linkgit:git-merge[1], but option values containing whitespace characters are currently not supported. @@ -364,7 +364,7 @@ branch..rebase:: When true, rebase the branch on top of the fetched branch, instead of merging the default branch from the default remote. *NOTE*: this is a possibly dangerous operation; do *not* use - it unless you understand the implications (see gitlink:git-rebase[1] + it unless you understand the implications (see linkgit:git-rebase[1] for details). clean.requireForce:: @@ -373,7 +373,7 @@ clean.requireForce:: color.branch:: A boolean to enable/disable color in the output of - gitlink:git-branch[1]. May be set to `always`, + linkgit:git-branch[1]. May be set to `always`, `false` (or `never`) or `auto` (or `true`), in which case colors are used only when the output is to a terminal. Defaults to false. @@ -423,7 +423,7 @@ color.pager:: color.status:: A boolean to enable/disable color in the output of - gitlink:git-status[1]. May be set to `always`, + linkgit:git-status[1]. May be set to `always`, `false` (or `never`) or `auto` (or `true`), in which case colors are used only when the output is to a terminal. Defaults to false. @@ -453,7 +453,7 @@ diff.external:: performed using the internal diff machinery, but using the given command. Note: if you want to use an external diff program only on a subset of your files, you might want to - use gitlink:gitattributes[5] instead. + use linkgit:gitattributes[5] instead. diff.renameLimit:: The number of files to consider when performing the copy/rename @@ -478,11 +478,11 @@ format.numbered:: A boolean which can enable sequence numbers in patch subjects. Setting this option to "auto" will enable it only if there is more than one patch. See --numbered option in - gitlink:git-format-patch[1]. + linkgit:git-format-patch[1]. format.headers:: Additional email headers to include in a patch to be submitted - by mail. See gitlink:git-format-patch[1]. + by mail. See linkgit:git-format-patch[1]. format.suffix:: The default for format-patch is to output files with the suffix @@ -530,27 +530,27 @@ gc.reflogexpireunreachable:: gc.rerereresolved:: Records of conflicted merge you resolved earlier are kept for this many days when `git rerere gc` is run. - The default is 60 days. See gitlink:git-rerere[1]. + The default is 60 days. See linkgit:git-rerere[1]. gc.rerereunresolved:: Records of conflicted merge you have not resolved are kept for this many days when `git rerere gc` is run. - The default is 15 days. See gitlink:git-rerere[1]. + The default is 15 days. See linkgit:git-rerere[1]. rerere.enabled:: Activate recording of resolved conflicts, so that identical conflict hunks can be resolved automatically, should they - be encountered again. gitlink:git-rerere[1] command is by + be encountered again. linkgit:git-rerere[1] command is by default enabled, but can be disabled by setting this option to false. gitcvs.enabled:: Whether the CVS server interface is enabled for this repository. - See gitlink:git-cvsserver[1]. + See linkgit:git-cvsserver[1]. gitcvs.logfile:: Path to a log file where the CVS server interface well... logs - various stuff. See gitlink:git-cvsserver[1]. + various stuff. See linkgit:git-cvsserver[1]. gitcvs.allbinary:: If true, all files are sent to the client in mode '-kb'. This @@ -563,7 +563,7 @@ gitcvs.dbname:: derived from the git repository. The exact meaning depends on the used database driver, for SQLite (which is the default driver) this is a filename. Supports variable substitution (see - gitlink:git-cvsserver[1] for details). May not contain semicolons (`;`). + linkgit:git-cvsserver[1] for details). May not contain semicolons (`;`). Default: '%Ggitcvs.%m.sqlite' gitcvs.dbdriver:: @@ -572,13 +572,13 @@ gitcvs.dbdriver:: with 'DBD::SQLite', reported to work with 'DBD::Pg', and reported *not* to work with 'DBD::mysql'. Experimental feature. May not contain double colons (`:`). Default: 'SQLite'. - See gitlink:git-cvsserver[1]. + See linkgit:git-cvsserver[1]. gitcvs.dbuser, gitcvs.dbpass:: Database user and password. Only useful if setting 'gitcvs.dbdriver', since SQLite has no concept of database users and/or passwords. 'gitcvs.dbuser' supports variable substitution (see - gitlink:git-cvsserver[1] for details). + linkgit:git-cvsserver[1] for details). All gitcvs variables except for 'gitcvs.allbinary' can also be specified as 'gitcvs..' (where 'access_method' @@ -587,7 +587,7 @@ access method. http.proxy:: Override the HTTP proxy, normally configured using the 'http_proxy' - environment variable (see gitlink:curl[1]). This can be overridden + environment variable (see linkgit:curl[1]). This can be overridden on a per-remote basis; see remote..proxy http.sslVerify:: @@ -636,7 +636,7 @@ i18n.commitEncoding:: does not care per se, but this information is necessary e.g. when importing commits from emails or in the gitk graphical history browser (and possibly at other places in the future or in other - porcelains). See e.g. gitlink:git-mailinfo[1]. Defaults to 'utf-8'. + porcelains). See e.g. linkgit:git-mailinfo[1]. Defaults to 'utf-8'. i18n.logOutputEncoding:: Character encoding the commit messages are converted to when @@ -645,7 +645,7 @@ i18n.logOutputEncoding:: log.showroot:: If true, the initial commit will be shown as a big creation event. This is equivalent to a diff against an empty tree. - Tools like gitlink:git-log[1] or gitlink:git-whatchanged[1], which + Tools like linkgit:git-log[1] or linkgit:git-whatchanged[1], which normally hide the root commit will now show it. True by default. merge.summary:: @@ -654,7 +654,7 @@ merge.summary:: merge.tool:: Controls which merge resolution program is used by - gitlink:git-mergetool[1]. Valid values are: "kdiff3", "tkdiff", + linkgit:git-mergetool[1]. Valid values are: "kdiff3", "tkdiff", "meld", "xxdiff", "emerge", "vimdiff", "gvimdiff", and "opendiff". merge.verbosity:: @@ -667,31 +667,31 @@ merge.verbosity:: merge..name:: Defines a human readable name for a custom low-level - merge driver. See gitlink:gitattributes[5] for details. + merge driver. See linkgit:gitattributes[5] for details. merge..driver:: Defines the command that implements a custom low-level - merge driver. See gitlink:gitattributes[5] for details. + merge driver. See linkgit:gitattributes[5] for details. merge..recursive:: Names a low-level merge driver to be used when performing an internal merge between common ancestors. - See gitlink:gitattributes[5] for details. + See linkgit:gitattributes[5] for details. mergetool..path:: Override the path for the given tool. This is useful in case your tool is not in the PATH. pack.window:: - The size of the window used by gitlink:git-pack-objects[1] when no + The size of the window used by linkgit:git-pack-objects[1] when no window size is given on the command line. Defaults to 10. pack.depth:: - The maximum delta depth used by gitlink:git-pack-objects[1] when no + The maximum delta depth used by linkgit:git-pack-objects[1] when no maximum depth is given on the command line. Defaults to 50. pack.windowMemory:: - The window memory size limit used by gitlink:git-pack-objects[1] + The window memory size limit used by linkgit:git-pack-objects[1] when no limit is given on the command line. The value can be suffixed with "k", "m", or "g". Defaults to 0, meaning no limit. @@ -707,16 +707,16 @@ pack.compression:: pack.deltaCacheSize:: The maximum memory in bytes used for caching deltas in - gitlink:git-pack-objects[1]. + linkgit:git-pack-objects[1]. A value of 0 means no limit. Defaults to 0. pack.deltaCacheLimit:: The maximum size of a delta, that is cached in - gitlink:git-pack-objects[1]. Defaults to 1000. + linkgit:git-pack-objects[1]. Defaults to 1000. pack.threads:: Specifies the number of threads to spawn when searching for best - delta matches. This requires that gitlink:git-pack-objects[1] + delta matches. This requires that linkgit:git-pack-objects[1] be compiled with pthreads otherwise this option is ignored with a warning. This is meant to reduce packing time on multiprocessor machines. The required amount of memory for the delta search window @@ -739,8 +739,8 @@ pull.twohead:: The default merge strategy to use when pulling a single branch. remote..url:: - The URL of a remote repository. See gitlink:git-fetch[1] or - gitlink:git-push[1]. + The URL of a remote repository. See linkgit:git-fetch[1] or + linkgit:git-push[1]. remote..proxy:: For remotes that require curl (http, https and ftp), the URL to @@ -748,24 +748,24 @@ remote..proxy:: disable proxying for that remote. remote..fetch:: - The default set of "refspec" for gitlink:git-fetch[1]. See - gitlink:git-fetch[1]. + The default set of "refspec" for linkgit:git-fetch[1]. See + linkgit:git-fetch[1]. remote..push:: - The default set of "refspec" for gitlink:git-push[1]. See - gitlink:git-push[1]. + The default set of "refspec" for linkgit:git-push[1]. See + linkgit:git-push[1]. remote..skipDefaultUpdate:: If true, this remote will be skipped by default when updating - using the update subcommand of gitlink:git-remote[1]. + using the update subcommand of linkgit:git-remote[1]. remote..receivepack:: The default program to execute on the remote side when pushing. See - option \--exec of gitlink:git-push[1]. + option \--exec of linkgit:git-push[1]. remote..uploadpack:: The default program to execute on the remote side when fetching. See - option \--exec of gitlink:git-fetch-pack[1]. + option \--exec of linkgit:git-fetch-pack[1]. remote..tagopt:: Setting this value to --no-tags disables automatic tag following when fetching @@ -773,22 +773,22 @@ remote..tagopt:: remotes.:: The list of remotes which are fetched by "git remote update - ". See gitlink:git-remote[1]. + ". See linkgit:git-remote[1]. repack.usedeltabaseoffset:: - Allow gitlink:git-repack[1] to create packs that uses + Allow linkgit:git-repack[1] to create packs that uses delta-base offset. Defaults to false. show.difftree:: - The default gitlink:git-diff-tree[1] arguments to be used - for gitlink:git-show[1]. + The default linkgit:git-diff-tree[1] arguments to be used + for linkgit:git-show[1]. showbranch.default:: - The default set of branches for gitlink:git-show-branch[1]. - See gitlink:git-show-branch[1]. + The default set of branches for linkgit:git-show-branch[1]. + See linkgit:git-show-branch[1]. status.relativePaths:: - By default, gitlink:git-status[1] shows paths relative to the + By default, linkgit:git-status[1] shows paths relative to the current directory. Setting this variable to `false` shows paths relative to the repository root (this was the default for git prior to v1.5.4). @@ -798,32 +798,32 @@ tar.umask:: tar archive entries. The default is 0002, which turns off the world write bit. The special value "user" indicates that the archiving user's umask will be used instead. See umask(2) and - gitlink:git-archive[1]. + linkgit:git-archive[1]. user.email:: Your email address to be recorded in any newly created commits. Can be overridden by the 'GIT_AUTHOR_EMAIL', 'GIT_COMMITTER_EMAIL', and - 'EMAIL' environment variables. See gitlink:git-commit-tree[1]. + 'EMAIL' environment variables. See linkgit:git-commit-tree[1]. user.name:: Your full name to be recorded in any newly created commits. Can be overridden by the 'GIT_AUTHOR_NAME' and 'GIT_COMMITTER_NAME' - environment variables. See gitlink:git-commit-tree[1]. + environment variables. See linkgit:git-commit-tree[1]. user.signingkey:: - If gitlink:git-tag[1] is not selecting the key you want it to + If linkgit:git-tag[1] is not selecting the key you want it to automatically when creating a signed tag, you can override the default selection with this variable. This option is passed unchanged to gpg's --local-user parameter, so you may specify a key using any method that gpg supports. whatchanged.difftree:: - The default gitlink:git-diff-tree[1] arguments to be used - for gitlink:git-whatchanged[1]. + The default linkgit:git-diff-tree[1] arguments to be used + for linkgit:git-whatchanged[1]. imap:: The configuration variables in the 'imap' section are described - in gitlink:git-imap-send[1]. + in linkgit:git-imap-send[1]. receive.unpackLimit:: If the number of objects received in a push is below this diff --git a/Documentation/cvs-migration.txt b/Documentation/cvs-migration.txt index 3b6b494162..ea98900228 100644 --- a/Documentation/cvs-migration.txt +++ b/Documentation/cvs-migration.txt @@ -36,12 +36,12 @@ them first before running git pull. ================================ The `pull` command knows where to get updates from because of certain configuration variables that were set by the first `git clone` -command; see `git config -l` and the gitlink:git-config[1] man +command; see `git config -l` and the linkgit:git-config[1] man page for details. ================================ You can update the shared repository with your changes by first committing -your changes, and then using the gitlink:git-push[1] command: +your changes, and then using the linkgit:git-push[1] command: ------------------------------------------------ $ git push origin master @@ -88,7 +88,7 @@ Next, give every team member read/write access to this repository. One easy way to do this is to give all the team members ssh access to the machine where the repository is hosted. If you don't want to give them a full shell on the machine, there is a restricted shell which only allows -users to do git pushes and pulls; see gitlink:git-shell[1]. +users to do git pushes and pulls; see linkgit:git-shell[1]. Put all the committers in the same group, and make the repository writable by that group: @@ -106,7 +106,7 @@ Importing a CVS archive First, install version 2.1 or higher of cvsps from link:http://www.cobite.com/cvsps/[http://www.cobite.com/cvsps/] and make sure it is in your path. Then cd to a checked out CVS working directory -of the project you are interested in and run gitlink:git-cvsimport[1]: +of the project you are interested in and run linkgit:git-cvsimport[1]: ------------------------------------------- $ git cvsimport -C @@ -146,7 +146,7 @@ Providing CVS Access to a git Repository ---------------------------------------- It is also possible to provide true CVS access to a git repository, so -that developers can still use CVS; see gitlink:git-cvsserver[1] for +that developers can still use CVS; see linkgit:git-cvsserver[1] for details. Alternative Development Models diff --git a/Documentation/diff-options.txt b/Documentation/diff-options.txt index 1a78635fba..8d35cbd60d 100644 --- a/Documentation/diff-options.txt +++ b/Documentation/diff-options.txt @@ -205,8 +205,8 @@ endif::git-format-patch[] --ext-diff:: Allow an external diff helper to be executed. If you set an - external diff driver with gitlink:gitattributes[5], you need - to use this option with gitlink:git-log[1] and friends. + external diff driver with linkgit:gitattributes[5], you need + to use this option with linkgit:git-log[1] and friends. --no-ext-diff:: Disallow external diff drivers. diff --git a/Documentation/everyday.txt b/Documentation/everyday.txt index f1993e2935..fdbd15a181 100644 --- a/Documentation/everyday.txt +++ b/Documentation/everyday.txt @@ -25,12 +25,12 @@ Basic Repository[[Basic Repository]] Everybody uses these commands to maintain git repositories. - * gitlink:git-init[1] or gitlink:git-clone[1] to create a + * linkgit:git-init[1] or linkgit:git-clone[1] to create a new repository. - * gitlink:git-fsck[1] to check the repository for errors. + * linkgit:git-fsck[1] to check the repository for errors. - * gitlink:git-gc[1] to do common housekeeping tasks such as + * linkgit:git-gc[1] to do common housekeeping tasks such as repack and prune. Examples @@ -69,28 +69,28 @@ A standalone individual developer does not exchange patches with other people, and works alone in a single repository, using the following commands. - * gitlink:git-show-branch[1] to see where you are. + * linkgit:git-show-branch[1] to see where you are. - * gitlink:git-log[1] to see what happened. + * linkgit:git-log[1] to see what happened. - * gitlink:git-checkout[1] and gitlink:git-branch[1] to switch + * linkgit:git-checkout[1] and linkgit:git-branch[1] to switch branches. - * gitlink:git-add[1] to manage the index file. + * linkgit:git-add[1] to manage the index file. - * gitlink:git-diff[1] and gitlink:git-status[1] to see what + * linkgit:git-diff[1] and linkgit:git-status[1] to see what you are in the middle of doing. - * gitlink:git-commit[1] to advance the current branch. + * linkgit:git-commit[1] to advance the current branch. - * gitlink:git-reset[1] and gitlink:git-checkout[1] (with + * linkgit:git-reset[1] and linkgit:git-checkout[1] (with pathname parameters) to undo changes. - * gitlink:git-merge[1] to merge between local branches. + * linkgit:git-merge[1] to merge between local branches. - * gitlink:git-rebase[1] to maintain topic branches. + * linkgit:git-rebase[1] to maintain topic branches. - * gitlink:git-tag[1] to mark known point. + * linkgit:git-tag[1] to mark known point. Examples ~~~~~~~~ @@ -156,16 +156,16 @@ A developer working as a participant in a group project needs to learn how to communicate with others, and uses these commands in addition to the ones needed by a standalone developer. - * gitlink:git-clone[1] from the upstream to prime your local + * linkgit:git-clone[1] from the upstream to prime your local repository. - * gitlink:git-pull[1] and gitlink:git-fetch[1] from "origin" + * linkgit:git-pull[1] and linkgit:git-fetch[1] from "origin" to keep up-to-date with the upstream. - * gitlink:git-push[1] to shared repository, if you adopt CVS + * linkgit:git-push[1] to shared repository, if you adopt CVS style shared repository workflow. - * gitlink:git-format-patch[1] to prepare e-mail submission, if + * linkgit:git-format-patch[1] to prepare e-mail submission, if you adopt Linux kernel-style public forum workflow. Examples @@ -258,17 +258,17 @@ project receives changes made by others, reviews and integrates them and publishes the result for others to use, using these commands in addition to the ones needed by participants. - * gitlink:git-am[1] to apply patches e-mailed in from your + * linkgit:git-am[1] to apply patches e-mailed in from your contributors. - * gitlink:git-pull[1] to merge from your trusted lieutenants. + * linkgit:git-pull[1] to merge from your trusted lieutenants. - * gitlink:git-format-patch[1] to prepare and send suggested + * linkgit:git-format-patch[1] to prepare and send suggested alternative to contributors. - * gitlink:git-revert[1] to undo botched commits. + * linkgit:git-revert[1] to undo botched commits. - * gitlink:git-push[1] to publish the bleeding edge. + * linkgit:git-push[1] to publish the bleeding edge. Examples @@ -343,10 +343,10 @@ Repository Administration[[Repository Administration]] A repository administrator uses the following tools to set up and maintain access to the repository by developers. - * gitlink:git-daemon[1] to allow anonymous download from + * linkgit:git-daemon[1] to allow anonymous download from repository. - * gitlink:git-shell[1] can be used as a 'restricted login shell' + * linkgit:git-shell[1] can be used as a 'restricted login shell' for shared central repository users. link:howto/update-hook-example.txt[update hook howto] has a good diff --git a/Documentation/fetch-options.txt b/Documentation/fetch-options.txt index da034223f3..61e48ccf02 100644 --- a/Documentation/fetch-options.txt +++ b/Documentation/fetch-options.txt @@ -50,5 +50,5 @@ \--depth=:: Deepen the history of a 'shallow' repository created by - `git clone` with `--depth=` option (see gitlink:git-clone[1]) + `git clone` with `--depth=` option (see linkgit:git-clone[1]) by the specified number of commits. diff --git a/Documentation/git-add.txt b/Documentation/git-add.txt index 721ca998c1..9d2ac865d2 100644 --- a/Documentation/git-add.txt +++ b/Documentation/git-add.txt @@ -37,7 +37,7 @@ directory recursion or filename globbing performed by Git (quote your globs before the shell) will be silently ignored. The 'add' command can be used to add ignored files with the `-f` (force) option. -Please see gitlink:git-commit[1] for alternative ways to add content to a +Please see linkgit:git-commit[1] for alternative ways to add content to a commit. @@ -231,12 +231,12 @@ diff:: See Also -------- -gitlink:git-status[1] -gitlink:git-rm[1] -gitlink:git-reset[1] -gitlink:git-mv[1] -gitlink:git-commit[1] -gitlink:git-update-index[1] +linkgit:git-status[1] +linkgit:git-rm[1] +linkgit:git-reset[1] +linkgit:git-mv[1] +linkgit:git-commit[1] +linkgit:git-update-index[1] Author ------ @@ -248,4 +248,4 @@ Documentation by Junio C Hamano and the git-list . GIT --- -Part of the gitlink:git[7] suite +Part of the linkgit:git[7] suite diff --git a/Documentation/git-am.txt b/Documentation/git-am.txt index e4a6b3a6f0..2ffba2102b 100644 --- a/Documentation/git-am.txt +++ b/Documentation/git-am.txt @@ -37,10 +37,10 @@ OPTIONS area to store extracted patches. -k, --keep:: - Pass `-k` flag to `git-mailinfo` (see gitlink:git-mailinfo[1]). + Pass `-k` flag to `git-mailinfo` (see linkgit:git-mailinfo[1]). -u, --utf8:: - Pass `-u` flag to `git-mailinfo` (see gitlink:git-mailinfo[1]). + Pass `-u` flag to `git-mailinfo` (see linkgit:git-mailinfo[1]). The proposed commit log message taken from the e-mail is re-coded into UTF-8 encoding (configuration variable `i18n.commitencoding` can be used to specify project's @@ -51,7 +51,7 @@ default. You could use `--no-utf8` to override this. --no-utf8:: Pass `-n` flag to `git-mailinfo` (see - gitlink:git-mailinfo[1]). + linkgit:git-mailinfo[1]). -3, --3way:: When the patch does not apply cleanly, fall back on @@ -61,15 +61,15 @@ default. You could use `--no-utf8` to override this. -b, --binary:: Pass `--allow-binary-replacement` flag to `git-apply` - (see gitlink:git-apply[1]). + (see linkgit:git-apply[1]). --whitespace=