@devobsessed/code-captain 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +214 -0
- package/bin/install.js +1048 -0
- package/claude-code/README.md +276 -0
- package/claude-code/agents/code-captain.md +121 -0
- package/claude-code/agents/spec-generator.md +271 -0
- package/claude-code/agents/story-creator.md +309 -0
- package/claude-code/agents/tech-spec.md +440 -0
- package/claude-code/commands/cc-initialize.md +520 -0
- package/copilot/README.md +210 -0
- package/copilot/chatmodes/Code Captain.chatmode.md +60 -0
- package/copilot/docs/best-practices.md +74 -0
- package/copilot/prompts/create-adr.prompt.md +468 -0
- package/copilot/prompts/create-spec.prompt.md +430 -0
- package/copilot/prompts/edit-spec.prompt.md +396 -0
- package/copilot/prompts/execute-task.prompt.md +144 -0
- package/copilot/prompts/explain-code.prompt.md +292 -0
- package/copilot/prompts/initialize.prompt.md +65 -0
- package/copilot/prompts/new-command.prompt.md +310 -0
- package/copilot/prompts/plan-product.prompt.md +450 -0
- package/copilot/prompts/research.prompt.md +329 -0
- package/copilot/prompts/status.prompt.md +424 -0
- package/copilot/prompts/swab.prompt.md +217 -0
- package/cursor/README.md +224 -0
- package/cursor/cc.md +183 -0
- package/cursor/cc.mdc +69 -0
- package/cursor/commands/create-adr.md +504 -0
- package/cursor/commands/create-spec.md +430 -0
- package/cursor/commands/edit-spec.md +405 -0
- package/cursor/commands/execute-task.md +514 -0
- package/cursor/commands/explain-code.md +289 -0
- package/cursor/commands/initialize.md +397 -0
- package/cursor/commands/new-command.md +312 -0
- package/cursor/commands/plan-product.md +466 -0
- package/cursor/commands/research.md +317 -0
- package/cursor/commands/status.md +413 -0
- package/cursor/commands/swab.md +209 -0
- package/cursor/docs/best-practices.md +74 -0
- package/cursor/integrations/azure-devops/create-azure-work-items.md +403 -0
- package/cursor/integrations/azure-devops/sync-azure-work-items.md +486 -0
- package/cursor/integrations/github/create-github-issues.md +765 -0
- package/cursor/integrations/github/scripts/create-issues-batch.sh +272 -0
- package/cursor/integrations/github/sync-github-issues.md +237 -0
- package/cursor/integrations/github/sync.md +305 -0
- package/manifest.json +381 -0
- package/package.json +58 -0
- package/windsurf/README.md +254 -0
- package/windsurf/rules/cc.md +5 -0
- package/windsurf/workflows/create-adr.md +331 -0
- package/windsurf/workflows/create-spec.md +280 -0
- package/windsurf/workflows/edit-spec.md +273 -0
- package/windsurf/workflows/execute-task.md +276 -0
- package/windsurf/workflows/explain-code.md +292 -0
- package/windsurf/workflows/initialize.md +298 -0
- package/windsurf/workflows/new-command.md +321 -0
- package/windsurf/workflows/status.md +213 -0
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
# Code Captain for GitHub Copilot + VS Code
|
|
2
|
+
|
|
3
|
+
> **Classic VS Code with AI-powered chat modes and prompts**
|
|
4
|
+
|
|
5
|
+
Transform GitHub Copilot Chat into a structured development workflow system with custom chat modes, prompts, and organized documentation.
|
|
6
|
+
|
|
7
|
+
## 🚀 Installation
|
|
8
|
+
|
|
9
|
+
### Automatic Installation (Recommended)
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
npx @devobsessed/code-captain
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
The installer will detect VS Code with Copilot and install to:
|
|
16
|
+
- `.github/chatmodes/` - Code Captain chat mode
|
|
17
|
+
- `.github/prompts/` - Workflow prompt templates
|
|
18
|
+
- `.code-captain/` - Complete workflow system
|
|
19
|
+
|
|
20
|
+
### Manual Installation
|
|
21
|
+
|
|
22
|
+
```bash
|
|
23
|
+
# Clone or download the copilot/ directory contents to .github/
|
|
24
|
+
cp -r copilot/chatmodes/ .github/chatmodes/
|
|
25
|
+
cp -r copilot/prompts/ .github/prompts/
|
|
26
|
+
cp -r .code-captain/ .
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
## 🎯 Command Syntax
|
|
30
|
+
|
|
31
|
+
Code Captain integrates with Copilot Chat through a custom chat mode. After installation:
|
|
32
|
+
|
|
33
|
+
1. **Select Code Captain chat mode** from the chat mode dropdown
|
|
34
|
+
2. **Use slash commands** directly:
|
|
35
|
+
|
|
36
|
+
```bash
|
|
37
|
+
/initialize
|
|
38
|
+
/create-spec "user authentication system"
|
|
39
|
+
/execute-task
|
|
40
|
+
/status
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
## 📁 Chat Modes & Prompts
|
|
44
|
+
|
|
45
|
+
### Chat Mode
|
|
46
|
+
Located in `.github/chatmodes/`:
|
|
47
|
+
|
|
48
|
+
- **Code Captain.chatmode.md** - Automatically available in chat mode selector
|
|
49
|
+
|
|
50
|
+
### Available Prompts
|
|
51
|
+
Located in `.github/prompts/`:
|
|
52
|
+
|
|
53
|
+
- **`create-spec.prompt.md`** - Feature specification creation
|
|
54
|
+
- **`create-adr.prompt.md`** - Architecture Decision Records
|
|
55
|
+
- **`execute-task.prompt.md`** - Test-driven development workflow
|
|
56
|
+
- **`initialize.prompt.md`** - Project setup and analysis
|
|
57
|
+
- **`plan-product.prompt.md`** - Product planning and strategy
|
|
58
|
+
- **`research.prompt.md`** - Systematic technical research
|
|
59
|
+
- **`explain-code.prompt.md`** - Code explanation with diagrams
|
|
60
|
+
- **`status.prompt.md`** - Project status analysis
|
|
61
|
+
- **`swab.prompt.md`** - Code cleanup methodology
|
|
62
|
+
- **`edit-spec.prompt.md`** - Specification modification
|
|
63
|
+
- **`new-command.prompt.md`** - Custom command creation
|
|
64
|
+
|
|
65
|
+
## 🛠️ Available Workflows
|
|
66
|
+
|
|
67
|
+
### 📋 Project Setup & Analysis
|
|
68
|
+
- **Initialize Project** - Analyze codebase and generate documentation
|
|
69
|
+
- **Product Planning** - Comprehensive product strategy and roadmap
|
|
70
|
+
- **Technical Research** - Systematic 4-phase research methodology
|
|
71
|
+
- **Custom Commands** - Create domain-specific workflows
|
|
72
|
+
|
|
73
|
+
### 📝 Requirements & Planning
|
|
74
|
+
- **Feature Specifications** - Comprehensive specs with technical details
|
|
75
|
+
- **Architecture Decisions** - ADRs with research and alternatives analysis
|
|
76
|
+
- **Code Explanations** - Visual diagrams and technical analysis
|
|
77
|
+
- **Specification Editing** - Contract-first modification approach
|
|
78
|
+
|
|
79
|
+
### ⚙️ Implementation
|
|
80
|
+
- **Test-Driven Development** - Systematic TDD workflow
|
|
81
|
+
- **Project Status** - Comprehensive status analysis
|
|
82
|
+
- **Code Cleanup** - Small improvements following Boy Scout Rule
|
|
83
|
+
|
|
84
|
+
## 🔄 Workflow Examples
|
|
85
|
+
|
|
86
|
+
### Using the Chat Mode
|
|
87
|
+
|
|
88
|
+
1. **Open Copilot Chat** in VS Code
|
|
89
|
+
2. **Select "Code Captain"** from the chat mode dropdown
|
|
90
|
+
3. **Type:** `/initialize`
|
|
91
|
+
4. **Follow the prompts** for project analysis
|
|
92
|
+
5. **Review generated files** in `.code-captain/docs/`
|
|
93
|
+
|
|
94
|
+
### Using Prompts Directly
|
|
95
|
+
|
|
96
|
+
1. **Open a prompt file** (e.g., `.github/prompts/create-spec.prompt.md`)
|
|
97
|
+
2. **Copy the prompt** content
|
|
98
|
+
3. **Paste in Copilot Chat** (any mode)
|
|
99
|
+
4. **Provide your feature description**
|
|
100
|
+
|
|
101
|
+
### Complete Feature Development
|
|
102
|
+
|
|
103
|
+
```bash
|
|
104
|
+
# Select "Code Captain" chat mode, then:
|
|
105
|
+
|
|
106
|
+
# 1. Project setup
|
|
107
|
+
/initialize
|
|
108
|
+
|
|
109
|
+
# 2. Research phase
|
|
110
|
+
/research "React state management options"
|
|
111
|
+
|
|
112
|
+
# 3. Document decision
|
|
113
|
+
/create-adr "React state management library selection"
|
|
114
|
+
|
|
115
|
+
# 4. Create specification
|
|
116
|
+
/create-spec "user dashboard with real-time notifications"
|
|
117
|
+
|
|
118
|
+
# 5. Implementation
|
|
119
|
+
/execute-task
|
|
120
|
+
|
|
121
|
+
# 6. Status check
|
|
122
|
+
/status
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
## 📁 File Organization
|
|
126
|
+
|
|
127
|
+
Copilot integration creates this structure:
|
|
128
|
+
|
|
129
|
+
```
|
|
130
|
+
.github/
|
|
131
|
+
├── chatmodes/
|
|
132
|
+
│ └── Code Captain.chatmode.md
|
|
133
|
+
└── prompts/
|
|
134
|
+
├── create-spec.prompt.md
|
|
135
|
+
├── create-adr.prompt.md
|
|
136
|
+
├── execute-task.prompt.md
|
|
137
|
+
├── initialize.prompt.md
|
|
138
|
+
├── plan-product.prompt.md
|
|
139
|
+
├── research.prompt.md
|
|
140
|
+
├── explain-code.prompt.md
|
|
141
|
+
├── status.prompt.md
|
|
142
|
+
├── swab.prompt.md
|
|
143
|
+
├── edit-spec.prompt.md
|
|
144
|
+
└── new-command.prompt.md
|
|
145
|
+
|
|
146
|
+
.code-captain/
|
|
147
|
+
├── docs/ # Generated documentation
|
|
148
|
+
├── research/ # Technical research reports
|
|
149
|
+
├── decision-records/ # Architecture Decision Records
|
|
150
|
+
├── specs/ # Feature specifications
|
|
151
|
+
└── cc.md # Complete reference guide
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
## 🎯 Copilot-Specific Features
|
|
155
|
+
|
|
156
|
+
### Custom Chat Modes
|
|
157
|
+
- **Structured workflows** through chat mode activation
|
|
158
|
+
- **Context-aware responses** based on project state
|
|
159
|
+
- **Guided interactions** with step-by-step processes
|
|
160
|
+
|
|
161
|
+
### Prompt Templates
|
|
162
|
+
- **Reusable workflows** for consistent outputs
|
|
163
|
+
- **Copy-paste convenience** for complex processes
|
|
164
|
+
- **Customizable templates** for team standards
|
|
165
|
+
|
|
166
|
+
### GitHub Integration
|
|
167
|
+
- **Repository-based configuration** through `.github/` structure
|
|
168
|
+
- **Team collaboration** through shared chat modes and prompts
|
|
169
|
+
- **Version-controlled workflows** alongside your codebase
|
|
170
|
+
|
|
171
|
+
|
|
172
|
+
## 📊 Command Reference
|
|
173
|
+
|
|
174
|
+
| Slash Command | Purpose | Output Location |
|
|
175
|
+
|---------------|---------|-----------------|
|
|
176
|
+
| `/initialize` | Project analysis | `.code-captain/docs/` |
|
|
177
|
+
| `/create-spec` | Feature specification | `.code-captain/specs/` |
|
|
178
|
+
| `/status` | Project status | Terminal output |
|
|
179
|
+
| `/research` | Technical research | `.code-captain/research/` |
|
|
180
|
+
|
|
181
|
+
## 🛠️ Troubleshooting
|
|
182
|
+
|
|
183
|
+
### Chat Mode Not Available
|
|
184
|
+
**Problem**: Code Captain doesn't appear in chat mode selector
|
|
185
|
+
**Solution**: Ensure `.github/chatmodes/Code Captain.chatmode.md` exists and restart VS Code
|
|
186
|
+
|
|
187
|
+
### Prompts Don't Work as Expected
|
|
188
|
+
**Problem**: Prompts generate inconsistent results
|
|
189
|
+
**Solution**: Copy the exact prompt text and include all context sections
|
|
190
|
+
|
|
191
|
+
### File Generation Issues
|
|
192
|
+
**Problem**: Files aren't created in expected locations
|
|
193
|
+
**Solution**: Check `.code-captain/` folder exists and has write permissions
|
|
194
|
+
|
|
195
|
+
## 🤝 Contributing
|
|
196
|
+
|
|
197
|
+
Copilot-specific contributions:
|
|
198
|
+
|
|
199
|
+
1. **Chat Mode Enhancement** - Improve workflow integration
|
|
200
|
+
2. **Prompt Templates** - Add new workflow templates
|
|
201
|
+
3. **Documentation** - Add Copilot-specific examples
|
|
202
|
+
4. **GitHub Integration** - Enhance repository templates
|
|
203
|
+
|
|
204
|
+
---
|
|
205
|
+
|
|
206
|
+
**Ready to enhance your Copilot workflow?**
|
|
207
|
+
|
|
208
|
+
1. **Install:** `npx @devobsessed/code-captain`
|
|
209
|
+
2. **Open:** Copilot Chat in VS Code
|
|
210
|
+
3. **Start:** Select "Code Captain" mode and type `/initialize`
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: '⚓ Awaiting orders...'
|
|
3
|
+
tools: ['changes', 'codebase', 'editFiles', 'extensions', 'fetch', 'findTestFiles', 'githubRepo', 'new', 'openSimpleBrowser', 'problems', 'runCommands', 'runNotebooks', 'runTasks', 'runTests', 'search', 'searchResults', 'terminalLastCommand', 'terminalSelection', 'testFailure', 'usages']
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Code Captain - System Instructions
|
|
7
|
+
|
|
8
|
+
## Identity
|
|
9
|
+
|
|
10
|
+
You are **Code Captain** - a methodical AI development partner who executes comprehensive software workflows. You organize all work in `.code-captain/` folders and use file-based progress tracking.
|
|
11
|
+
|
|
12
|
+
## Command Execution Protocol
|
|
13
|
+
|
|
14
|
+
1. **Check user environment**: Read `.code-captain/state.json` for platform and shell configuration
|
|
15
|
+
2. **Display welcome message**: Randomly select one of these greetings:
|
|
16
|
+
- "⚓ All aboard! Code Captain ready to steer your development ship."
|
|
17
|
+
- "🧭 Ahoy! Your Code Captain is charting the course to quality code."
|
|
18
|
+
- "⛵ Welcome aboard! Code Captain at your service, ready to navigate your codebase."
|
|
19
|
+
- "🚢 Greetings! Your Code Captain is here to guide you through smooth sailing."
|
|
20
|
+
- "⚓ Code Captain reporting for duty! Let's set sail toward exceptional software."
|
|
21
|
+
- "🧭 Ready to embark? Code Captain is here to navigate your development journey."
|
|
22
|
+
- "⛵ Permission to come aboard? Code Captain ready to chart your coding adventure."
|
|
23
|
+
- "🚢 Steady as she goes! Code Captain prepared to steer your project to success."
|
|
24
|
+
- "⚓ Anchors aweigh! Code Captain ready to lead your development expedition."
|
|
25
|
+
- "🧭 All hands on deck! Code Captain here to guide your coding voyage."
|
|
26
|
+
3. **Use available tools efficiently** with GitHub Copilot's capabilities
|
|
27
|
+
4. **Follow established patterns** from the prompt files for consistent execution
|
|
28
|
+
|
|
29
|
+
## Core Commands
|
|
30
|
+
|
|
31
|
+
- `/initialize` - Project technical foundation setup and analysis (recommends plan-product for product strategy)
|
|
32
|
+
- `/new-command "name" "description"` - Meta command to create new Code Captain commands
|
|
33
|
+
- `/plan-product "idea"` - Product strategy and vision through structured discovery
|
|
34
|
+
- `/create-spec "feature"` - Feature specifications with implementation roadmaps
|
|
35
|
+
|
|
36
|
+
- `/create-adr "decision"` - Architecture Decision Records (auto-executes research)
|
|
37
|
+
- `/research "topic"` - 4-phase systematic research
|
|
38
|
+
- `/execute-task` - TDD implementation from specifications
|
|
39
|
+
- `/status` - Comprehensive status report with git state, active work, and suggested actions
|
|
40
|
+
- `/swab` - Code cleanup: one small improvement following Boy Scout Rule
|
|
41
|
+
|
|
42
|
+
## GitHub Integration
|
|
43
|
+
|
|
44
|
+
- `/create-github-issues` - Create GitHub issues from specifications
|
|
45
|
+
- `/sync` - Advanced bidirectional GitHub sync with partitioned cache
|
|
46
|
+
- `/sync-github-issues` - Basic GitHub synchronization
|
|
47
|
+
|
|
48
|
+
## File Organization
|
|
49
|
+
|
|
50
|
+
```
|
|
51
|
+
.code-captain/
|
|
52
|
+
├── state.json # User platform and shell configuration
|
|
53
|
+
├── docs/ # Generated documentation
|
|
54
|
+
├── research/ # Technical research and analysis
|
|
55
|
+
├── decision-records/ # Architecture Decision Records
|
|
56
|
+
├── explanations/ # Code explanations with diagrams
|
|
57
|
+
└── specs/ # Requirements, specifications, and tasks
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
**Note: Command details and workflows are defined in individual prompt files in `.github/prompts/`**
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
# Development Best Practices
|
|
2
|
+
|
|
3
|
+
## Context
|
|
4
|
+
|
|
5
|
+
Global development guidelines for Agent OS projects.
|
|
6
|
+
|
|
7
|
+
## Core Principles
|
|
8
|
+
|
|
9
|
+
### Keep It Simple
|
|
10
|
+
|
|
11
|
+
- Implement code in the fewest lines possible
|
|
12
|
+
- Avoid over-engineering solutions
|
|
13
|
+
- Choose straightforward approaches over clever ones
|
|
14
|
+
|
|
15
|
+
### Optimize for Readability
|
|
16
|
+
|
|
17
|
+
- Prioritize code clarity over micro-optimizations
|
|
18
|
+
- Write self-documenting code with clear variable names
|
|
19
|
+
- Add comments for "why" not "what"
|
|
20
|
+
|
|
21
|
+
### DRY (Don't Repeat Yourself)
|
|
22
|
+
|
|
23
|
+
- Extract repeated business logic to private methods
|
|
24
|
+
- Extract repeated UI markup to reusable components
|
|
25
|
+
- Create utility functions for common operations
|
|
26
|
+
|
|
27
|
+
### File Structure
|
|
28
|
+
|
|
29
|
+
- Keep files focused on a single responsibility
|
|
30
|
+
- Group related functionality together
|
|
31
|
+
- Use consistent naming conventions
|
|
32
|
+
|
|
33
|
+
## Critical Thinking and Decision Making
|
|
34
|
+
|
|
35
|
+
### Challenge Ideas and Assumptions
|
|
36
|
+
|
|
37
|
+
- Question the "why" behind every technical decision
|
|
38
|
+
- Identify unstated assumptions in requirements and designs
|
|
39
|
+
- Ask "What could go wrong?" for proposed solutions
|
|
40
|
+
- Consider edge cases and failure scenarios
|
|
41
|
+
|
|
42
|
+
### Provide Constructive Pushback
|
|
43
|
+
|
|
44
|
+
- Disagree when you have evidence-based concerns
|
|
45
|
+
- Offer alternative approaches with clear reasoning
|
|
46
|
+
- Challenge overly complex solutions in favor of simpler ones
|
|
47
|
+
- Point out potential security, performance, or maintainability issues
|
|
48
|
+
|
|
49
|
+
### Focus on Evidence Over Agreement
|
|
50
|
+
|
|
51
|
+
- Base decisions on data, benchmarks, and measurable outcomes
|
|
52
|
+
- Cite specific examples when discussing trade-offs
|
|
53
|
+
- Reference industry standards and established patterns
|
|
54
|
+
- Avoid "yes, and..." responses when "no, because..." is more appropriate
|
|
55
|
+
|
|
56
|
+
### Question Popular Choices
|
|
57
|
+
|
|
58
|
+
- Don't assume popularity equals correctness
|
|
59
|
+
- Evaluate if trendy technologies actually solve the problem
|
|
60
|
+
- Consider long-term maintenance costs of new frameworks
|
|
61
|
+
- Assess if existing solutions already meet the need
|
|
62
|
+
|
|
63
|
+
## Dependencies
|
|
64
|
+
|
|
65
|
+
### Choose Libraries Wisely
|
|
66
|
+
|
|
67
|
+
When adding third-party dependencies:
|
|
68
|
+
|
|
69
|
+
- Select the most popular and actively maintained option
|
|
70
|
+
- Check the library's GitHub repository for:
|
|
71
|
+
- Recent commits (within last 6 months)
|
|
72
|
+
- Active issue resolution
|
|
73
|
+
- Number of stars/downloads
|
|
74
|
+
- Clear documentation
|