Checking commit messages in TortoiseHG

I wonder if it is possible in TortoisHG, as well as in TortoiseSVN, to check whether the message about the commission contains a problem identifier? In TortoiseSVN, you can set the bugtraq properties on the repo to open a dialog box and warn if the identifier has not been enabled, and I'm looking for a way to do the same (still need to be able to check this, just show a warning that the identifier is not included and can interrupt the commit if you want).

Thanks in advance Jonas H.

+4
source share
3 answers

As far as I know, nothing like this is possible right in TortoiseHG.
But TortoiseHG is just a GUI for Mercurial, and in Mercurial you can do such things with hooks.

See chapter 10 in the HG book for a general description of what hooks are and how they work:
Handling Repository Events with Interceptors

In this chapter there is even a specific example that rolls back a commit if it does not contain an error identifier .

+1
source

This dialog in the TortoiseHg 2.4 settings looks the way you want:

enter image description here

+1
source

I only know about setting issue.linkmandatory = True , which forcibly enters a link to the problem specified in issue.regex and issue.link for each commit.

0
source

All Articles