agentsclimarketplace

Hook discipline

Skill jackjconner/agent-harness/skills/hook-discipline

Use when a pre-commit, pre-push, or CI hook fails. Fix the underlying issue rather than bypassing the hook. Never use --no-verify or equivalent without explicit user approval.From its SKILL.md

Install
npx -y skills add jackjconner/agent-harness --skill hook-discipline

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

2 things to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

1.7 KB, as published. Nobody here has run it

Hook discipline

Hooks exist because past-you (or past-team) needed them. A failing hook is a signal, not an obstacle.

The rule

When a hook fails:

  1. Read the failure output.
  2. Fix the underlying issue.
  3. Re-stage, re-commit. Hooks may auto-fix on first run (formatters, trailing whitespace) — re-add and retry.

Never use any of:

  • git commit --no-verify / -n
  • git commit --no-gpg-sign
  • git -c commit.gpgsign=false commit
  • git push --no-verify
  • Removing or commenting out hook entries to "make it work"

Why

Suppression is the path of least resistance under time pressure. Removing the path forces real fixes. Every bypass leaves a landmine for the next agent or human who runs the suite cleanly.

If the hook is genuinely wrong for this codebase, raise it with the user as a config change. Don't bypass.

After a hook failure: NEW commit, not amend

If a pre-commit hook fails, the commit did not happen. Running git commit --amend after a hook failure modifies the previous commit, which can destroy unrelated work. Instead:

  1. Fix the issue.
  2. Re-stage the files (git add <paths>).
  3. Run git commit fresh.

When the user explicitly authorizes a bypass

Some workflows have legitimate one-off bypasses (rebase recovery, a known-broken hook the user is patching). The user must say so explicitly for that commit. Authorization doesn't carry forward.

Exit condition

The hook passes cleanly on a fresh run, OR the user has explicitly approved a one-time bypass for this commit.

Keep looking

Skills are one crate of 607,533. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.