I am new to writing git hooks.
Here's what I'd like to do:
Once a branch XYZ is merged into master (on remote); write a hook that changes the status of a JIRA ticket associated with branch XYZ from "pending approval" to "prod ready".
My research into this so far:
- I've figured JIRA Rest API can allow me to do this (using
- Git hooks can be written in many languages
(and I figured python would be the easiest for me as I am well
versed in it) .
- I should be implementing either
git hook to do this. The hook would essentially get the
Branch name (my branch name is enforced to be the same as Jira name)
; and then do a POST using JIRA API to change the status as
- There is such a thing as "web hooks" that are also
an option for folks using github. My repo at the moment is github
deployed into the organization..but we might be moving toward
bitbucket; in which case I am concerned that webhooks will no longer be useful...
- Is it possible to accomplish this task?
- If so, what githook should I
- Should I be using web hooks or
- Can anyone point me to an example to get me started?