cp-toolkit 2.2.16 → 3.0.0
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/package.json +2 -2
- package/src/commands/add.js +68 -7
- package/src/commands/doctor.js +11 -6
- package/src/commands/init.js +27 -13
- package/templates/agents/{backend-specialist.md → backend-specialist.agent.md} +264 -264
- package/templates/agents/{code-archaeologist.md → code-archaeologist.agent.md} +2 -2
- package/templates/agents/{database-architect.md → database-architect.agent.md} +227 -227
- package/templates/agents/{debugger.md → debugger.agent.md} +226 -226
- package/templates/agents/{devops-engineer.md → devops-engineer.agent.md} +243 -243
- package/templates/agents/{documentation-writer.md → documentation-writer.agent.md} +105 -105
- package/templates/agents/{explorer-agent.md → explorer-agent.agent.md} +2 -2
- package/templates/agents/{frontend-specialist.md → frontend-specialist.agent.md} +557 -557
- package/templates/agents/{game-developer.md → game-developer.agent.md} +163 -163
- package/templates/agents/{mobile-developer.md → mobile-developer.agent.md} +378 -378
- package/templates/agents/{orchestrator.md → orchestrator.agent.md} +2 -2
- package/templates/agents/{penetration-tester.md → penetration-tester.agent.md} +189 -189
- package/templates/agents/{performance-optimizer.md → performance-optimizer.agent.md} +188 -188
- package/templates/agents/{product-manager.md → product-manager.agent.md} +2 -2
- package/templates/agents/{product-owner.md → product-owner.agent.md} +2 -2
- package/templates/agents/{project-planner.md → project-planner.agent.md} +2 -2
- package/templates/agents/{qa-automation-engineer.md → qa-automation-engineer.agent.md} +2 -2
- package/templates/agents/{security-auditor.md → security-auditor.agent.md} +171 -171
- package/templates/agents/{seo-specialist.md → seo-specialist.agent.md} +112 -112
- package/templates/agents/{test-engineer.md → test-engineer.agent.md} +159 -159
- package/templates/copilot-instructions.md +19 -74
- package/templates/instructions/github-actions.instructions.md +0 -1
- /package/templates/skills/{optional/api-patterns → api-patterns}/SKILL.md +0 -0
- /package/templates/skills/{optional/api-patterns → api-patterns}/api-style.md +0 -0
- /package/templates/skills/{optional/api-patterns → api-patterns}/auth.md +0 -0
- /package/templates/skills/{optional/api-patterns → api-patterns}/documentation.md +0 -0
- /package/templates/skills/{optional/api-patterns → api-patterns}/graphql.md +0 -0
- /package/templates/skills/{optional/api-patterns → api-patterns}/rate-limiting.md +0 -0
- /package/templates/skills/{optional/api-patterns → api-patterns}/response.md +0 -0
- /package/templates/skills/{optional/api-patterns → api-patterns}/rest.md +0 -0
- /package/templates/skills/{optional/api-patterns → api-patterns}/scripts/api_validator.py +0 -0
- /package/templates/skills/{optional/api-patterns → api-patterns}/security-testing.md +0 -0
- /package/templates/skills/{optional/api-patterns → api-patterns}/trpc.md +0 -0
- /package/templates/skills/{optional/api-patterns → api-patterns}/versioning.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/SKILL.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/agent-coordination.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/feature-building.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/project-detection.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/scaffolding.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/tech-stack.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/SKILL.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/astro-static/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/chrome-extension/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/cli-tool/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/electron-desktop/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/express-api/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/flutter-app/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/monorepo-turborepo/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/nextjs-fullstack/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/nextjs-saas/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/nextjs-static/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/nuxt-app/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/python-fastapi/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/app-builder → app-builder}/templates/react-native-app/TEMPLATE.md +0 -0
- /package/templates/skills/{optional/architecture → architecture}/SKILL.md +0 -0
- /package/templates/skills/{optional/architecture → architecture}/context-discovery.md +0 -0
- /package/templates/skills/{optional/architecture → architecture}/examples.md +0 -0
- /package/templates/skills/{optional/architecture → architecture}/pattern-selection.md +0 -0
- /package/templates/skills/{optional/architecture → architecture}/patterns-reference.md +0 -0
- /package/templates/skills/{optional/architecture → architecture}/trade-off-analysis.md +0 -0
- /package/templates/skills/{optional/bash-linux → bash-linux}/SKILL.md +0 -0
- /package/templates/skills/{core/behavioral-modes → behavioral-modes}/SKILL.md +0 -0
- /package/templates/skills/{core/brainstorming → brainstorming}/SKILL.md +0 -0
- /package/templates/skills/{core/brainstorming → brainstorming}/dynamic-questioning.md +0 -0
- /package/templates/skills/{core/clean-code → clean-code}/SKILL.md +0 -0
- /package/templates/skills/{optional/code-review-checklist → code-review-checklist}/SKILL.md +0 -0
- /package/templates/skills/{optional/database-design → database-design}/SKILL.md +0 -0
- /package/templates/skills/{optional/database-design → database-design}/database-selection.md +0 -0
- /package/templates/skills/{optional/database-design → database-design}/indexing.md +0 -0
- /package/templates/skills/{optional/database-design → database-design}/migrations.md +0 -0
- /package/templates/skills/{optional/database-design → database-design}/optimization.md +0 -0
- /package/templates/skills/{optional/database-design → database-design}/orm-selection.md +0 -0
- /package/templates/skills/{optional/database-design → database-design}/schema-design.md +0 -0
- /package/templates/skills/{optional/database-design → database-design}/scripts/schema_validator.py +0 -0
- /package/templates/skills/{optional/deployment-procedures → deployment-procedures}/SKILL.md +0 -0
- /package/templates/skills/{optional/documentation-templates → documentation-templates}/SKILL.md +0 -0
- /package/templates/skills/{optional/frontend-design → frontend-design}/SKILL.md +0 -0
- /package/templates/skills/{optional/frontend-design → frontend-design}/animation-guide.md +0 -0
- /package/templates/skills/{optional/frontend-design → frontend-design}/color-system.md +0 -0
- /package/templates/skills/{optional/frontend-design → frontend-design}/decision-trees.md +0 -0
- /package/templates/skills/{optional/frontend-design → frontend-design}/motion-graphics.md +0 -0
- /package/templates/skills/{optional/frontend-design → frontend-design}/scripts/accessibility_checker.py +0 -0
- /package/templates/skills/{optional/frontend-design → frontend-design}/scripts/ux_audit.py +0 -0
- /package/templates/skills/{optional/frontend-design → frontend-design}/typography-system.md +0 -0
- /package/templates/skills/{optional/frontend-design → frontend-design}/ux-psychology.md +0 -0
- /package/templates/skills/{optional/frontend-design → frontend-design}/visual-effects.md +0 -0
- /package/templates/skills/{optional/game-development → game-development}/2d-games/SKILL.md +0 -0
- /package/templates/skills/{optional/game-development → game-development}/3d-games/SKILL.md +0 -0
- /package/templates/skills/{optional/game-development → game-development}/SKILL.md +0 -0
- /package/templates/skills/{optional/game-development → game-development}/game-art/SKILL.md +0 -0
- /package/templates/skills/{optional/game-development → game-development}/game-audio/SKILL.md +0 -0
- /package/templates/skills/{optional/game-development → game-development}/game-design/SKILL.md +0 -0
- /package/templates/skills/{optional/game-development → game-development}/mobile-games/SKILL.md +0 -0
- /package/templates/skills/{optional/game-development → game-development}/multiplayer/SKILL.md +0 -0
- /package/templates/skills/{optional/game-development → game-development}/pc-games/SKILL.md +0 -0
- /package/templates/skills/{optional/game-development → game-development}/vr-ar/SKILL.md +0 -0
- /package/templates/skills/{optional/game-development → game-development}/web-games/SKILL.md +0 -0
- /package/templates/skills/{optional/geo-fundamentals → geo-fundamentals}/SKILL.md +0 -0
- /package/templates/skills/{optional/geo-fundamentals → geo-fundamentals}/scripts/geo_checker.py +0 -0
- /package/templates/skills/{optional/i18n-localization → i18n-localization}/SKILL.md +0 -0
- /package/templates/skills/{optional/i18n-localization → i18n-localization}/scripts/i18n_checker.py +0 -0
- /package/templates/skills/{core/intelligent-routing → intelligent-routing}/SKILL.md +0 -0
- /package/templates/skills/{optional/lint-and-validate → lint-and-validate}/SKILL.md +0 -0
- /package/templates/skills/{optional/lint-and-validate → lint-and-validate}/scripts/lint_runner.py +0 -0
- /package/templates/skills/{optional/lint-and-validate → lint-and-validate}/scripts/type_coverage.py +0 -0
- /package/templates/skills/{core/mcp-builder → mcp-builder}/SKILL.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/SKILL.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/decision-trees.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/mobile-backend.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/mobile-color-system.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/mobile-debugging.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/mobile-design-thinking.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/mobile-navigation.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/mobile-performance.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/mobile-testing.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/mobile-typography.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/platform-android.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/platform-ios.md +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/scripts/mobile_audit.py +0 -0
- /package/templates/skills/{optional/mobile-design → mobile-design}/touch-psychology.md +0 -0
- /package/templates/skills/{optional/nextjs-react-expert → nextjs-react-expert}/1-async-eliminating-waterfalls.md +0 -0
- /package/templates/skills/{optional/nextjs-react-expert → nextjs-react-expert}/2-bundle-bundle-size-optimization.md +0 -0
- /package/templates/skills/{optional/nextjs-react-expert → nextjs-react-expert}/3-server-server-side-performance.md +0 -0
- /package/templates/skills/{optional/nextjs-react-expert → nextjs-react-expert}/4-client-client-side-data-fetching.md +0 -0
- /package/templates/skills/{optional/nextjs-react-expert → nextjs-react-expert}/5-rerender-re-render-optimization.md +0 -0
- /package/templates/skills/{optional/nextjs-react-expert → nextjs-react-expert}/6-rendering-rendering-performance.md +0 -0
- /package/templates/skills/{optional/nextjs-react-expert → nextjs-react-expert}/7-js-javascript-performance.md +0 -0
- /package/templates/skills/{optional/nextjs-react-expert → nextjs-react-expert}/8-advanced-advanced-patterns.md +0 -0
- /package/templates/skills/{optional/nextjs-react-expert → nextjs-react-expert}/SKILL.md +0 -0
- /package/templates/skills/{optional/nextjs-react-expert → nextjs-react-expert}/scripts/convert_rules.py +0 -0
- /package/templates/skills/{optional/nextjs-react-expert → nextjs-react-expert}/scripts/react_performance_checker.py +0 -0
- /package/templates/skills/{optional/nodejs-best-practices → nodejs-best-practices}/SKILL.md +0 -0
- /package/templates/skills/{core/parallel-agents → parallel-agents}/SKILL.md +0 -0
- /package/templates/skills/{optional/performance-profiling → performance-profiling}/SKILL.md +0 -0
- /package/templates/skills/{optional/performance-profiling → performance-profiling}/scripts/lighthouse_audit.py +0 -0
- /package/templates/skills/{core/plan-writing → plan-writing}/SKILL.md +0 -0
- /package/templates/skills/{optional/powershell-windows → powershell-windows}/SKILL.md +0 -0
- /package/templates/skills/{optional/python-patterns → python-patterns}/SKILL.md +0 -0
- /package/templates/skills/{optional/red-team-tactics → red-team-tactics}/SKILL.md +0 -0
- /package/templates/skills/{optional/seo-fundamentals → seo-fundamentals}/SKILL.md +0 -0
- /package/templates/skills/{optional/seo-fundamentals → seo-fundamentals}/scripts/seo_checker.py +0 -0
- /package/templates/skills/{optional/server-management → server-management}/SKILL.md +0 -0
- /package/templates/skills/{optional/systematic-debugging → systematic-debugging}/SKILL.md +0 -0
- /package/templates/skills/{optional/tailwind-patterns → tailwind-patterns}/SKILL.md +0 -0
- /package/templates/skills/{optional/tdd-workflow → tdd-workflow}/SKILL.md +0 -0
- /package/templates/skills/{optional/testing-patterns → testing-patterns}/SKILL.md +0 -0
- /package/templates/skills/{optional/testing-patterns → testing-patterns}/scripts/test_runner.py +0 -0
- /package/templates/skills/{optional/vulnerability-scanner → vulnerability-scanner}/SKILL.md +0 -0
- /package/templates/skills/{optional/vulnerability-scanner → vulnerability-scanner}/checklists.md +0 -0
- /package/templates/skills/{optional/vulnerability-scanner → vulnerability-scanner}/scripts/security_scan.py +0 -0
- /package/templates/skills/{optional/web-design-guidelines → web-design-guidelines}/SKILL.md +0 -0
- /package/templates/skills/{optional/webapp-testing → webapp-testing}/SKILL.md +0 -0
- /package/templates/skills/{optional/webapp-testing → webapp-testing}/scripts/playwright_runner.py +0 -0
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cp-toolkit",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "Copilot Toolkit - AI
|
|
3
|
+
"version": "3.0.0",
|
|
4
|
+
"description": "Copilot Toolkit - Native AI Agents & Skills for GitHub Copilot (v2026)",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ai-agents",
|
|
7
7
|
"github-copilot",
|
package/src/commands/add.js
CHANGED
|
@@ -13,8 +13,11 @@ const AGENT_TEMPLATES = {
|
|
|
13
13
|
specialist: (name, description, triggers) => `---
|
|
14
14
|
name: ${name}
|
|
15
15
|
description: ${description}
|
|
16
|
-
|
|
17
|
-
|
|
16
|
+
model: gpt-4o
|
|
17
|
+
capabilities:
|
|
18
|
+
- clean-code
|
|
19
|
+
handoffs:
|
|
20
|
+
- project-planner
|
|
18
21
|
---
|
|
19
22
|
|
|
20
23
|
# ${name}
|
|
@@ -41,8 +44,12 @@ ${triggers.map(t => `- ${t} related tasks`).join('\n')}
|
|
|
41
44
|
reviewer: (name, description, triggers) => `---
|
|
42
45
|
name: ${name}
|
|
43
46
|
description: ${description}
|
|
44
|
-
|
|
45
|
-
|
|
47
|
+
model: gpt-4o
|
|
48
|
+
capabilities:
|
|
49
|
+
- clean-code
|
|
50
|
+
- qa-automation-engineer
|
|
51
|
+
handoffs:
|
|
52
|
+
- project-planner
|
|
46
53
|
---
|
|
47
54
|
|
|
48
55
|
# ${name}
|
|
@@ -78,11 +85,31 @@ skills: clean-code, qa-automation-engineer
|
|
|
78
85
|
`
|
|
79
86
|
};
|
|
80
87
|
|
|
88
|
+
const SKILL_TEMPLATE = (name, description) => `---
|
|
89
|
+
name: ${name}
|
|
90
|
+
description: ${description}
|
|
91
|
+
version: 1.0.0
|
|
92
|
+
---
|
|
93
|
+
|
|
94
|
+
# Skill: ${name}
|
|
95
|
+
|
|
96
|
+
> ${description}
|
|
97
|
+
|
|
98
|
+
## Context & Rules
|
|
99
|
+
- [Rule 1]
|
|
100
|
+
- [Rule 2]
|
|
101
|
+
|
|
102
|
+
## Code Snippets
|
|
103
|
+
\`\`\`javascript
|
|
104
|
+
// Example code for this skill
|
|
105
|
+
\`\`\`
|
|
106
|
+
`;
|
|
107
|
+
|
|
81
108
|
export async function addCommand(type, name, options) {
|
|
82
109
|
const targetDir = process.cwd();
|
|
83
110
|
|
|
84
111
|
// Validate type
|
|
85
|
-
const validTypes = ['agent', 'instruction'];
|
|
112
|
+
const validTypes = ['agent', 'instruction', 'skill'];
|
|
86
113
|
if (!validTypes.includes(type)) {
|
|
87
114
|
console.log(chalk.red(`❌ Unknown type: ${type}`));
|
|
88
115
|
console.log(chalk.dim(` Valid types: ${validTypes.join(', ')}`));
|
|
@@ -103,6 +130,9 @@ export async function addCommand(type, name, options) {
|
|
|
103
130
|
case 'agent':
|
|
104
131
|
await addAgent(githubDir, name, options);
|
|
105
132
|
break;
|
|
133
|
+
case 'skill':
|
|
134
|
+
await addSkill(githubDir, name, options);
|
|
135
|
+
break;
|
|
106
136
|
case 'instruction':
|
|
107
137
|
await addInstruction(githubDir, name, options);
|
|
108
138
|
break;
|
|
@@ -110,7 +140,7 @@ export async function addCommand(type, name, options) {
|
|
|
110
140
|
}
|
|
111
141
|
|
|
112
142
|
async function addAgent(githubDir, name, options) {
|
|
113
|
-
const agentFile = path.join(githubDir, 'agents', `${name}.md`);
|
|
143
|
+
const agentFile = path.join(githubDir, 'agents', `${name}.agent.md`);
|
|
114
144
|
|
|
115
145
|
if (fs.existsSync(agentFile)) {
|
|
116
146
|
console.log(chalk.yellow(`⚠️ Agent "${name}" already exists.`));
|
|
@@ -152,10 +182,41 @@ async function addAgent(githubDir, name, options) {
|
|
|
152
182
|
await fs.ensureDir(path.dirname(agentFile));
|
|
153
183
|
await fs.writeFile(agentFile, content);
|
|
154
184
|
|
|
155
|
-
console.log(chalk.green(`✅ Created agent: .github/agents/${name}.md`));
|
|
185
|
+
console.log(chalk.green(`✅ Created agent: .github/agents/${name}.agent.md`));
|
|
156
186
|
console.log(chalk.dim(` Invoke with @${name} in Copilot Chat`));
|
|
157
187
|
}
|
|
158
188
|
|
|
189
|
+
async function addSkill(githubDir, name, options) {
|
|
190
|
+
const skillFile = path.join(githubDir, 'skills', name, 'SKILL.md');
|
|
191
|
+
|
|
192
|
+
if (fs.existsSync(skillFile)) {
|
|
193
|
+
console.log(chalk.yellow(`⚠️ Skill "${name}" already exists.`));
|
|
194
|
+
return;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
const response = await prompts([
|
|
198
|
+
{
|
|
199
|
+
type: 'text',
|
|
200
|
+
name: 'description',
|
|
201
|
+
message: 'Description (used for semantic loading):',
|
|
202
|
+
initial: `${name} helper`
|
|
203
|
+
}
|
|
204
|
+
]);
|
|
205
|
+
|
|
206
|
+
if (!response.description) {
|
|
207
|
+
console.log(chalk.yellow('Aborted.'));
|
|
208
|
+
return;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
const content = SKILL_TEMPLATE(name, response.description);
|
|
212
|
+
|
|
213
|
+
await fs.ensureDir(path.dirname(skillFile));
|
|
214
|
+
await fs.writeFile(skillFile, content);
|
|
215
|
+
|
|
216
|
+
console.log(chalk.green(`✅ Created skill: .github/skills/${name}/SKILL.md`));
|
|
217
|
+
console.log(chalk.dim(` This skill will be loaded when you ask about "${response.description}"`));
|
|
218
|
+
}
|
|
219
|
+
|
|
159
220
|
async function addInstruction(githubDir, name, options) {
|
|
160
221
|
const instrFile = path.join(githubDir, 'instructions', `${name}.instructions.md`);
|
|
161
222
|
|
package/src/commands/doctor.js
CHANGED
|
@@ -30,10 +30,15 @@ const CHECKS = [
|
|
|
30
30
|
const agentsDir = path.join(dir, '.github', 'agents');
|
|
31
31
|
if (!await fs.pathExists(agentsDir)) return false;
|
|
32
32
|
const files = await fs.readdir(agentsDir);
|
|
33
|
-
return files.some(f => f.endsWith('.md'));
|
|
33
|
+
return files.some(f => f.endsWith('.agent.md') || f.endsWith('.md'));
|
|
34
34
|
},
|
|
35
35
|
fix: 'Run: cp-kit add agent <name>'
|
|
36
36
|
},
|
|
37
|
+
{
|
|
38
|
+
name: 'skills/ directory exists',
|
|
39
|
+
check: async (dir) => fs.pathExists(path.join(dir, '.github', 'skills')),
|
|
40
|
+
fix: 'Run: cp-kit init'
|
|
41
|
+
},
|
|
37
42
|
{
|
|
38
43
|
name: 'instructions/ directory exists',
|
|
39
44
|
check: async (dir) => fs.pathExists(path.join(dir, '.github', 'instructions')),
|
|
@@ -77,22 +82,22 @@ const CHECKS = [
|
|
|
77
82
|
fix: 'Add version and description frontmatter to instruction files'
|
|
78
83
|
},
|
|
79
84
|
{
|
|
80
|
-
name: 'Agents have complete frontmatter (name, description,
|
|
85
|
+
name: 'Agents have complete frontmatter (name, description, capabilities)',
|
|
81
86
|
check: async (dir) => {
|
|
82
87
|
const agentsDir = path.join(dir, '.github', 'agents');
|
|
83
88
|
if (!await fs.pathExists(agentsDir)) return true;
|
|
84
89
|
const files = await fs.readdir(agentsDir);
|
|
85
|
-
for (const file of files.filter(f => f.endsWith('.md'))) {
|
|
90
|
+
for (const file of files.filter(f => f.endsWith('.agent.md'))) {
|
|
86
91
|
const content = await fs.readFile(path.join(agentsDir, file), 'utf-8');
|
|
87
92
|
if (!content.startsWith('---')) return false;
|
|
88
93
|
if (!content.includes('name:')) return false;
|
|
89
94
|
if (!content.includes('description:')) return false;
|
|
90
|
-
|
|
91
|
-
if (!content.includes('
|
|
95
|
+
// Capabilities is the new standard (was skills)
|
|
96
|
+
if (!content.includes('capabilities:') && !content.includes('tools:')) return false;
|
|
92
97
|
}
|
|
93
98
|
return true;
|
|
94
99
|
},
|
|
95
|
-
fix: 'Update agent files with full frontmatter (name, description,
|
|
100
|
+
fix: 'Update agent files with full frontmatter (name, description, capabilities, model)'
|
|
96
101
|
}
|
|
97
102
|
];
|
|
98
103
|
|
package/src/commands/init.js
CHANGED
|
@@ -103,11 +103,14 @@ export async function initCommand(directory, options) {
|
|
|
103
103
|
'database-design',
|
|
104
104
|
'testing-patterns',
|
|
105
105
|
'deployment-procedures',
|
|
106
|
-
'architecture'
|
|
106
|
+
'architecture',
|
|
107
|
+
'brainstorming',
|
|
108
|
+
'clean-code',
|
|
109
|
+
'plan-writing'
|
|
107
110
|
];
|
|
108
111
|
|
|
109
112
|
for (const skill of essentialSkills) {
|
|
110
|
-
const skillSourceDir = path.join(templatesDir, 'skills',
|
|
113
|
+
const skillSourceDir = path.join(templatesDir, 'skills', skill);
|
|
111
114
|
if (fs.existsSync(skillSourceDir)) {
|
|
112
115
|
const skillTargetDir = path.join(skillsTargetDir, skill);
|
|
113
116
|
await fs.ensureDir(skillTargetDir);
|
|
@@ -127,10 +130,29 @@ export async function initCommand(directory, options) {
|
|
|
127
130
|
const modelsTemplatePath = path.join(templatesDir, 'cp-kit-models.yaml');
|
|
128
131
|
await fs.copy(modelsTemplatePath, modelsPath);
|
|
129
132
|
|
|
130
|
-
// 7. Setup .vscode/
|
|
131
|
-
spinner.text = 'Configuring
|
|
133
|
+
// 7. Setup .vscode/settings.json
|
|
134
|
+
spinner.text = 'Configuring VS Code settings...';
|
|
132
135
|
const vscodeDir = path.join(targetDir, '.vscode');
|
|
133
136
|
await fs.ensureDir(vscodeDir);
|
|
137
|
+
|
|
138
|
+
const settingsPath = path.join(vscodeDir, 'settings.json');
|
|
139
|
+
let settings = {};
|
|
140
|
+
if (fs.existsSync(settingsPath)) {
|
|
141
|
+
try {
|
|
142
|
+
settings = JSON.parse(await fs.readFile(settingsPath, 'utf8'));
|
|
143
|
+
} catch (e) {
|
|
144
|
+
// ignore error
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
settings['chat.agent.skills.enabled'] = true;
|
|
149
|
+
// Suggest other useful settings for 2026
|
|
150
|
+
settings['github.copilot.chat.welcomeMessage'] = "always";
|
|
151
|
+
|
|
152
|
+
await fs.writeFile(settingsPath, JSON.stringify(settings, null, 2));
|
|
153
|
+
|
|
154
|
+
// 8. Setup .vscode/mcp.json
|
|
155
|
+
spinner.text = 'Configuring MCP Server...';
|
|
134
156
|
|
|
135
157
|
const mcpConfig = {
|
|
136
158
|
"mcpServers": {
|
|
@@ -152,14 +174,6 @@ export async function initCommand(directory, options) {
|
|
|
152
174
|
],
|
|
153
175
|
"disabled": false,
|
|
154
176
|
"autoApprove": []
|
|
155
|
-
},
|
|
156
|
-
"antigravity": {
|
|
157
|
-
"command": "node",
|
|
158
|
-
"args": [
|
|
159
|
-
"${workspaceFolder}/.github/scripts/mcp-server.js"
|
|
160
|
-
],
|
|
161
|
-
"disabled": false,
|
|
162
|
-
"autoApprove": []
|
|
163
177
|
}
|
|
164
178
|
}
|
|
165
179
|
};
|
|
@@ -169,7 +183,7 @@ export async function initCommand(directory, options) {
|
|
|
169
183
|
JSON.stringify(mcpConfig, null, 2)
|
|
170
184
|
);
|
|
171
185
|
|
|
172
|
-
//
|
|
186
|
+
// 9. Copy workflows to .github/workflows-copilot/ (optional reference)
|
|
173
187
|
if (config.installEverything) {
|
|
174
188
|
spinner.text = 'Copying workflows...';
|
|
175
189
|
const workflowsSourceDir = path.join(templatesDir, 'workflows');
|