juhp / fbrnch

Tool to update fedora packages branches
https://hackage.haskell.org/package/fbrnch
GNU General Public License v2.0
23 stars 3 forks source link

Custom commit messages #38

Open eclipseo opened 1 year ago

eclipseo commented 1 year ago

Hi,

I'm not really keen on the current commit messages, either for import or updates. They are not capitalised and they don't include the correct format for bug numbers (Close: rhbz#XXXXXX, Closes: rhbz#XXXXXX, Fix: rhbz#XXXXXX, Fixes: rhbz#XXXXXX). How can I customize them?

juhp commented 1 year ago

Hi, thanks for reporting this feedback

Do you have any concrete examples? I take it you are not using fbrnch commit? On the plus side fbrnch will add mentioned bugs to Bodhi when pushing a manual update (ie not for rawhide/branched)

Let me think a little on this, certainly I agree the Closes/Fixes keywards are important I guess. Capitalizing is probably more readable too, I suppose.

eclipseo commented 1 year ago

No I was importing a new package.

fbrnch import -F golang-github-hashicorp-hc-install

And I got that commit message:

https://src.fedoraproject.org/rpms/golang-github-hashicorp-hc-install/c/8136ca061e5ff24737f2fdb40a52085da888172f?branch=rawhide

import #2224864

What I usually do is :

git commit -m "Initial import" -m "Close: rhbz#2225225"

That format will automatically close the bug for updates too. So I wish to be able to customize them.

I haven't tested fbrnch update yet but from the code it seemed similar.

juhp commented 10 months ago

Are these bz keywords documented somewhere? Or where are they implemented? (I tried grepping bodhi but nothing)

juhp commented 10 months ago

I would like to understand how those keywords work in Fedora infra before proceeding

juhp commented 10 months ago

Carl George pointed me at https://fedora-infra.github.io/bodhi/7.2/user/automatic_updates.html#fedora-linux-specific-regex

juhp commented 10 months ago

Let me start addressing this with a small tweak then, which should help automatic updates for %autochangelog.

For non-%autochangelog this would require an appropriate %changelog message of course

juhp commented 10 months ago

I released 1.3.3 with this tweak so autoupdates should now close Review Request bugs at least when using autochangelog.