aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Copeland <ben.copeland@linaro.org>2016-10-26 09:13:45 +0100
committerBen Copeland <ben.copeland@linaro.org>2016-10-27 15:07:52 +0100
commit89a55b58fddb3eeb948b4b3f057c04e1bc3dd395 (patch)
treeaed0758564451ccf3e3a852765d85b2cfb2d6d4f
parentddee70f66f4739c8c1c02a64d0fb6c3692decb70 (diff)
downloadlinaro-git-tools-89a55b58fddb3eeb948b4b3f057c04e1bc3dd395.tar.gz
bugzilla: fix rev issue
"fatal: Invalid revision range" appears when a user pushes a new repo, this fix ignores new repos so the user isn't presented with an error. Change-Id: I65bfdec465d9edaa0181632c4bc7653f6a7890d4
-rwxr-xr-xbugzilla-post-receive.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/bugzilla-post-receive.py b/bugzilla-post-receive.py
index 552cf20..a9413c3 100755
--- a/bugzilla-post-receive.py
+++ b/bugzilla-post-receive.py
@@ -89,8 +89,8 @@ def update_if_bug(log, rev):
if changed:
add_comment(generate_comment(rev), int(bug))
-
-revs = get_git_revlist()
-for rev in revs:
- commit_log = get_commit_log(rev)
- update_if_bug(commit_log, rev)
+if OLDREV != 0000000000000000000000000000000000000000:
+ revs = get_git_revlist()
+ for rev in revs:
+ commit_log = get_commit_log(rev)
+ update_if_bug(commit_log, rev)