aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKonstantin Ryabitsev <konstantin@linuxfoundation.org>2021-10-07 11:14:17 -0400
committerKonstantin Ryabitsev <konstantin@linuxfoundation.org>2021-10-07 11:14:17 -0400
commitfdc9d1a11c091ebf17efb8a80f8b04c23e1ae80c (patch)
treed5c5f067714ea854b5a316caaa782a7dc61929be
parente21e357733ccaa1e29374dd99295f542409e1820 (diff)
downloadkorg-helpers-fdc9d1a11c091ebf17efb8a80f8b04c23e1ae80c.tar.gz
git-patchwork-bot: use shortened refname in notices
The refname is always going to be a branch, so remove "refs/heads/" in all notices being sent. Signed-off-by: Konstantin Ryabitsev <konstantin@linuxfoundation.org>
-rwxr-xr-xgit-patchwork-bot.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/git-patchwork-bot.py b/git-patchwork-bot.py
index bb07b3c..f87af6e 100755
--- a/git-patchwork-bot.py
+++ b/git-patchwork-bot.py
@@ -587,7 +587,7 @@ def send_summary(serieslist, committers, to_state, refname, pname, rs, hs):
params = {
'newstate': to_state,
'treename': rs['treename'],
- 'refname': refname,
+ 'refname': refname.replace('refs/heads/', '', 1),
'summary': '\n'.join(summary),
'total': count,
'signature': CONFIG['templates']['signature'],
@@ -743,7 +743,7 @@ def notify_submitters(serieslist, committers, refname, revs, pname, rs, hs):
params = {
'reqtype': reqtype,
'treename': rs['treename'],
- 'refname': refname,
+ 'refname': refname.replace('refs/heads/', '', 1),
'committer': committer,
'sentdate': str(headers.get('date')),
'trimquote': '\n'.join(trimquote),