summaryrefslogtreecommitdiffstats
path: root/project.py
diff options
context:
space:
mode:
authorMike Frysinger <vapier@google.com>2020-03-22 12:15:20 -0400
committerMike Frysinger <vapier@google.com>2020-03-23 00:27:52 +0000
commit915fda130efa14b9314b500d122f9af707518508 (patch)
tree054e7a0322bbd7927cfe57792dea28f6e855839c /project.py
parentea43176de0a46eadb12be814517532a13eec8b1d (diff)
downloadgit-repo-915fda130efa14b9314b500d122f9af707518508.tar.gz
download: support -x when cherry-picking
This is a pretty common option for people to want too use, so include it as a pass-thru option when cherry-picking. Bug: https://crbug.com/gerrit/9418 Change-Id: I2a24c1ed7544541719caa4d3c0574347a151a1b0 Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/259853 Reviewed-by: David Pursehouse <dpursehouse@collab.net> Tested-by: Mike Frysinger <vapier@google.com>
Diffstat (limited to 'project.py')
-rw-r--r--project.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/project.py b/project.py
index a58af4ff..d35ad52d 100644
--- a/project.py
+++ b/project.py
@@ -2681,10 +2681,12 @@ class Project(object):
2681 if self._allrefs: 2681 if self._allrefs:
2682 raise GitError('%s checkout %s ' % (self.name, rev)) 2682 raise GitError('%s checkout %s ' % (self.name, rev))
2683 2683
2684 def _CherryPick(self, rev, ffonly=False): 2684 def _CherryPick(self, rev, ffonly=False, record_origin=False):
2685 cmd = ['cherry-pick'] 2685 cmd = ['cherry-pick']
2686 if ffonly: 2686 if ffonly:
2687 cmd.append('--ff') 2687 cmd.append('--ff')
2688 if record_origin:
2689 cmd.append('-x')
2688 cmd.append(rev) 2690 cmd.append(rev)
2689 cmd.append('--') 2691 cmd.append('--')
2690 if GitCommand(self, cmd).Wait() != 0: 2692 if GitCommand(self, cmd).Wait() != 0: