diff options
author | Junio C Hamano <gitster@pobox.com> | 2021-02-25 16:43:32 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-02-25 16:43:32 -0800 |
commit | cadae717d557840d3566b7c0fc2003046e08c88f (patch) | |
tree | f6c95ee9d4216724dab20c6b17992965d423abe1 | |
parent | Merge branch 'dl/doc-config-camelcase' (diff) | |
parent | mergetools/vimdiff: add vimdiff1 merge tool variant (diff) | |
download | tgif-cadae717d557840d3566b7c0fc2003046e08c88f.tar.xz |
Merge branch 'sh/mergetools-vimdiff1'
Mergetools update.
* sh/mergetools-vimdiff1:
mergetools/vimdiff: add vimdiff1 merge tool variant
-rw-r--r-- | mergetools/vimdiff | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/mergetools/vimdiff b/mergetools/vimdiff index abc8ce4ec4..96f6209a04 100644 --- a/mergetools/vimdiff +++ b/mergetools/vimdiff @@ -15,6 +15,17 @@ merge_cmd () { "$LOCAL" "$MERGED" "$REMOTE" fi ;; + *vimdiff1) + "$merge_tool_path" -f -d \ + -c 'echon "Resolve conflicts leftward then save. Use :cq to abort."' \ + "$LOCAL" "$REMOTE" + ret="$?" + if test "$ret" -eq 0 + then + cp -- "$LOCAL" "$MERGED" + fi + return "$ret" + ;; *vimdiff2) "$merge_tool_path" -f -d -c 'wincmd l' \ "$LOCAL" "$MERGED" "$REMOTE" @@ -52,7 +63,7 @@ exit_code_trustable () { list_tool_variants () { for prefix in '' g n; do - for suffix in '' 2 3; do + for suffix in '' 1 2 3; do echo "${prefix}vimdiff${suffix}" done done |