Afara CLI

The pre-push hook

afara init installs a pre-push hook so that work does not reach the remote without Afara having seen it.

When a push is checked. Only branches whose name contains a ticket key are checked. Afara recognises:

Branch Ticket
chu-1-onboarding CHU-1
alice/PAY-981-refunds PAY-981
418-fix-totals (GitHub’s own format) #418
issue-418, gh-418, fix/issue_418 #418

Common words are not mistaken for ticket prefixes: release-2024, hotfix-3, feature-12, v-2 and dependency-bot branches are not checked, and version numbers such as lodash-4.17.21 are not read as tickets.

What is checked. For each branch being pushed, Afara looks at the commits that are new to the remote, ignoring merge commits, commits at or before the baseline, and commits that touch no source files. The push goes through if all of them have been generated. Otherwise it is held back:

Good to know:


← Afara CLI documentation