Skip to content

Contributing

Contributions are welcome — whether it’s a bug fix, a new feature, or an improvement to the documentation. This guide covers everything you need to get started.

  1. Clone the repository

    Terminal window
    git clone https://github.com/senivel/domain-context-claude.git
    cd domain-context-claude
  2. Link skills and hooks for development

    Terminal window
    node bin/install.js --link

    Creates symlinks from ~/.claude/ to your local source files. Edits to skills, hooks, and templates are immediately live — no re-install needed. Use --link --local for project-scoped installs.

  3. Run the context validator

    Terminal window
    bash tools/validate-templates.sh .

    Checks that .context/MANIFEST.md is in sync with the files on disk — catches broken links, orphans, and stale entries.

  4. Test the full npm package flow

    Terminal window
    npm pack && npx ./domain-context-cc-*.tgz

    Builds a tarball and installs from it, simulating what users experience with npx domain-context-cc.

commands/dc/ Six slash commands (/dc:init, /dc:explore, etc.)
hooks/ Session-start and edit-time lifecycle hooks
agents/ Domain validator subagent
rules/ Path-specific editing guidance for .context/ files
templates/ Scaffolding files copied by /dc:init
tools/ Standalone validation script
bin/ npm installer entry point
docs/ Documentation site (Astro/Starlight)

This project produces configuration files only — markdown skills, Node.js hooks, and shell scripts. There is no runtime library code.

Markdown files with YAML frontmatter (name, description, allowed-tools) followed by <objective>, <execution_context>, and <process> sections. All skill names use the dc: prefix.

Node.js scripts that read JSON from stdin and write JSON to stdout. Hooks must be timeout-safe and must always exit 0 on error — they should never block the user’s workflow.

Plain markdown with {placeholder} tokens. Templates are copied to the target project by /dc:init and filled in during scaffolding.

Markdown files in .claude/rules/ with a globs frontmatter field for path matching. Rules provide editing guidance when Claude Code modifies files inside .context/.

  • kebab-case for all file names
  • dc: prefix for all skill names
  • No runtime dependencies — Node.js built-ins only
  • Fork the repository and branch from main
  • Use imperative mood in commit messages (e.g., “add freshness check hook”, not “added” or “adding”)
  • Context changes (.context/ files) go through the same review process as code
  • Open a PR with a clear description of what changed and why