Available in
Marketplaces, most starred first
Tags
Add to README
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
By karanb192v1.0.2MITIn 1 marketplace
Warns you before retrying an approach you already reverted, and asks before an edit brings back a reverted hunk. Hooks mine your local transcripts into a per-repo registry and claim no network calls.
Trending plugins
7-day copy clicks
Claude loads one when your task matches it, or you run it by name.
1 caution to review before installing
A hook runs when Claude writes or edits files
Static checks of hooks, mods, MCP servers and commands. Not a security audit.
1 marketplace, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Remembers approaches you tried and reverted (with reason and estimated token cost) and warns before you retry them.
On Stop, SubagentStop, and PreCompact the hook mines the session transcript for approaches you TRIED and then REVERTED or ruled out, recording each with its reason, date, and an estimated token cost of the detour into a per-repo registry. On UserPromptSubmit it keyword-matches the new prompt against that registry and injects a "DEAD END: you already tried this" card via additionalContext. On PreToolUse (Edit|Write) it returns an ask decision when the pending diff would reintroduce a previously-reverted hunk. Extraction is deterministic (revert-signal heuristics plus tool-result scanning); an optional model pass is never required and never runs in tests.
/plugin marketplace add karanb192/claude-code-hooks # once per machine
/plugin install dead-end-registry@claude-code-hooks
Restart Claude Code, done. (Or from a shell: claude plugin install dead-end-registry@claude-code-hooks.)
| Event | Runs | What happens |
|---|---|---|
| UserPromptSubmit | sync | Matches the prompt against the registry; injects a "you already tried this" warning card when it hits a recorded dead end. |
| PreToolUse (Edit|Write) | sync | Returns permission decision ask when the diff would reintroduce a previously-reverted hunk. |
| Stop | async (zero added latency) | Mines the transcript for abandoned approaches into the per-repo registry. |
| SubagentStop | async (zero added latency) | Same mining, at subagent stop. |
| PreCompact | async (zero added latency) | Same mining, before context is compacted away. |
/dead-end-registry:dead-ends renders this repo's recorded dead ends, newest first, each with the date tried, why it was walked back, and the estimated token cost of the detour.
No environment variables. Behavior is governed by in-source constants with these defaults:
MAX_AGE_DAYS = 60: entries older than this are ignored on read and dropped at compaction.MAX_CARD_ENTRIES = 3: entries shown in an injected card.MAX_REGISTRY_ENTRIES = 500: entries scanned on prompt-submit.MAX_CODE_LINES = 80 / MAX_CODE_CHARS = 4000: truncation caps on stored code snapshots.USD_PER_TOKEN = 0.000009: rough blended rate for the headline cost figure.State is stored per-project (keyed by a hash of the repo path) under ~/.claude/dead-end-registry/<repo>.jsonl, outside the repo so nothing is accidentally committed.
Recorded: short summaries and truncated code snapshots of reverted approaches, plus reason, date, and an estimated token cost, all mined from your local transcripts. Everything stays on your machine: the hook makes no network calls.
/plugin uninstall dead-end-registry@claude-code-hooks
Built from public signals: copy clicks on this site, GitHub stars and activity, the README and the manifest. Not a security audit or an endorsement.
npx claudepluginhub karanb192/claude-code-hooks --plugin dead-end-registryPlugins from other owners that cover similar ground