summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: a9786bb)
raw | patch | inline | side by side (parent: a9786bb)
author | Alexander Gavrilov <angavrilov@gmail.com> | |
Mon, 8 Sep 2008 16:37:11 +0000 (20:37 +0400) | ||
committer | Shawn O. Pearce <sop@google.com> | |
Fri, 12 Sep 2008 15:09:09 +0000 (08:09 -0700) |
Tools like rerere leave files marked as conflicts in the index,
while actually resolving them in the working copy. Also, some
people like to use an external editor to resolve conflicts.
This patch restores functionality previously removed in
commit 617ceee653 by adding a new context menu item.
It still ensures that the user does not stage conflicting files
accidentally by clicking on the icon instead of the name.
Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com>
Tested-by: Johannes Sixt <johannes.sixt@telecom.at>
Signed-off-by: Shawn O. Pearce <sop@google.com>
while actually resolving them in the working copy. Also, some
people like to use an external editor to resolve conflicts.
This patch restores functionality previously removed in
commit 617ceee653 by adding a new context menu item.
It still ensures that the user does not stage conflicting files
accidentally by clicking on the icon instead of the name.
Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com>
Tested-by: Johannes Sixt <johannes.sixt@telecom.at>
Signed-off-by: Shawn O. Pearce <sop@google.com>
git-gui.sh | patch | blob | history | |
lib/mergetool.tcl | patch | blob | history |
diff --git a/git-gui.sh b/git-gui.sh
index 9fbee24c2edf46e616cbc950c7233bfb2286654b..1044ab9a736fa390b6a6d4053783eeed2759b1a0 100755 (executable)
--- a/git-gui.sh
+++ b/git-gui.sh
-command {merge_resolve_one 1}
lappend diff_actions [list $ctxmmg entryconf [$ctxmmg index last] -state]
$ctxmmg add separator
+$ctxmmg add command \
+ -label [mc "Stage Working Copy"] \
+ -command {merge_resolve_one 0}
+lappend diff_actions [list $ctxmmg entryconf [$ctxmmg index last] -state]
+$ctxmmg add separator
create_common_diff_popup $ctxmmg
proc popup_diff_menu {ctxm ctxmmg x y X Y} {
diff --git a/lib/mergetool.tcl b/lib/mergetool.tcl
index 79c58bc7bc8c79a13acd1370b184a530d67eaa20..dd2315b858ce76ed457f523c6085f363ce91bff1 100644 (file)
--- a/lib/mergetool.tcl
+++ b/lib/mergetool.tcl
global current_diff_path
switch -- $stage {
+ 0 { # Stage without confirmation, to minimize
+ # disruption of the rerere workflow
+ merge_add_resolution $current_diff_path
+ return
+ }
+
1 { set target [mc "the base version"] }
2 { set target [mc "this branch"] }
3 { set target [mc "the other branch"] }