Repository with lots of example branches to demo the CaptainHook functionality. Clone the repository and then activate the Captain.
$ git clone git@github.com:captainhook-go/examples.git & cd examples
$ captainhook install -f
Checkout the first branch.
$ git switch action/git-notify-checkout-first
If you update your working directory with merge
, rebase
, checkout
and any commit contains git-notify:
followed by a message the message will be displayed.
$ git switch action/git-notify-checkout-second
Checkout the demo branch.
$ git switch action/inject-key-from-branch-PROJ-12345
Add a new file, and commit it to the repository
$ touch demo
$ git add demo
$ git commit
Your editor should already contain the PROJ-12345
issue key extracted from the branch name.
Start by checking out the starting branch.
$ git switch action/prevent-push-fixup+squash
Merge a prepared fixup! commit.
$ git merge action/prevent-push-fixup+squash-fix
If you try to push the changes the push should fail.
$ git push