mirror of
https://gerrit.googlesource.com/git-repo
synced 2024-12-21 07:16:21 +00:00
repo info findRemoteLocalDiff use short branch
When running repo info -d an error would be thrown saying: fatal: bad revision 'refs/remotes/m/refs/heads/master..' Using the short branch name here instead, like 'refs/remotes/m/master..' resolves this issue. Signed-off-by: Daniel Kutik <daniel.kutik@lavawerk.com> Change-Id: I50ea92c45c011b2c3e3a63803decb88e7837a380 Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/266578 Reviewed-by: Mike Frysinger <vapier@google.com>
This commit is contained in:
parent
dbfbcb14c1
commit
e7082ccb54
@ -16,7 +16,7 @@
|
||||
|
||||
from command import PagedCommand
|
||||
from color import Coloring
|
||||
from git_refs import R_M
|
||||
from git_refs import R_M, R_HEADS
|
||||
|
||||
|
||||
class _Coloring(Coloring):
|
||||
@ -127,7 +127,10 @@ class Info(PagedCommand):
|
||||
if not self.opt.local:
|
||||
project.Sync_NetworkHalf(quiet=True, current_branch_only=True)
|
||||
|
||||
logTarget = R_M + self.manifest.manifestProject.config.GetBranch("default").merge
|
||||
branch = self.manifest.manifestProject.config.GetBranch('default').merge
|
||||
if branch.startswith(R_HEADS):
|
||||
branch = branch[len(R_HEADS):]
|
||||
logTarget = R_M + branch
|
||||
|
||||
bareTmp = project.bare_git._bare
|
||||
project.bare_git._bare = False
|
||||
|
Loading…
Reference in New Issue
Block a user