cd
into a deliveroo repo directory- run:
curl -s https://gist.githubusercontent.com/scott-ad-riley/0d774a70452bd5bb118638b7dbed0176/raw/dde71f9489f2d01a6f048ec58d6f7f4cf93f63ce/prepare-commit-msg.rb > ./.git/hooks/prepare-commit-msg
- That downloads the script in this gist (I promise) and puts it in a
./git/hooks/prepare-commit-msg
file - You'll need to run this for each repo
N.B. It currently throws and prevents you from committing if your commit message starts with a different ticket number to the branch you're on (i.e. if you pass it PAY-1234: some message and you're on a branch that doesn't start PAY-1234/...
)