Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1198)

Unified Diff: git_cl.py

Issue 16211005: Allow --3way to be passed to `git apply` via `git cl patch`. (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@master
Patch Set: make 3way default Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: git_cl.py
diff --git a/git_cl.py b/git_cl.py
index 01fe0767afdb4691e94a121b001e30d50b2239ba..082b4ebff80196f73684b3b512a2f09691f1e5ad 100755
--- a/git_cl.py
+++ b/git_cl.py
@@ -1692,7 +1692,8 @@ def CMDpatch(parser, args):
parser.add_option('-f', action='store_true', dest='force',
help='with -b, clobber any existing branch')
parser.add_option('--reject', action='store_true', dest='reject',
- help='allow failed patches and spew .rej files')
+ help='failed patches spew .rej files rather than '
+ 'attempting a 3-way merge')
parser.add_option('-n', '--no-commit', action='store_true', dest='nocommit',
help="don't commit after patch applies")
(options, args) = parser.parse_args(args)
@@ -1750,6 +1751,8 @@ def CMDpatch(parser, args):
cmd = ['git', '--no-pager', 'apply', '--index', '-p0']
if options.reject:
cmd.append('--reject')
+ else:
+ cmd.append('--3way')
ncarter (slow) 2013/06/07 19:42:00 FYI: this option doesn't seem to exist in git vers
M-A Ruel 2013/06/07 19:44:45 Trent, can you revert or fix? We have to support s
try:
subprocess2.check_call(cmd, stdin=patch_data, stdout=subprocess2.VOID)
except subprocess2.CalledProcessError:
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698