mirror of
https://gerrit.googlesource.com/git-repo
synced 2024-12-21 07:16:21 +00:00
Fast-forward a fully merged topic branch during 'repo sync'
Instead of trying to rebase the changes on a topic branch that has been fully merged into the upstream branch we track, we should just fast-forward the topic branch to the new upstream revision. This way the branch doesn't try to rewrite commits that are already merged in the upstream. Signed-off-by: Shawn O. Pearce <sop@google.com>
This commit is contained in:
parent
df830f1238
commit
a54c527ae9
@ -563,6 +563,15 @@ class Project(object):
|
||||
_info("[%s] Consider merging or rebasing the"
|
||||
" unpublished commits.", self.name)
|
||||
return True
|
||||
else:
|
||||
# We can fast-forward safely.
|
||||
#
|
||||
try:
|
||||
self._FastForward(rev)
|
||||
except GitError:
|
||||
return False
|
||||
self._CopyFiles()
|
||||
return True
|
||||
|
||||
if merge == rev:
|
||||
try:
|
||||
|
Loading…
Reference in New Issue
Block a user