@cofoundr/init
v1.5.0
Published
Universal installer for the CoFoundr starter kit. Drops a tool-agnostic spec-driven workspace into any project — Claude Code, Cursor, Windsurf, Cline, Codex, Aider, Copilot, Gemini.
Maintainers
Readme
@cofoundr/init
Universal installer for the CoFoundr spec-driven starter kit. Runs in any project, drops a tool-agnostic .cofoundr/ workspace and an AGENTS.md at the root, then installs per-tool shims for the AI tools you actually use.
Why this exists
The CoFoundr starter kit was originally a Claude Code plugin. That left out everyone using Cursor, Windsurf, Cline, Codex, Aider, GitHub Copilot, Gemini, and the rest of the modern AI-coding stack. This package fixes that — one canonical workflow, every tool.
┌──────────────────────┐
│ .cofoundr/ │ ← single source of truth
│ constitution.md │
│ memory/ │
│ specs/ │
│ commands/ │
│ agents/ │
└──────────┬───────────┘
│
▼
┌──────────┬───────────┬──────┬────────┬──────────┬──────────┬──────────┬─────────┐
│ Claude │ Cursor │ Wind │ Cline /│ Codex │ Aider │ GitHub │ Gemini │
│ Code │ │ surf │ Roo │ CLI │ │ Copilot │ CLI │
└──────────┴───────────┴──────┴────────┴──────────┴──────────┴──────────┴─────────┘
(per-tool shim files written by adapters)
and AGENTS.md at the repo root
(read by ~25+ other agents natively)Install + run
# Greenfield or existing project — interactive picker
npx @cofoundr/init init
# Non-interactive, install everything
npx @cofoundr/init init --all-tools --yes
# Pick specific tools
npx @cofoundr/init init --tools claude-code,cursor,codex
# Map an existing codebase before specing
npx @cofoundr/init onboard
# Refresh after a CoFoundr upgrade
npx @cofoundr/init sync
# Health check
npx @cofoundr/init doctor
# What's supported, what's detected here
npx @cofoundr/init toolsSupported tools
| Tool | Tool reads |
|------------------------|------------------------------------------------------------------|
| Claude Code | .claude/commands/, .claude/agents/, CLAUDE.md |
| Cursor | .cursor/rules/cofoundr.mdc |
| Windsurf | .windsurfrules, .windsurf/rules/cofoundr.md |
| Cline / Roo Code | .clinerules/cofoundr.md |
| OpenAI Codex CLI | AGENTS.md, .codex/instructions.md |
| Aider | AGENTS.md, .aider.conf.yml |
| GitHub Copilot | .github/copilot-instructions.md |
| Gemini CLI | GEMINI.md |
AGENTS.md is the open-standard universal context file (agents.md) read by 20+ additional agents — Junie, Jules, Goose, opencode, Zed, Warp, Devin, Amp, Augment, Kilo, Phoenix, Roo, Ona, Factory, and more — so even tools without a dedicated adapter pick up the workspace automatically.
What gets installed
Always — universal source of truth
AGENTS.md # universal context, read by ~25 tools
.cofoundr/
├── manifest.json # version stamp + selected tools
├── README.md
├── constitution.md # the project's binding rules
├── memory/
│ ├── project.md
│ ├── decisions.md # append-only decision log
│ └── knowledge.md # patterns and gotchas
├── specs/ # feature- and phase-level specs
├── commands/ # canonical workflow commands (read by all tools)
├── agents/ # canonical agent definitions
└── templates/ # editable scaffoldsPer tool — only the shims you asked for
The adapter for each tool writes a thin file that points the tool back to .cofoundr/. There is one source of truth — the per-tool files are routers.
Workflow commands
Every command works the same in every tool — the user types /cofoundr:<name> (or cofoundr <name>) and the tool reads .cofoundr/commands/<name>.md and follows it.
| Category | Command | What it does |
|-------------|------------------------|--------------|
| Session | resume | First command of every session — recap, confirm, then code |
| Planning | quick-brief | 4-question fast pass; produces product.md |
| | new-project | Full pipeline — planning, research, six-file spec |
| | plan | Standalone planning conversation (15-item rubric) |
| | next | Planning driver — does the next unblocked thing |
| | new-feature | Add a feature to an existing project |
| SDD | constitution | Establish or amend the binding rules |
| | specify | Produce or refresh the formal spec (project / feature / phase) |
| | tasks | Break a phase or feature into ordered, copy-paste tasks |
| | implement | Execute the next task with HALT enforcement |
| Brownfield | onboard | Map an existing codebase. Drafts a back-filled spec |
| | document | Generate or refresh living docs from code |
| | audit | Drift, dead surfaces, security smells, constitution violations |
| Guardrails | scope-guard | Check a proposed change vs. product.md non-goals |
| | rules-check | Audit current work vs. rules.md tiers |
| | review | 22-check spec quality audit |
| Comms | translate | Plain-English companion (docs/plan-for-humans.md) |
| Setup | setup-skills | Install recommended skill packs |
Safety
- Idempotent.
initandsyncskip files that already exist unless you pass--force. Files inside.cofoundr/memory/,.cofoundr/specs/,.cofoundr/reports/, and your code are never overwritten by the CLI. - No source modification. The CLI only writes to
.cofoundr/,AGENTS.md, and the per-tool shim files. It does not touchsrc/,app/,lib/, etc. - Dry run. Pass
--dry-runto see what would change without writing. - Reversible.
cofoundr removestrips the shims (preserves your specs and memory).--hardwipes.cofoundr/entirely.
Development
The package uses a monorepo layout. The canonical content lives at the repo root (cofoundr-system/) and is bundled into packages/cofoundr-cli/content/ at publish time via prepack. In dev mode the CLI reads directly from cofoundr-system/.
# Run from a checkout
node packages/cofoundr-cli/bin/cofoundr.mjs init --cwd /tmp/test-project --all-tools --yes
# Smoke test
node packages/cofoundr-cli/test/smoke.mjsLicense
See the LICENSE at the repository root.
