summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMike Frysinger <vapier@google.com>2021-05-01 00:45:19 -0400
committerMike Frysinger <vapier@google.com>2021-05-02 00:05:49 +0000
commit3b038cecc4ff189f9f7263adc5f8bf1ae62f3380 (patch)
tree5d23b7568c142e8506543f21b51da85b9681502c
parenta590e640a69b1a6ba448600cbc7f3be31178bc92 (diff)
downloadgit-repo-3b038cecc4ff189f9f7263adc5f8bf1ae62f3380.tar.gz
upload: include the project in error messages
When running upload across multiple projects, include the project in any error messages that come up. This lets users figure out where the problem might be. Change-Id: I09470c9a1b512baf910d6d97b747816d1a6f3a87 Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/304783 Reviewed-by: Raman Tenneti <rtenneti@google.com> Tested-by: Mike Frysinger <vapier@google.com>
-rw-r--r--subcmds/upload.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/subcmds/upload.py b/subcmds/upload.py
index 50dccc52..a23755c7 100644
--- a/subcmds/upload.py
+++ b/subcmds/upload.py
@@ -520,10 +520,10 @@ Gerrit Code Review: https://www.gerritcodereview.com/
520 avail = [up_branch] 520 avail = [up_branch]
521 else: 521 else:
522 avail = None 522 avail = None
523 print('repo: error: Unable to upload branch "%s". ' 523 print('repo: error: %s: Unable to upload branch "%s". '
524 'You might be able to fix the branch by running:\n' 524 'You might be able to fix the branch by running:\n'
525 ' git branch --set-upstream-to m/%s' % 525 ' git branch --set-upstream-to m/%s' %
526 (str(cbr), self.manifest.branch), 526 (project.relpath, str(cbr), self.manifest.branch),
527 file=sys.stderr) 527 file=sys.stderr)
528 else: 528 else:
529 avail = project.GetUploadableBranches(branch) 529 avail = project.GetUploadableBranches(branch)