/claude-leverage:dynamic-check [--source agents|readme|all] [--timeout N] [--json] [--fail-on fail]from claude-leverage
Verifies that a repo's declared build/test/lint commands (from AGENTS.md or README) actually run, with preview, explicit confirmation, denylist tripwire, and timeouts. Complements /repo-doctor's read-only checks.
Ships in claude-leverage. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Answers the one question /repo-doctor's read-only layers cannot: do the
commands this repo declares actually run? Collects commands from the
repo's own docs, shows them to the user with source attribution, and — only
after explicit confirmation — executes them sequentially and reports
pass/fail/timeout per command.
This is the only skill in the stack that executes repo-declared commands. Its safety contract is ADR 0013: four independent consent layers, fail-closed everywhere.
Note the frontmatter deliberately pre-approves only git rev-parse.
Every declared command goes through the session's normal permission flow —
in an interactive session each un-allowlisted command produces the standard
prompt. That platform prompt is a consent layer, not an obstacle; do not
ask the user to pre-allow Bash(*) to avoid it.
-p run, no answer
path), print the parsed command table, state
dynamic-check: no interactive confirmation available — nothing executed, and stop with exit 0. Silence never executes (ADR 0013).Resolve repo root. git rev-parse --show-toplevel. If not in a git
repo, STOP: "dynamic-check needs a git checkout".
Collect declared commands. Parse fenced ```bash/sh/console
blocks (strip $ prompts, skip comment/blank lines) under headings
matching build|test|lint|check|quickstart|install|setup|usage
(case-insensitive) — in root AGENTS.md first, then README.md
(--source agents|readme|all, default all, narrows this). Attribute
every command to its source file:line. Cap at 10 commands and report
anything dropped by the cap.
Denylist screen. Mark — do not run, report as
⛔ skipped: denylisted — any command matching: sudo, rm ,
curl … | sh/wget … | bash, git push, docker … --privileged,
> /dev/, chmod -R, npm publish, twine upload, cargo publish,
gem push. The denylist is a tripwire, not a sandbox, and it
matches single lines only. Known bypasses the preview-reader's mental
model must include: indirection via make targets or npm scripts;
a download-then-execute pair split across two innocent-looking lines
(curl -o s.sh … then sh s.sh); obfuscated payloads
(bash -c "$(… | base64 -d)"). When the parsed list contains such a
pattern — a command executing or sourcing a file a previous command
fetched or wrote, or any encoded/eval-style construction — annotate
that row ⚠️ review closely: <reason> in the preview so the user's
consent is informed. The platform permission layer and the user's
judgment at the preview are the real gates.
Preview + confirm (non-skippable). Print the full table (command,
source file:line, denylist status) and ask the user to confirm the
batch, offering per-command exclusion. On "no": stop, nothing executed.
Non-interactive: fail closed per Hard rules.
Execute. Sequentially, in declaration order, from the repo root.
Wrap each with timeout <N> (default 300 s; --timeout N overrides;
if timeout is unavailable on this platform, note it and rely on the
Bash tool's own timeout). Capture exit code + last ~5 lines of output.
Stop after 3 failures and mark the rest (stopped early: 3 failures).
Report (format verbatim):
# Dynamic check — <repo> — <YYYY-MM-DD> (advisory)
| Command | Source | Result |
|---|---|---|
| `pytest tests/ -v` | AGENTS.md:98 | ✅ pass (41 s) |
| `make lint` | README.md:23 | ❌ fail — `make: *** No rule to make target 'lint'` |
| `sudo make install` | README.md:31 | ⛔ skipped: denylisted (`sudo`) |
❌ rows include the last ~5 output lines in a collapsed block. Per ❌, say which fix the output suggests: the doc is wrong (update the doc) or the project is broken (fix the project).
--json / exit code. --json emits
{"commands": [{"cmd", "source", "status": "pass|fail|timeout|skipped", "exit", "tail"}], "summary": {"pass": N, "fail": N, "skipped": N}}.
--fail-on fail → exit 4 if any fail/timeout. Default exit 0.
/repo-doctor's score or levels — advisory only (ADR 0012).Same SKILL.md ships to Codex. Commands run under the configured sandbox
profile — recommend workspace-write with network off (see
/codex-sandbox) unless installs are being validated. The confirm step is
plain conversation and works in both tools.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub filip-podstavec/claude-leverage --plugin claude-leverage16 skills in this plugin
/adr-newUSE WHEN a load-bearing architectural decision is being made in conversation (database / framework / auth model / integration choice, or explicit rejection of an alternative) — one likely to be re-litigated in 6 months without the rationale. Bootstraps a numbered MADR ADR in `docs/adr/`, asks for context + decision + alternatives, updates the index. Immutable status once accepted. See `docs/adr/README.md` for the convention; full Do/Don't list in this SKILL body.
/arch-mapUSE WHEN setting up a repo for AI-first work, after a major directory restructure, or when an agent needs structured answers like "which modules are stable?" / "what's the public surface of X?" that the prose AGENTS.md doesn't give cheaply. Bootstraps or refreshes `architecture.yml` at repo root — machine-readable module metadata (path / role / stability / public_surface / depends_on / paired_with / owners). Hand-curated; the skill drafts, the user confirms. See ADR 0005 for why this file lives at root and why YAML over JSON.
/codex-sandboxUSE WHEN setting up Codex CLI in a project, tightening sandbox for prod/CI, or when user asks about Codex permissions. Interactive helper for per-project `.codex/config.toml`: `dev` / `prod` / `custom` profiles, idempotent via markers, preserves unmanaged config below the block. Codex-only artifact.
/conventions-initUSE WHEN setting up a repo for AI-first work (after /init-repo), or when the context-surface hook should start feeding repo conventions to agents before edits. Drafts `conventions.yml` at repo root: per-kind casing (inferred from the code), a vague-name denylist seed, directory roles, and a hand-filled house-rules block. Idempotent — never overwrites a populated file; re-running prints suggested additions for manual merge. Read-only on code; never invents house rules. After writing, run /refresh-context-map so the hook picks it up.
/explain-diffUSE WHEN about to open a PR, when teammate asks "what's in this diff?", or when returning to a branch and needing self-orientation. Three modes: `--for pr|review|self`. Reads `git diff HEAD` (or passed range), returns 3–5 bullet plain-English narration. Read-only — defers security/test concerns to other skills.
/glossary-initUSE WHEN setting up a repo for AI-first work, when an agent hallucinates domain term meaning, or when user asks to bootstrap / extend the repo's domain glossary. Surfaces candidate terms by identifier frequency, asks the user for 1-sentence definitions, writes `GLOSSARY.md` at repo root. Idempotent — re-running adds new terms without overwriting existing ones. Read-only on code; never invents domain meaning. Full Do/Don't list in this SKILL body. See ADR 0005 for why this file lives at root.
Other plugins' skills for the same job