vulkro install-hook
Install or update git hooks that run Vulkro before a commit or push.
install-hook manages a marked block inside the hook file, so
re-running it is idempotent and it composes with an existing husky or
hand-written hook instead of refusing. With no selector, it installs
both hooks.
The generated hook keeps your code on the machine: your source, file paths, and findings are never sent anywhere.
- pre-commit runs the new-findings gate against
HEAD.vulkro gatemakes no outbound request at all. - pre-push runs a fast high-confidence quick scan of
src. The scan path can send the usage heartbeat (at most once every 24 hours, on a background thread, and it never blocks or delays the push).
If the hook must be network-silent, set VULKRO_OFFLINE=1 (or
VULKRO_NO_HEARTBEAT=1) in the environment the hook runs in.
Bypass once with VULKRO_SKIP_HOOKS=1.
Usage
vulkro install-hook [FLAGS]
Flags
| Flag | Description |
|---|---|
--pre-commit | Manage the pre-commit hook. |
--pre-push | Manage the pre-push hook (the last gate before code leaves the machine). |
--uninstall | Remove the Vulkro-managed block instead of installing it. |
--force | Replace the whole hook file with just the Vulkro block. The default composes with any existing content. |
Exit codes
0hook(s) installed, updated, or removed.2not in a git repo, or a write failure.
The generated hook itself returns 1 on findings at commit or push time.
Examples
# Install both hooks, composing with anything already there.
vulkro install-hook
# Only the pre-push gate.
vulkro install-hook --pre-push
# Remove the Vulkro block from both hooks.
vulkro install-hook --uninstall
# Skip the hook for one commit.
VULKRO_SKIP_HOOKS=1 git commit -m "wip"
Related
vulkro gate- the new-findings gate the pre-commit hook runs.vulkro scan- the full pipeline.vulkro guard- the in-loop gate for AI-assisted editing.