On martedì 25 gennaio 2022 18:00:30 CET Michael Orlitzky wrote:
> Can I request that Bug: and Closes: tags in our commits automatically
> CC the committer on the bug that is modified?
> 
> Use case: I often fix (sci-*) bugs that I'm not CCed on, and a user
> will leave a comment like "it still crashes on x86" that I never see.
> Of course, I could manually CC myself on every bug. But that will send
> everyone an extra email, and is forgettable. Plus, avoiding the manual
> step is kind of the point of the automation, right?
> 
> One potential downside is that the commit author could wind up CCed
> twice via an alias, but that could be solved with a sufficiently clever
> implementation. Or disregarded if it's not too much of a problem in
> practice; the bugs will usually be closed, after all.

While it does not hurt implement an hook I'd say that:

- CI already cc'es the author of the commit when he breaks a package or 
introduces a QA 
issue.
This is related to a new bugs and, obviously, does not cover your use-case.

- If you are CC'ed by the hook and you are part of the alias that is the 
assignee of the bug, 
you will receive two emails unless the hook integrates the alias.

- Based on the previous point, I'd suggest to use a wrapper if you want to be 
cc'ed on the 
bug you are resolving:


#!/bin/bash

BUG="${1}"
COMMIT_MESSAGE="${2}"

repoman commit -c "${BUG}" -m "${COMMIT_MESSAGE}" && bugz --key "${APIKEY}" 
modify --add-cc n...@gentoo.org "${BUG}"


Agostino

Reply via email to