vulkro install-hook
Installs git hooks that run Vulkro before a commit or push.
vulkro install-hook # both hooks
vulkro install-hook --pre-push # only the pre-push hook
VULKRO_SKIP_HOOKS=1 git commit -m "wip" # skip the hooks once
The hook file gets a marked Vulkro block, so re-running is safe and it works alongside husky or a hand-written hook.
- pre-commit runs
vulkro ctx check --staged(call sites left on an old signature, removed names still used, syntax errors), then the new-findings gate againstHEAD. The ctx step warns unless you pass--block-on-ctx-check. - pre-push runs a quick, high-confidence scan of
src.
Your source, paths and findings never leave the machine. Set VULKRO_OFFLINE=1 in the hook's environment for a fully network-silent hook. Without a licence the hooks print a notice ending in vulkro: license_required and let the git operation continue.
Flags
| Flag | Description |
|---|---|
--pre-commit | Manage only the pre-commit hook. |
--pre-push | Manage only the pre-push hook. |
--uninstall | Remove the Vulkro block. |
--force | Replace the whole hook file with the Vulkro block. |
--block-on-ctx-check | Make the pre-commit ctx check block the commit. |
Exit codes
0 hooks installed, updated or removed. 2 not a git repo, or a write failure. The hook itself returns 1 on findings.
See also: vulkro gate, vulkro guard.