1 |
On martedì 25 gennaio 2022 18:00:30 CET Michael Orlitzky wrote: |
2 |
> Can I request that Bug: and Closes: tags in our commits automatically |
3 |
> CC the committer on the bug that is modified? |
4 |
> |
5 |
> Use case: I often fix (sci-*) bugs that I'm not CCed on, and a user |
6 |
> will leave a comment like "it still crashes on x86" that I never see. |
7 |
> Of course, I could manually CC myself on every bug. But that will send |
8 |
> everyone an extra email, and is forgettable. Plus, avoiding the manual |
9 |
> step is kind of the point of the automation, right? |
10 |
> |
11 |
> One potential downside is that the commit author could wind up CCed |
12 |
> twice via an alias, but that could be solved with a sufficiently clever |
13 |
> implementation. Or disregarded if it's not too much of a problem in |
14 |
> practice; the bugs will usually be closed, after all. |
15 |
|
16 |
While it does not hurt implement an hook I'd say that: |
17 |
|
18 |
- CI already cc'es the author of the commit when he breaks a package or introduces a QA |
19 |
issue. |
20 |
This is related to a new bugs and, obviously, does not cover your use-case. |
21 |
|
22 |
- If you are CC'ed by the hook and you are part of the alias that is the assignee of the bug, |
23 |
you will receive two emails unless the hook integrates the alias. |
24 |
|
25 |
- Based on the previous point, I'd suggest to use a wrapper if you want to be cc'ed on the |
26 |
bug you are resolving: |
27 |
|
28 |
|
29 |
#!/bin/bash |
30 |
|
31 |
BUG="${1}" |
32 |
COMMIT_MESSAGE="${2}" |
33 |
|
34 |
repoman commit -c "${BUG}" -m "${COMMIT_MESSAGE}" && bugz --key "${APIKEY}" |
35 |
modify --add-cc name@g.o "${BUG}" |
36 |
|
37 |
|
38 |
Agostino |