On Tue, May 21, 2024 at 09:36:05AM +0200, Tobias Burnus wrote: > Jakub Jelinek wrote: > > On Mon, May 20, 2024 at 08:31:02AM +0200, Tobias Burnus wrote: > > > Hmm, there were now two daily bumps: [...] I really wonder why. > > Because I've done it by hand. > > Okay, that explains it. > > I still do not understand why it slipped through at the first place; I tried > old versions down to r12-709-g772e5e82e3114f and it still FAIL for the > invalid commit ("ERR: cannot find a ChangeLog location in message"). > > Thus, I wonder whether the commit hook is active at all?!?
They are. But https://github.com/AdaCore/git-hooks/blob/master/hooks/updates/__init__.py#L836 with https://github.com/AdaCore/git-hooks/blob/master/hooks/updates/commits.py#L230 bypasses all commits which contain just 3 magic words in a row. And because that part is owned by AdaCore hooks, not the GCC customizations, not sure what to do about that. > > I have in ~gccadmin a gcc-changelog copy and adjusted update_version_git > > script which doesn't use contrib/gcc-changelog subdirectory from the > > checkout it makes but from the ~gccadmin directory, > [...] > > I'm already using something similar in > > my hack (just was doing it for even successful commits, but I think your > > patch is better). > > And, I think best would be if update_version_git script simply > > accepted a list of ignored commits from the command line too, > > passed it to the git_update_version.py script and that one > > added those to IGNORED_COMMITS. > > Updated version: > > * Uses my diagnostic > > * Adds an -i/--ignore argument for commits. Permits to use '-i hash1 -i > hash2' but also '-i hash1,hash2' or '-i "hash1 hash2' > > * I changed the global variable to lower case as Python's style guide states > that all uppercase variables is for constants. > > * The '=None' matches one of the current usages (no argument passed); hence, > it is now explicit and 'pylint' is happy. > > OK for mainline? Yes, thanks. > PS: I have not updated the hashes. If needed/wanted, I leave that to you, > Jakub. Once some commit is ignored, we won't be processing it anymore, so I think the -i option is all we need. Jakub