Hello,
I am trying to set up a merge check script that will reuse an existing pre-commit git hook in my repository(from the ".git/hooks" folder) and if the hook returns the ok status I will allow the merge.
From my understanding the ".git/hooks" folder is only local so I will upload the hook somewhere in the repo if that is needed.
My main goal is to check if that hook returns OK when someone is trying to merge into the main branch because that will be easier for newcomers that do not have the hook setup locally.
Also some way of checking the hook on the server side when they are pushing would help.
Is there any way to achieve this behavior using Scriptrunner or maybe other basic git functionalities?
Thank you!