tag 559549 + patch thanks On Sun, 06 Dec 2009 13:45:37 +0100, Patrick Schoenfeld wrote:
> > I'm not sure I understand the concern. nmudiff is already adding +patch > > tags, why can't it add also +pending upon request? For instance, when I > > do DELAYED uploads, I always hand-patch the "tags +" line by adding > > "pending", nmudiff can do that for me (in fact, it would even be a sane > > default when --delay is passed). > > What tagpending additionally does is (I believe) checking which bugs > > should not be tagged pending as they already are. nmudiff should ignore > > that, as the mail is going to be sent to the BTS anyhow. > Yep. That was the case I'm thinking about, but probably you are right. > So no objections from my side anymore ;) Find attached a quick patch that adds "+ pending" if the bug is not yet tagged pending and $NMUDIFF_DELAY != 0. Additionally I've moved a few lines around in order to add "thanks" and the bcc addresses only when $TAGS is not empty after the loop. (What's still a bit weird is the amount of whitespace at the top of the mail but well ...) Cheers, gregor -- .''`. http://info.comodo.priv.at/ -- GPG Key IDs: 0x00F3CFE4, 0x8649AA06 : :' : Debian GNU/Linux user, admin, & developer - http://www.debian.org/ `. `' Member of VIBE!AT, SPI Inc., fellow of FSFE | http://got.to/quote/ `- NP: Dave Brubeck: Theme From Mr. Broadway
--- /usr/bin/nmudiff 2009-12-01 06:20:23.000000000 +0100
+++ /home/gregoa/bin/nmudiff 2009-12-27 02:49:00.000000000 +0100
@@ -305,21 +305,19 @@
exit 1
fi
+TO_ADDRESSES_SENDMAIL=""
+TO_ADDRESSES_MUTT=""
+BCC_ADDRESS_SENDMAIL=""
+BCC_ADDRESS_MUTT=""
+TAGS=""
if [ "$NMUDIFF_NEWREPORT" = "yes" ]; then
TO_ADDRESSES_SENDMAIL="[email protected]"
TO_ADDRESSES_MUTT="[email protected]"
- BCC_ADDRESS_SENDMAIL=""
- BCC_ADDRESS_MUTT=""
TAGS="Package: $SOURCE
Version: $OLDVERSION
Severity: normal
-Tags: patch"
+Tags: patch pending"
else
- TO_ADDRESSES_SENDMAIL=""
- TO_ADDRESSES_MUTT=""
- BCC_ADDRESS_SENDMAIL="[email protected]"
- BCC_ADDRESS_MUTT="-b [email protected]"
- TAGS=""
for b in $CLOSES; do
TO_ADDRESSES_SENDMAIL="$TO_ADDRESSES_SENDMAIL,
[email protected]"
@@ -328,11 +326,19 @@
TAGS="$TAGS
tags $b + patch"
fi
+ if [ "$NMUDIFF_DELAY" != "0" ] && [ "`bts select bugs:$b tag:pending`" != "$b" ]; then
+ TAGS="$TAGS
+tags $b + pending"
+ fi
done
TO_ADDRESSES_SENDMAIL=$(echo "$TO_ADDRESSES_SENDMAIL" | tail -n +2)
- TAGS=$(echo "$TAGS" | tail -n +2)
- TAGS="$TAGS
+ if [ "$TAGS" != "" ]; then
+ TAGS=$(echo "$TAGS" | tail -n +2)
+ TAGS="$TAGS
thanks"
+ BCC_ADDRESS_SENDMAIL="[email protected]"
+ BCC_ADDRESS_MUTT="-b [email protected]"
+ fi
fi
TMPNAM="$( tempfile )"
signature.asc
Description: Digital signature
