{"id":49147269,"url":"https://github.com/mikestankavich/claude-spec-workflow","last_synced_at":"2026-04-22T04:30:53.052Z","repository":{"id":318770532,"uuid":"1074351542","full_name":"mikestankavich/claude-spec-workflow","owner":"mikestankavich","description":"A structured workflow process for Claude Code with slash commands","archived":false,"fork":false,"pushed_at":"2026-03-24T11:16:16.000Z","size":512,"stargazers_count":3,"open_issues_count":16,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-25T11:55:29.499Z","etag":null,"topics":["agentic-ai","automation","code-"],"latest_commit_sha":null,"homepage":"https://trakrf.id/claude-spec-workflow","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mikestankavich.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-11T16:12:52.000Z","updated_at":"2026-03-24T11:16:19.000Z","dependencies_parsed_at":"2025-10-15T13:27:50.926Z","dependency_job_id":"f4af233c-98c8-490a-bb96-273b03a86aef","html_url":"https://github.com/mikestankavich/claude-spec-workflow","commit_stats":null,"previous_names":["trakrf/claude-spec-workflow","mikestankavich/claude-spec-workflow"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/mikestankavich/claude-spec-workflow","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mikestankavich%2Fclaude-spec-workflow","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mikestankavich%2Fclaude-spec-workflow/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mikestankavich%2Fclaude-spec-workflow/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mikestankavich%2Fclaude-spec-workflow/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mikestankavich","download_url":"https://codeload.github.com/mikestankavich/claude-spec-workflow/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mikestankavich%2Fclaude-spec-workflow/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32120831,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-22T00:31:26.853Z","status":"online","status_checked_at":"2026-04-22T02:00:05.693Z","response_time":58,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["agentic-ai","automation","code-"],"created_at":"2026-04-22T04:30:52.340Z","updated_at":"2026-04-22T04:30:53.045Z","avatar_url":"https://github.com/mikestankavich.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Claude Spec Workflow\n\nSpecification-driven development commands for Claude Code by [TrakRF](https://trakrf.id)\n\nCreated by Mike Stankavich ([@mikestankavich](https://github.com/mikestankavich))\n\n## What is this?\n\nA specification-driven development workflow for Claude Code that helps you ship production-ready features with confidence.\n\n### Origin Story\n\nThis project builds on excellent work from two pioneers in AI-assisted development:\n\n**Cole Medin's [Context Engineering](https://github.com/coleam00/context-engineering-intro)** taught us the power of comprehensive context and validation loops. His methodology showed how structured context dramatically improves AI output quality and prevents the \"big bang integration\" failures we've all experienced.\n\n**Ryan Carson's [3-File PRD System](https://creatoreconomy.so/p/full-tutorial-a-proven-3-file-system-to-vibe-code-production-apps-ryan)** ([repo](https://github.com/snarktank/ai-dev-tasks)) demonstrated the value of progress tracking and clarifying questions. His approach to breaking down work and maintaining visible state throughout development inspired our specification lifecycle.\n\n### Our Contribution\n\nWe loved what both Cole and Ryan created, and found ourselves naturally combining techniques from both approaches. This project synthesizes those ideas into a **single, opinionated workflow** that:\n\n- **Starts with clarity** (spec-first approach)\n- **Plans with questions** (mandatory clarification gates)\n- **Builds with validation** (continuous testing, not cleanup)\n- **Ships with confidence** (comprehensive pre-release checks)\n\nThe key difference: where their approaches offer flexibility and exploration, we provide a **Rails-style opinionated process**. We believe the best creativity happens within constraints, and that AI-assisted development benefits from clear guard rails and validation gates.\n\nThink of it as \"the best of both worlds, with training wheels\" - structured enough to prevent common pitfalls, flexible enough to adapt to your stack.\n\n## Features\n\n- 🎯 **Conversation to Spec** - Extract formal specifications from exploratory chats\n- 🤔 **Interactive Planning** - Get clarifying questions before implementation\n- ✅ **Continuous Validation** - Test and fix as you build, not after\n- 📊 **Pre-release Checks** - Comprehensive validation before creating PRs\n- 🚀 **Clean Shipping** - Automated cleanup and git workflow\n- 🔧 **Stack Agnostic** - Works with TypeScript, Python, Go, and more via presets\n\n## Prerequisites\n\n**All Platforms:**\n- Git installed\n- Bash shell\n\n**Platform-Specific Setup:**\n- **macOS/Linux**: Native bash support ✓\n- **Windows**: Requires Git Bash or WSL2\n  - [Install Git for Windows](https://git-scm.com/download/win) (includes Git Bash)\n  - [Install WSL2](https://docs.microsoft.com/en-us/windows/wsl/install)\n\n**Why bash?** This is a bash-based workflow system. Claude Code executes all commands through bash, and the workflow depends on bash tools (git, grep, find, etc.) for every operation from installation to validation to shipping. Whether your project uses TypeScript, Python, Go, or Rust - you're still running those commands through bash. Git Bash or WSL2 provides this bash environment.\n\n**GitHub Authentication (for automatic PR creation):**\n\nThe `/csw:ship` command can create pull requests automatically if you authenticate with GitHub using any of these methods:\n\n1. **GitHub CLI** (Recommended):\n   ```bash\n   gh auth login\n   ```\n\n2. **Personal Access Token**:\n   ```bash\n   export GH_TOKEN=your_token_here\n   # Get token: https://github.com/settings/tokens\n   # Scopes needed: repo, workflow\n   ```\n\n3. **gh config**: If gh CLI is installed, `/csw:ship` will use stored credentials automatically\n\n**Without authentication**: `/csw:ship` will provide manual PR creation instructions.\n\n## Installation\n\n```bash\n# Clone the repository\ngit clone https://github.com/trakrf/claude-spec-workflow\ncd claude-spec-workflow\n\n# Install commands globally\n./csw install\n\n# Initialize a project with default preset (TypeScript + React + Vite)\ncsw init /path/to/your/project\n\n# Or initialize with a specific preset\ncsw init /path/to/your/project python-fastapi\n```\n\n**Windows users**: Run these commands in Git Bash or WSL2 terminal.\n\n## Quick Start\n\n1. **Create a specification**\n   ```bash\n   mkdir -p spec/my-feature\n   cp spec/template.md spec/my-feature/spec.md\n   # Edit spec.md with your requirements\n   ```\n\n   See `examples/profile-feature/spec.md` for a complete example.\n\n2. **Generate implementation plan**\n   ```\n   /csw:plan spec/my-feature/spec.md\n   ```\n   Claude will ask clarifying questions to ensure a solid plan.\n\n3. **Build with validation**\n   ```\n   /csw:build spec/my-feature/\n   ```\n   Implementation happens with continuous testing and progress tracking.\n\n4. **Check readiness**\n   ```\n   /csw:check\n   ```\n   Comprehensive validation ensures your code is PR-ready.\n\n5. **Ship it**\n   ```\n   /csw:ship spec/my-feature/\n   ```\n   Prepares for pull request with validation and git workflow.\n\n## Stack Configuration\n\nThe workflow adapts to your project's tech stack through `spec/stack.md`, which is created automatically when you initialize a project.\n\n### Available Presets\n\n**Single-Stack:**\n- `typescript-react-vite` - React + TypeScript + Vite + npm (default)\n- `nextjs-app-router` - Next.js App Router + TypeScript\n- `python-fastapi` - Python + FastAPI + pytest\n- `go-standard` - Go with standard library or frameworks\n\n**Monorepo:**\n- `monorepo-go-react` - Go backend + React/Vite frontend + TimescaleDB\n\n### Using a Preset\n\nPresets are automatically applied during project initialization:\n\n```bash\n# Default preset (typescript-react-vite)\ncsw init /path/to/your/project\n\n# Specific preset\ncsw init /path/to/your/project python-fastapi\n```\n\n### Changing Your Stack\n\nTo change your stack configuration, you have two options:\n\n1. **Edit spec/stack.md directly** - Customize validation commands to match your setup\n2. **Re-run csw init with a different preset** - Overwrites with new preset (prompts for confirmation)\n\n```bash\n# From your project directory, switch to a different preset\ncsw init . go-standard\n```\n\n### Custom Stack Configuration\n\nIf your stack doesn't match any preset, use `templates/stack-template.md` as a guide:\n\n```bash\n# Copy the template to see the format\ncp templates/stack-template.md spec/stack.md\n```\n\nThen edit `spec/stack.md` with your validation commands:\n\n```markdown\n# Stack: My Custom Stack\n\n\u003e **Package Manager**: your-package-manager\n\u003e **Test Runner**: your-test-runner\n\n## Lint\n\\```bash\nyour-lint-command --fix\n\\```\n\n## Typecheck\n\\```bash\nyour-typecheck-command\n\\```\n\n## Test\n\\```bash\nyour-test-command\n\\```\n\n## Build\n\\```bash\nyour-build-command\n\\```\n```\n\nThe commands `/csw:build`, `/csw:check`, and `/csw:ship` automatically read and use these commands.\n\n**Built a great stack definition?** Share it with the community! If you've created a stack configuration for a framework or toolchain not yet in our presets, consider contributing it back. See [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines on submitting new presets.\n\n### Monorepo Support\n\nFor monorepos with multiple tech stacks (like Go backend + React frontend):\n\n1. **Initialize with monorepo preset:**\n   ```bash\n   # From your project directory\n   csw init . monorepo-go-react\n   ```\n\n2. **Add workspace metadata to specs:**\n   ```markdown\n   ## Metadata\n   **Workspace**: backend\n   **Type**: feature\n   ```\n\n3. **Commands auto-detect workspace:**\n   ```bash\n   /csw:build spec/auth/       # Detects backend workspace from spec\n   /csw:check                  # Validates all workspaces (database → backend → frontend)\n   /csw:check backend          # Validates only backend workspace (faster feedback)\n   ```\n\nThe system uses workspace-specific validation commands from `spec/stack.md`:\n- Backend changes use commands from `## Workspace: backend` section\n- Frontend changes use commands from `## Workspace: frontend` section\n- Database changes use commands from `## Workspace: database` section\n\n## Commands\n\n| Command | What It Does | When to Use |\n|---------|--------------|-------------|\n| `/csw:spec` | **Define WHAT** - Gather requirements and desired outcomes | After exploring bugs, reading tickets, or discussing ideas |\n| `/csw:plan` | **Define HOW** - Generate detailed implementation approach | When you have clear requirements in spec.md |\n| `/csw:build` | **Execute** - Implement the plan with continuous validation | After reviewing and approving the plan |\n| `/csw:check` | **Validate** - Comprehensive pre-ship audit (optional) | For detailed readiness report or pre-ship review |\n| `/csw:ship` | **Finalize** - Commit, push, create PR (runs /csw:check automatically) | When ready to merge |\n| `/csw:cleanup` | **Clean up** - Post-merge branch cleanup + issue check | After merging PR |\n\nAll commands also work via CLI: `csw spec`, `csw plan`, `csw build`, `csw check`, `csw ship`, `csw cleanup`.\n\n## Feature Lifecycle\n\nCSW supports a complete feature development cycle:\n\n([csw:spec] | `\u003cspec\u003e`) → csw:plan → csw:build → [csw:check] → csw:ship → `\u003cmerge\u003e` → [csw:cleanup] → repeat\n\n**Legend**:\n- [brackets] - Optional CSW command\n- `\u003cangle brackets\u003e` - Manual/external action\n- (A | B) - Choose either approach\n\n```mermaid\nflowchart LR\n    Start([Start Feature]) --\u003e Spec{Create Spec}\n    Spec --\u003e|/csw:spec| AutoSpec[spec/feature/]\n    Spec --\u003e|Write manually| ManualSpec[spec/feature/spec.md]\n    AutoSpec --\u003e Plan\n    ManualSpec --\u003e Plan\n    Plan[/csw:plan] --\u003e Build[/csw:build]\n    Build --\u003e Check{/csw:check?}\n    Check --\u003e|Optional| CheckRun[Validate]\n    Check --\u003e|Skip| Ship\n    CheckRun --\u003e Ship\n    Ship[/csw:ship] --\u003e Merge(\u003cmerge PR\u003e)\n    Merge --\u003e Cleanup{/csw:cleanup?}\n    Cleanup --\u003e|Optional| CleanupRun[Branch + issue cleanup]\n    Cleanup --\u003e|Skip| Next\n    CleanupRun --\u003e Next([Next Feature])\n    Next --\u003e Spec\n```\n\n**The cycle**:\n1. **([csw:spec] | `\u003cspec\u003e`)** - Create feature spec (tool-assisted or manual)\n2. **csw:plan** - Generate implementation plan\n3. **csw:build** - Implement the feature\n4. **[csw:check]** - Validate (optional: tests, lint, types, build)\n5. **csw:ship** - Create PR\n6. **`\u003cmerge\u003e`** - Merge the PR (manual)\n7. **[csw:cleanup]** - Post-merge housekeeping (branch cleanup, issue check)\n8. **repeat** - Start next feature (spec cleanup happens automatically at start of `/csw:spec`)\n\n## Workflow vs History\n\nCSW focuses on *current* work, not completed work.\n\n- **spec/** - Workspace for active/planned features (transient)\n- **Git + GitHub PRs** - Full history and record of shipped features\n- **log.md** - Local proof that `/build` succeeded\n\nComplete a feature? `/csw:ship` creates the PR. After merging, run `/csw:cleanup` to handle git housekeeping (delete branch, prune refs, check issues). The spec/ scaffolding is automatically cleaned up at the start of the next `/csw:spec` cycle — it's already preserved in git history.\n\n## Workflow Philosophy\n\n1. **Context is King** - Provide comprehensive context for better AI execution\n2. **Clarify Before Coding** - Interactive planning prevents false starts\n3. **Validate Continuously** - Fix issues immediately, not in a big cleanup\n4. **Ship Clean** - Comprehensive checks ensure professional results\n\n## Optimizing Command Flow\n\n### Understanding the Contract Model\n\nCSW commands read from disk artifacts (spec.md, plan.md, etc.) which enables:\n- **Resumable workflows** - Pick up hours or days later\n- **Clear contracts** - Each stage produces a complete artifact for the next\n- **Team collaboration** - Multiple people can work on different stages\n\n### When to Clear Context\n\nEach workflow stage has different context requirements:\n\n| Transition | Context Strategy | Why |\n|------------|------------------|-----|\n| /spec → /plan | **Keep context** | Natural flow from exploration to planning |\n| /plan → /build | **Clear context** | plan.md is complete contract; tests completeness |\n| /build → /check | **Clear context** | Independent review with fresh perspective |\n| /check → /ship | **Clear context** | Mechanical operation from artifacts |\n\n**Rapid flow example**:\n```bash\n# Exploration and specification\n/csw:spec my-feature\n\n# Planning (keeps context from /csw:spec conversation)\n/csw:plan\n\n# Clear context, build from plan.md\n/clear\n/csw:build\n\n# Skip /csw:check, go straight to ship (it re-validates anyway)\n/csw:ship\n```\n\n### When to Skip /csw:check\n\n**/csw:build already validates everything** before allowing commits:\n- Lint must be clean\n- Types must be correct\n- Tests must pass\n- Build must succeed\n\n**/csw:ship runs /csw:check automatically** before creating PR, so in rapid flow you can safely skip it.\n\n**Run /csw:check explicitly when:**\n- You want a detailed readiness report before deciding to ship\n- Time has passed since /csw:build (hours/days)\n- You made manual edits after /csw:build completed\n- Someone else is reviewing your work\n\n**Bottom line**: Trust /csw:build's validation. In rapid flow, skip /csw:check and go straight to /csw:ship - it will re-validate everything anyway.\n\n## Complexity Assessment \u0026 Scope Protection\n\nThe `/csw:plan` command includes automatic scope analysis to prevent scope creep and protect you from common pitfalls.\n\n### The Problem We've All Experienced\n\n**The Pattern**:\n- **Hour 1**: \"This is going great!\"\n- **Hour 3**: \"Wait, why is this test failing?\"\n- **Hour 5**: \"Which of the 15 changes broke this?\"\n- **Hour 6**: \"I should have split this up...\"\n\n**Real story from the trenches**: One of our developers reviewed a 3,000-line PR diff until their eyes bled, spending hours trying to understand all the changes across multiple subsystems. They finally YOLO'd the merge. It worked, but the risk was enormous and the review was nearly impossible.\n\n### The Solution: Automatic Complexity Scoring\n\nThe `/csw:plan` command automatically calculates a **complexity score (0-10)** based on:\n\n- **File Impact**: How many files you're creating/modifying\n- **Subsystem Coupling**: How many different systems you're touching\n- **Task Estimate**: Total number of implementation steps\n- **New Dependencies**: External packages you're adding\n- **Pattern Novelty**: Whether you're using existing patterns or creating new ones\n\n**Threshold-based protection**:\n- **0-3 (LOW)**: ✅ Green light, well-scoped feature\n- **4-5 (MEDIUM-LOW)**: ⚠️ Suggested split, but manageable as-is\n- **6-10 (MEDIUM-HIGH to CRITICAL)**: 🛑 Mandatory split or explicit YOLO override required\n\n### How It Works\n\nWhen complexity \u003e= 6, `/csw:plan` will:\n\n1. **Show detailed complexity breakdown** with specific factors\n2. **Optionally generate phase breakdown** if you want to see the split\n3. **Explain why splitting reduces risk** (better validation, reviewable PRs, incremental value)\n4. **Require simple y/n confirmation** to proceed with full scope\n\n**Example output**:\n\n```\n🛑 COMPLEXITY: 7/10 (HIGH)\n\n**Complexity Factors**:\n📁 File Impact: Creating 5 files, modifying 4 files (9 total)\n🔗 Subsystems: Touching 3 subsystems (UI, API, Database)\n🔢 Task Estimate: ~10 subtasks\n📦 Dependencies: 0 new packages\n🆕 Pattern Novelty: Following existing patterns\n\n**Why This Is Risky**:\n- Context overload: 10 subtasks is manageable but pushing limits\n- Validation isolation: Hard to isolate which of 10 steps caused failure\n- PR review difficulty: 9 files is unreviewable in single PR\n- Architectural pivot cost: If approach is wrong, significant time wasted\n- Token limit risks: Large context may hit AI limits\n\n**You know this feeling**:\n- Hour 1: \"This is going great!\"\n- Hour 3: \"Wait, why is this test failing?\"\n- Hour 5: \"Which of the 10 changes broke this?\"\n- Hour 6: \"I should have split this up...\"\n\n**RECOMMENDATION: SPLIT INTO PHASES**\n\n### Phase 1: Database Schema \u0026 Core Models (Complexity: 2/10) ✅\n**Start here** - Foundation that other phases depend on\n- Create database migrations\n- Add TypeScript types\n- Write database access layer tests\n**Estimated**: 3 subtasks\n**Can ship**: No - infrastructure only, but validates approach\n\n### Phase 2: API Endpoints (Complexity: 3/10) ⚠️\n**Do second** - Business logic implementation\n- Implement CRUD endpoints\n- Add request validation\n- Write API integration tests\n**Estimated**: 4 subtasks\n**Can ship**: Yes - provides functional backend\n\n### Phase 3: UI Components (Complexity: 3/10) ⚠️\n**Do last** - User-facing features\n- Create form components\n- Add data fetching hooks\n- Implement E2E tests\n**Estimated**: 6 subtasks\n**Can ship**: Yes - complete feature\n\n**Why Splitting Works**:\n✅ Each phase has meaningful validation gates (\u003c 8 subtasks = debuggable)\n✅ Ship Phase 1, get feedback, adjust Phase 2 accordingly\n✅ PRs are reviewable size (Phase 1 = ~3 files vs 9 files)\n✅ If Phase 1 reveals issues, haven't wasted time on Phase 2/3\n✅ Incremental value delivery\n\n**Your Decision** (required):\n1. **Phase 1 only** - Generate full spec for Phase 1 (recommended)\n2. **Full roadmap** - Generate Phase 1 spec + Phase 2/3 outlines\n3. ⚠️ **YOLO OVERRIDE** - Proceed with full scope (not recommended)\n\nPlease choose: 1, 2, or 3\n```\n\n**If you choose YOLO override**:\n\nThe system will ask for simple y/n confirmation to proceed with full scope. This makes scope decisions **deliberate** rather than default, without adding unnecessary friction.\n\n### Why This Matters\n\n**For developers who self-select for quality**:\n\nIf you're using a specification-driven methodology like this, you probably care deeply about code quality. The complexity assessment helps you maintain that standard by:\n\n- **Preventing context overload** that leads to bugs\n- **Ensuring reviewable PRs** that actually get reviewed\n- **Enabling incremental validation** so failures are easy to debug\n- **Protecting your time** from architectural pivots late in development\n\n**Bottom line**: The best time to split a feature is during planning, not at 2 AM when tests are failing and you can't remember which of 15 changes broke things.\n\n## Project Structure\n\nAfter initialization, your project will have:\n\n```\nyour-project/\n├── .claude/\n│   ├── skills/csw/SKILL.md    # Autonomous discovery\n│   └── commands/csw:*.md      # Slash commands\n└── spec/\n    ├── feature-name/\n    │   ├── spec.md   # Requirements\n    │   ├── plan.md   # Implementation plan (generated)\n    │   └── log.md    # Progress tracking (generated)\n    ├── stack.md          # Validation commands for your tech stack\n    ├── template.md       # Spec template for new features\n    └── README.md         # Workflow documentation\n```\n\n**Important:** All spec files (spec.md, plan.md, log.md) should be committed to git. They provide a complete audit trail of the feature development process:\n- `spec.md` - What you're building and why\n- `plan.md` - How you're building it\n- `log.md` - Proof that validation passed during `/build`\n\nThe cleanup preamble in `/csw:spec` uses log.md to determine which specs have been completed and shipped. Don't gitignore these files.\n\n## Uninstalling\n\n```bash\ncsw uninstall\n```\n\nThis removes:\n- Skill from `~/.claude/skills/csw/`\n- Claude commands from `~/.claude/commands/`\n- `~/.local/bin/csw` symlink\n\nYour project `spec/` directories remain untouched. To remove the installation directory itself, delete it manually.\n\n## Troubleshooting\n\n### Installation Issues\n\n**Commands not showing up in Claude Code**\n- Verify installation path:\n  - macOS/Linux: `~/.claude/commands/`\n  - Windows: `%APPDATA%\\claude\\commands\\`\n- Restart Claude Code after installation\n- Check file permissions: `ls -la ~/.claude/commands/`\n\n**Permission denied errors**\n- Make scripts executable: `chmod +x *.sh`\n- Check directory permissions: `mkdir -p ~/.claude/commands`\n\n### Command Execution Issues\n\n**`/plan` or `/build` can't find spec directory**\n- Ensure you're in the project root\n- Check `spec/` directory exists: `ls -la spec/`\n- Run `csw init .` if spec directory is missing\n\n**Commands run out of order**\n- Recommended flow: `/csw:spec` → `/csw:plan` → `/csw:build` → `/csw:check` → `/csw:ship`\n- If missing plan.md, run `/csw:plan` first\n- If missing spec.md, create it or use `/csw:spec`\n\n**Validation commands fail**\n- Missing `spec/stack.md`: Commands will error and ask you to run csw init\n- Check validation commands work: `npm run lint`, `npm test`, etc.\n- Run `csw init . \u003cpreset-name\u003e` to create or update stack.md\n- Verify commands in spec/stack.md match your project setup\n\n### Git Issues\n\n**Not on a feature branch**\n- `/csw:plan` creates a branch automatically\n- Or create manually: `git checkout -b feature/your-feature`\n- Never run `/csw:ship` from main/master branch\n\n**Uncommitted changes block `/ship`**\n- Commit or stash changes first\n- `/csw:ship` requires clean working directory\n- Check status: `git status`\n\n### Monorepo Issues\n\n**Workspace not detected**\n- Add `Workspace: backend` to spec.md metadata\n- Or detect from file paths in plan.md\n- Verify workspace exists in `spec/stack.md` as `## Workspace: backend`\n\n**Wrong commands run for workspace**\n- Check `spec/stack.md` has correct workspace sections\n- Verify workspace-specific validation commands\n- Test commands manually in workspace directory\n\n### Configuration Issues\n\n**Stack config not being read**\n- Ensure file is named exactly `spec/stack.md`\n- Check file is in spec/ directory (not inside spec/active/)\n- Verify markdown format with bash code blocks\n\n**Commands in stack.md don't work**\n- Test commands manually first\n- Check for typos in command paths\n- Verify package.json scripts exist (for npm/pnpm/yarn projects)\n- Commands should be in bash code blocks under section headers (## Lint, ## Test, etc.)\n\n### Workflow Issues\n\n**Spec too vague, plan is generic**\n- Add more specific technical requirements\n- Include code examples and patterns\n- Reference similar features in your codebase\n- Define clear validation criteria\n\n**Build fails validation repeatedly**\n- Check linter and test output carefully\n- Fix issues incrementally, don't skip validation\n- Review log.md for patterns in failures\n- Consider if spec needs clarification\n\n**`/check` finds unexpected issues**\n- Review code quality patterns in config\n- Some warnings are informational only\n- Fix critical issues, decide on warnings\n- Update config if checks don't fit your workflow\n\n### Cross-Platform Issues\n\n**Windows setup**\n- Use Git Bash or WSL2 terminal for all commands\n- Use forward slashes in paths: `/csw:plan spec/feature/spec.md`\n- If using Git Bash: Right-click in directory → \"Git Bash Here\"\n\n**Symlink issues on Unix**\n- Scripts now handle symlinks correctly (v1.0.0+)\n- If issues persist, use absolute paths\n\n### PR Creation Issues\n\n**`/csw:ship` doesn't create PR automatically**\n\nThe `/csw:ship` command tries multiple authentication methods in order:\n1. GitHub CLI (if authenticated)\n2. GH_TOKEN environment variable\n3. Token from gh config\n\nIf all fail, you'll get manual PR creation instructions.\n\n**To fix**:\n```bash\n# Option 1: Use GitHub CLI\ngh auth login\n\n# Option 2: Set GH_TOKEN\nexport GH_TOKEN=your_token_here\n# Add to ~/.bashrc or ~/.zshrc for persistence\n\n# Then re-run\n/csw:ship spec/your-feature/\n```\n\n**After creating PR manually**:\nYour PR is ready for review! The spec directory remains in your working tree until it's automatically cleaned up at the start of the next `/csw:spec` cycle.\n\n### Getting Help\n\nStill stuck?\n1. Check existing issues: https://github.com/trakrf/claude-spec-workflow/issues\n2. Review TESTING.md for validation procedures\n3. See CONTRIBUTING.md for reporting bugs\n4. Include error messages and system details in reports\n\n## Roadmap\n\n### Upcoming Features\n\n- Additional stack presets (Rust, Ruby on Rails, Bun, etc.)\n- Enhanced error messages and validation feedback\n- Integration tests for workflow validation\n- Community preset library (users share configs via PRs)\n- Improved monorepo workspace detection\n\n## Credits\n\nThis specification-driven development system synthesizes ideas from:\n\n- **Cole Medin** - [Context Engineering](https://github.com/coleam00/context-engineering-intro) methodology, validation loops, and comprehensive context approach\n- **Ryan Carson** - [3-File PRD System](https://creatoreconomy.so/p/full-tutorial-a-proven-3-file-system-to-vibe-code-production-apps-ryan) ([repo](https://github.com/snarktank/ai-dev-tasks)) for progress tracking and clarifying questions pattern\n\nSpecial thanks to both for sharing their methodologies publicly.\n\n## License\n\nMIT License - See LICENSE file\n\n## Contributing\n\nIssues and PRs welcome! This is an evolving methodology based on real-world usage.\n\n**Hacking on CSW?** Use `@commands/csw:plan.md` instead of `/csw:plan` for instant feedback without install/restart. See CONTRIBUTING.md for rapid iteration workflow.\n\n## About TrakRF\n\n[TrakRF](https://trakrf.id) provides RFID asset tracking solutions for manufacturing and logistics. We use AI-assisted development to accelerate our platform development while maintaining high code quality.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmikestankavich%2Fclaude-spec-workflow","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmikestankavich%2Fclaude-spec-workflow","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmikestankavich%2Fclaude-spec-workflow/lists"}