Skip to content
youdede

Debug artifact guard

DevelopmentHookv1.0.0

A deterministic Claude Code PreToolUse commit gate that reads bounded staged blobs, and the working-tree files a commit would take, and rejects unresolved merge markers, standalone debugger breakpoints, and focused JavaScript, TypeScript, or Ruby tests without duplicating secret scanning.

Runs on

Scope
$npx @youdede/toolkit add debug-artifact-guard --target claude-code

What it does

Block commits containing high-confidence debugger statements or focused tests.

When it fires

  • pre-commit
  • review

How it behaves

Read bounded staged blobs and the working-tree files a commit would take, and deterministically reject high-confidence debugging residue.

It does not scan for credentials, dependency risk, lint failures, ordinary logging, or incomplete TODO comments.

It does not remove a breakpoint, unfocus a test, resolve a conflict, or modify the Git index.

It does not accept an inline suppression comment, project file, environment variable, or agent-authored change as approval.

Configuration

targets/claude-code/debug-artifact-guard.mjsnode · read-only

Version
1.0.0
Requires
Shell command guard
Licence
RiskThis automatic gate blocks commits containing high-confidence debugger statements or focused tests; a false denial can interrupt legitimate work, but it does not execute the blocked action.
Medium
ModeHow it works: fixed rules, model instructions, or both.
Deterministic only
Behaviour
Enforces, blocks on violation
On failure
Denies and blocks
LatencyTo block commits containing high-confidence debugger statements or focused tests, the entrypoint may run a bounded local subprocess before returning.
Bounded
Data retentionWhether data remains after use and who manages its storage.
Not retained

Often used with

All in Development