adr/skills/adr/SKILL.md
Create, list, supersede, deprecate, or audit Architecture Decision Records (MADR 4.0). Handles auto-numbering, directory detection, and cross-reference consistency. For quick stale-reference scans in markdown, use adr-ref-guard instead.
npx skillsauth add musingfox/cc-plugins adrInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Manage Architecture Decision Records using MADR 4.0 format with full cross-reference consistency enforcement.
Do NOT use when:
Auto-detect the ADR directory by scanning (in order):
docs/decisions/docs/adr/adr/decisions/Use Glob: {docs/decisions,docs/adr,adr,decisions}/[0-9][0-9][0-9][0-9]-*.md
If no directory found and user wants to create an ADR, ask which location to use.
---
status: proposed
date: YYYY-MM-DD
decision-makers: ""
---
Status values: proposed | accepted | deprecated | superseded by [ADR-NNNN](file)
NNNN-kebab-case-title.mdRead ${CLAUDE_PLUGIN_ROOT}/skills/adr/references/madr-template.md for the full MADR 4.0 template.
[0-9][0-9][0-9][0-9]-*.md files, determine next number${CLAUDE_PLUGIN_ROOT}/skills/adr/references/madr-template.md and apply with today's dateWhen no ADRs exist yet, read ${CLAUDE_PLUGIN_ROOT}/skills/adr/references/bootstrap-adr.md and create 0000-use-madr.md from its content, replacing {today} with the current date.
[0-9][0-9][0-9][0-9]-*.md in the ADR directorystatus, date) and first # heading| # | Title | Status | Date |
|------|------------------------|----------------------------|------------|
| 0000 | Use MADR 4.0 for ADRs | [accepted] | 2025-03-16 |
| 0001 | Use PostgreSQL | [superseded -> ADR-0003] | 2025-01-10 |
| 0002 | REST API Design | [accepted] | 2025-02-01 |
| 0003 | Use SQLite | [accepted] | 2025-03-15 |
0001 -> 0003Total: 4 | accepted: 2 | proposed: 0 | superseded: 1 | deprecated: 0This is the most critical operation. Execute ALL steps in order.
0003-*.md)Supersedes [ADR-NNNN](old-adr-file.md)Edit the old ADR file:
status to: superseded by [ADR-{new}]({new-adr-file.md})---, before the first heading:
> **SUPERSEDED**: This ADR has been superseded by [ADR-NNNN: New Title](new-adr-file.md). The decision described here is no longer in effect.
Search the ENTIRE repository for references to the old ADR using a 4-layer pattern:
Layer 1 — Filename: Grep for the old ADR filename
pattern: 0003-use-postgresql\.md
Layer 2 — ADR-N marker: Grep for ADR number in various formats
pattern: ADR[-\s]?0*3\b
(matches: ADR-3, ADR-0003, ADR 3, ADR-03)
Layer 3 — Markdown link: Grep for links containing the ADR number
pattern: \[.*?\]\(.*?0003-.*?\)
Layer 4 — Title substring: Grep .md files only for the old ADR's title
pattern: "Use PostgreSQL" (exact title, .md files only to reduce noise)
Exclude from all searches:
node_modules/, .git/, target/, dist/, build/, vendor/, .agents/Group matches into categories and present as table:
| Category | Files Found | Default Action |
|----------|-------------|----------------|
| Other ADR files | 0005-api-versioning.md | Auto-update |
| Documentation (non-ADR .md) | docs/setup.md | Auto-update |
| Source code comments | src/db.ts | Add (superseded) marker |
| Config files | config.yaml | Skip — manual review |
Use AskUserQuestion per category for the user to choose:
(superseded — see ADR-NNNN) after referenceFor auto-update targets:
superseded by references, update markdown linksFor add notice targets:
(superseded — see [ADR-NNNN](path/to/new-adr.md)) after each referenceSupersession Complete:
Created: ADR-0007: Use SQLite (0007-use-sqlite.md)
Superseded: ADR-0003: Use PostgreSQL (0003-use-postgresql.md)
Cross-Reference Updates:
Auto-updated: 3 files
Notice added: 1 file
Skipped: 1 file (manual review needed)
- config/database.yaml (line 12)
Simpler than supersession — no replacement ADR is created.
status to: deprecated---:
> **DEPRECATED**: This ADR is deprecated. The decision described here is no longer relevant.
Run the same 4-layer search as supersede Step 4, but use add notice as the default action for all categories:
(deprecated) after each reference foundPresent findings and ask user per category whether to add notice or skip.
Deprecation Complete:
Deprecated: ADR-0005: Legacy Auth (0005-legacy-auth.md)
Cross-Reference Updates:
Notice added: 2 files
Skipped: 1 file (manual review needed)
Run these validation checks and report grouped by severity:
.md files for links matching NNNN-*.md, verify target exists.status or date fields in YAML frontmatter.Output format:
ADR Consistency Check:
ERRORS (2):
[broken-link] docs/setup.md:15 links to 0009-missing.md — file does not exist
[circular] ADR-0003 -> ADR-0007 -> ADR-0003
WARNINGS (1):
[stale-ref] README.md:42 references ADR-0003 (superseded by ADR-0007)
INFO (1):
[gap] Missing numbers: 0004, 0006
Summary: 2 errors, 1 warning, 1 info
If errors or warnings found, suggest running supersede or manual fixes.
data-ai
Unified entry point for Obsidian daily-note captures and long-form notes. Triggers on "記一下 / log / 紀錄 / capture this / 寫到 journal" (→ cap mode) and "建立筆記 / new note / 寫一份筆記 / create a note on" (→ note mode). Also via `/obw:cap` and `/obw:note`. Requires `.obsidian.yaml`.
tools
Use the `gog` CLI to operate Google Workspace — Gmail (read/search/send/labels/drafts), Calendar (events/RSVP/freebusy/focus-time/out-of-office), and Drive (list/search/upload/ download/share/move). Triggers on any Gmail, inbox, email, calendar, agenda, meeting, schedule, RSVP, Drive, Google Doc/Sheet/Slides, file share, or upload/download request.
documentation
Interactively create .obsidian.yaml for a project and install starter templates (task / doc / adr) into the vault's Templates folder. Skips templates that already exist; never overwrites.
tools
Manage project hook-guard installation — set up, diagnose, or update Claude Code hooks, git pre-commit, and commit-msg scripts with security checks, code-quality gates, and CLAUDECODE skip logic. Triggers on "set up hooks", "configure pre-commit", "add linting hooks", "initialize hook-guard", "check hooks", "hook doctor", "verify hook setup", "troubleshoot hooks", "update hooks", "regenerate hooks", "sync hooks with current tools", or similar requests.