I am trying to add the commit message hook to accept the following inputs in Gitlab:
bug 12345
bug #12345
BUG # 12345
Bug#12345
bug12345
The number 12345 should be changed to anything which is either a 5 digit or 6 digit number (not less than that, not greater than that)
It should get started from Bug, BUG or bug.
It should not have any other character than # or space or blank that too just between the numbers and string "Bug/bug/BUG"
I need help with this ASAP.
I have tried to achieve this by :
^(BUG|bug|Bug)\ |#\d+
but this is not giving the desired output. I am taking reference from :
Thanks a lot in advance.