crewkit 1.1.4 → 1.1.6
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 +6 -8
- package/package.json +1 -2
- package/skill/SKILL.md +99 -49
- package/skill/adapters/copilot.md +230 -64
- package/skill/copilot-agent.md +113 -9
- package/src/cli.js +1 -1
- package/src/detect.js +0 -5
- package/src/install.js +1 -5
- package/skill/adapters/cursor.md +0 -215
- package/skill/cursor-global.md +0 -157
package/README.md
CHANGED
|
@@ -94,10 +94,9 @@ npx crewkit add impact # analise de blast radius
|
|
|
94
94
|
## IDEs suportadas
|
|
95
95
|
|
|
96
96
|
- **Claude Code** — suporte completo (agents, skills, hooks, rules, memory)
|
|
97
|
-
- **GitHub Copilot** —
|
|
98
|
-
- **Cursor** — auto-detectado, gera rules com globs e `AGENTS.md`
|
|
97
|
+
- **GitHub Copilot** — gera `copilot-instructions.md`, agents, skills nativas, prompts, instructions por stack e guardrails de seguranca
|
|
99
98
|
|
|
100
|
-
A IDE e
|
|
99
|
+
A IDE e selecionada pelo usuario durante o setup. `.ai/memory/` e compartilhado entre as IDEs.
|
|
101
100
|
|
|
102
101
|
## O que e commitado vs ignorado
|
|
103
102
|
|
|
@@ -111,7 +110,7 @@ A IDE e detectada automaticamente durante o setup. `.ai/memory/` e compartilhado
|
|
|
111
110
|
## Requisitos
|
|
112
111
|
|
|
113
112
|
- Node.js >= 20
|
|
114
|
-
- Claude Code
|
|
113
|
+
- Claude Code ou GitHub Copilot
|
|
115
114
|
- Opus ou Sonnet recomendado (Haiku funciona mas gera scans mais rasos)
|
|
116
115
|
|
|
117
116
|
## Licenca
|
|
@@ -216,10 +215,9 @@ npx crewkit add impact # blast radius analysis
|
|
|
216
215
|
## Supported IDEs
|
|
217
216
|
|
|
218
217
|
- **Claude Code** — full support (agents, skills, hooks, rules, memory)
|
|
219
|
-
- **GitHub Copilot** —
|
|
220
|
-
- **Cursor** — auto-detected, generates rules with globs and `AGENTS.md`
|
|
218
|
+
- **GitHub Copilot** — generates `copilot-instructions.md`, agents, native skills, prompts, per-stack instructions and security guardrails
|
|
221
219
|
|
|
222
|
-
IDE is
|
|
220
|
+
IDE is selected by the user during setup. `.ai/memory/` is shared across IDEs.
|
|
223
221
|
|
|
224
222
|
## What gets committed vs ignored
|
|
225
223
|
|
|
@@ -233,7 +231,7 @@ IDE is auto-detected during setup. `.ai/memory/` is shared across all IDEs.
|
|
|
233
231
|
## Requirements
|
|
234
232
|
|
|
235
233
|
- Node.js >= 20
|
|
236
|
-
- Claude Code
|
|
234
|
+
- Claude Code or GitHub Copilot
|
|
237
235
|
- Opus or Sonnet recommended (Haiku works but produces shallower scans)
|
|
238
236
|
|
|
239
237
|
## License
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "crewkit",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.6",
|
|
4
4
|
"description": "Context engineering framework for AI-assisted development. One command to set up agents, skills, hooks, rules, and memory for your project.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -20,7 +20,6 @@
|
|
|
20
20
|
"ai",
|
|
21
21
|
"claude-code",
|
|
22
22
|
"copilot",
|
|
23
|
-
"cursor",
|
|
24
23
|
"agents",
|
|
25
24
|
"skills",
|
|
26
25
|
"mcp",
|
package/skill/SKILL.md
CHANGED
|
@@ -15,7 +15,7 @@ This skill scans the current project's codebase and generates a complete, calibr
|
|
|
15
15
|
|
|
16
16
|
### Critical rules (read before starting)
|
|
17
17
|
1. **Language:** All generated files MUST be in **English**. User-facing output (reports during execution) matches the user's language.
|
|
18
|
-
2. **Zero questions:** Do not pause for user input except for re-run detection ([R]/[M]/[C]).
|
|
18
|
+
2. **Zero questions:** Do not pause for user input except for re-run detection ([R]/[M]/[C]) and IDE target selection.
|
|
19
19
|
3. **Validate everything:** After all files are generated, run the completion checklist at the bottom of this document before reporting done.
|
|
20
20
|
4. **Persist to disk:** Write scan results to `.crewkit/` files at each phase. Read them back before generating. This survives context compaction.
|
|
21
21
|
|
|
@@ -40,6 +40,21 @@ Check if `.crewkit/version` exists.
|
|
|
40
40
|
|
|
41
41
|
Wait for user choice. On [R] or [M]: existing `lessons-*.md` files with content are **preserved and merged**, not overwritten — these contain accumulated institutional knowledge.
|
|
42
42
|
|
|
43
|
+
### 3. IDE target selection
|
|
44
|
+
|
|
45
|
+
**Always ask the user which IDEs to generate context for.**
|
|
46
|
+
|
|
47
|
+
Check if a previous selection exists in `.crewkit/scan-phase1-recon.md`. If it does, show it as the default.
|
|
48
|
+
|
|
49
|
+
> "Which IDEs should I generate context for?"
|
|
50
|
+
> - **[1] Claude Code**
|
|
51
|
+
> - **[2] GitHub Copilot**
|
|
52
|
+
> - **[A] All of the above**
|
|
53
|
+
>
|
|
54
|
+
> You can select multiple (e.g., "1,2"). Default: [previous selection if re-run, or "1" if first run].
|
|
55
|
+
|
|
56
|
+
Accept the user's choice. If the user presses Enter without typing, use the default.
|
|
57
|
+
|
|
43
58
|
---
|
|
44
59
|
|
|
45
60
|
## Phase 0 — Preparation
|
|
@@ -51,16 +66,32 @@ If `.claude/` or `CLAUDE.md` or `.ai/memory/` exists:
|
|
|
51
66
|
3. Report: "Existing setup backed up to `.crewkit-backup/`"
|
|
52
67
|
|
|
53
68
|
### Create directory structure
|
|
69
|
+
Create directories based on the **selected IDE targets** from Pre-flight:
|
|
70
|
+
|
|
71
|
+
**Always:**
|
|
72
|
+
```
|
|
73
|
+
.ai/
|
|
74
|
+
memory/
|
|
75
|
+
plans/
|
|
76
|
+
.crewkit/
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
**If Claude Code is a selected target:**
|
|
54
80
|
```
|
|
55
81
|
.claude/
|
|
56
82
|
agents/
|
|
57
83
|
hooks/
|
|
58
84
|
rules/
|
|
59
85
|
skills/
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
**If GitHub Copilot is a selected target:**
|
|
89
|
+
```
|
|
90
|
+
.github/
|
|
91
|
+
agents/
|
|
92
|
+
instructions/
|
|
93
|
+
skills/
|
|
94
|
+
prompts/
|
|
64
95
|
```
|
|
65
96
|
|
|
66
97
|
### Version tracking
|
|
@@ -142,24 +173,16 @@ For each stack, detect the build and test commands:
|
|
|
142
173
|
|
|
143
174
|
Read `package.json` scripts, CI configs, or Makefiles to find the actual commands used in this project. Prefer project-specific over generic.
|
|
144
175
|
|
|
145
|
-
### IDE
|
|
146
|
-
|
|
147
|
-
Detect which IDEs are in use or configured in this project:
|
|
148
|
-
|
|
149
|
-
| IDE | Detection signals |
|
|
150
|
-
|-----|------------------|
|
|
151
|
-
| Claude Code | **Always** — this skill runs inside Claude Code |
|
|
152
|
-
| GitHub Copilot | `.github/` directory exists OR `.github/copilot-instructions.md` found |
|
|
153
|
-
| Cursor | `.cursor/` directory exists OR `.cursorrules` file found |
|
|
176
|
+
### IDE targets
|
|
154
177
|
|
|
155
|
-
|
|
178
|
+
Use the IDE targets selected during Pre-flight (step 3). Include them in the scan data:
|
|
156
179
|
```
|
|
157
|
-
IDE targets
|
|
180
|
+
IDE targets selected: [selected IDEs from pre-flight]
|
|
158
181
|
```
|
|
159
182
|
|
|
160
183
|
**Store results as: `ReconProfile`** — write to `.crewkit/scan-phase1-recon.md` for persistence.
|
|
161
184
|
|
|
162
|
-
Report: "Phase 1 complete. Detected: [stacks], [CI], [DBs], [build/test commands]."
|
|
185
|
+
Report: "Phase 1 complete. Detected: [stacks], [CI], [DBs], [build/test commands]. IDE target: [selected IDEs]."
|
|
163
186
|
|
|
164
187
|
---
|
|
165
188
|
|
|
@@ -178,10 +201,8 @@ Read existing human-written documentation to understand project context, convent
|
|
|
178
201
|
**Existing AI context (from any IDE — preserve, don't discard):**
|
|
179
202
|
- Existing `CLAUDE.md` (if backed up from a previous setup)
|
|
180
203
|
- Existing `.ai/memory/` files (if backed up)
|
|
181
|
-
- `.cursorrules` or `.cursor/rules/*.md` (Cursor)
|
|
182
204
|
- `.github/copilot-instructions.md` or `.github/instructions/*.md` (GitHub Copilot)
|
|
183
205
|
- `.github/agents/*.agent.md` (Copilot agents)
|
|
184
|
-
- `AGENTS.md` (Cursor agents)
|
|
185
206
|
|
|
186
207
|
If any of these exist, read them and extract rules, conventions, and patterns to incorporate into the generated setup. This preserves context engineering work done in other IDEs.
|
|
187
208
|
|
|
@@ -409,8 +430,8 @@ Compile all profiles into a single summary and present it to the user.
|
|
|
409
430
|
- Test: `[command]`
|
|
410
431
|
- Dev server: `[command]` (if detected)
|
|
411
432
|
|
|
412
|
-
## IDE Targets
|
|
413
|
-
- [list
|
|
433
|
+
## IDE Targets (selected)
|
|
434
|
+
- [list selected IDE targets — e.g., "Claude Code" or "Claude Code, GitHub Copilot"]
|
|
414
435
|
```
|
|
415
436
|
|
|
416
437
|
### Save profile
|
|
@@ -437,9 +458,16 @@ This step is critical for large projects where context compaction may have evict
|
|
|
437
458
|
|
|
438
459
|
---
|
|
439
460
|
|
|
440
|
-
Generate
|
|
461
|
+
Generate files based on the **selected IDE targets** from Phase 1. The generation order is designed for **graceful failure** — if the process is interrupted, the user has the most valuable files first.
|
|
441
462
|
|
|
442
|
-
**
|
|
463
|
+
**IDE-conditional generation:**
|
|
464
|
+
- **Step 1** (`.ai/memory/`): ALWAYS — shared across all IDEs.
|
|
465
|
+
- **Steps 2-9** (CLAUDE.md, `.claude/agents/`, `.claude/rules/`, `.claude/settings.json`, `.claude/hooks/`, `.claude/skills/`, `.claude/QUICKSTART.md`, `.mcp.json`): ONLY if **Claude Code** is a selected target.
|
|
466
|
+
- **Step 10** (IDE Adapters): Runs for each non-Claude IDE in the selected targets. Adapters generate directly from scan data + `.ai/memory/` — they do NOT depend on Claude files existing.
|
|
467
|
+
|
|
468
|
+
If the only selected target is GitHub Copilot, Steps 2-9 are **skipped entirely**. The adapter generates the IDE-native files directly.
|
|
469
|
+
|
|
470
|
+
**If the user chose [M] (memory only):** generate Step 1 (memory) + the project rules file for the selected IDE (CLAUDE.md / copilot-instructions.md), then update context headers in existing agents. Stop after that.
|
|
443
471
|
|
|
444
472
|
### Templates directory
|
|
445
473
|
Templates are located at `~/.claude/skills/crewkit-setup/templates/`. Read them from disk.
|
|
@@ -591,6 +619,8 @@ Create empty `lessons-{stack}.md` files for each detected stack.
|
|
|
591
619
|
|
|
592
620
|
### Step 2 — `CLAUDE.md` (AI-generated from scan)
|
|
593
621
|
|
|
622
|
+
> **Conditional:** Skip this step if Claude Code is NOT a selected IDE target. Jump to Step 10.
|
|
623
|
+
|
|
594
624
|
Generate the project's root `CLAUDE.md`. This is the most important generated file — it defines the AI's behavior for this project.
|
|
595
625
|
|
|
596
626
|
**Structure:**
|
|
@@ -908,7 +938,6 @@ Read all core skill templates from `~/.claude/skills/crewkit-setup/templates/ski
|
|
|
908
938
|
- `hotfix/SKILL.md`
|
|
909
939
|
- `explore-and-plan/SKILL.md`
|
|
910
940
|
- `review-pr/SKILL.md`
|
|
911
|
-
|
|
912
941
|
Copy each skill template to `.claude/skills/[name]/SKILL.md`. **If the template has a `references/` subdirectory, copy it too.**
|
|
913
942
|
|
|
914
943
|
These skill templates are **stack-agnostic** by design — they reference `.ai/memory/commands.md` for build/test commands and `.ai/memory/` for project context. No variable substitution needed.
|
|
@@ -935,6 +964,7 @@ This project uses crewkit for AI-assisted development. Here's how to use it.
|
|
|
935
964
|
- `/explore-and-plan <feature>` — map a module and plan before coding (recommended for LARGE tasks)
|
|
936
965
|
- `/review-pr [number]` — review a pull request
|
|
937
966
|
|
|
967
|
+
|
|
938
968
|
## How agents work together
|
|
939
969
|
The orchestrator routes work to specialized agents:
|
|
940
970
|
- **explorer** (Sonnet) — finds files, maps dependencies — read-only
|
|
@@ -1001,15 +1031,17 @@ For any placeholder tokens, add a comment in the profile or tell the user to fil
|
|
|
1001
1031
|
|
|
1002
1032
|
### Step 10 — IDE Adapters
|
|
1003
1033
|
|
|
1004
|
-
If
|
|
1034
|
+
If **GitHub Copilot** is a selected target:
|
|
1005
1035
|
|
|
1006
|
-
1.
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
2. If
|
|
1036
|
+
1. Determine the adapter file path: `~/.claude/skills/crewkit-setup/adapters/copilot.md`
|
|
1037
|
+
2. If the adapter file does not exist: WARN the user ("Adapter file not found for Copilot — skipping"). Do not fail.
|
|
1038
|
+
3. If the adapter file exists: read it completely, then MANDATORY: follow ALL instructions in it.
|
|
1039
|
+
|
|
1040
|
+
**Source of truth for adapters (in priority order):**
|
|
1041
|
+
1. If Claude Code files exist (Steps 2-9 were generated): use them as the primary source, converting content to the target IDE format.
|
|
1042
|
+
2. If Claude Code files do NOT exist (Claude was not a selected target): generate IDE-native files directly from `.crewkit/last-scan.md` + `.ai/memory/` (Step 1). The adapter instructions describe the expected output format — use scan data to fill in the content instead of reformatting Claude files.
|
|
1043
|
+
|
|
1044
|
+
If no non-Claude IDE targets were selected, skip this step entirely.
|
|
1013
1045
|
|
|
1014
1046
|
**Note:** The adapters do NOT duplicate `.ai/memory/` — that directory is shared across all IDEs without transformation.
|
|
1015
1047
|
|
|
@@ -1022,8 +1054,12 @@ After all generation steps, run the **Completion Checklist** (at the bottom of t
|
|
|
1022
1054
|
```markdown
|
|
1023
1055
|
# crewkit setup complete
|
|
1024
1056
|
|
|
1025
|
-
##
|
|
1057
|
+
## IDE target: [selected IDE(s)]
|
|
1058
|
+
|
|
1059
|
+
## Generated files (shared)
|
|
1026
1060
|
- `.ai/memory/` — [N] files (architecture, conventions, commands, testing, lessons, state)
|
|
1061
|
+
|
|
1062
|
+
## Generated files (Claude Code) — only if selected
|
|
1027
1063
|
- `CLAUDE.md` — project rules ([N] hard rules)
|
|
1028
1064
|
- `.claude/agents/` — 5 agents (explorer, architect, coder, tester, reviewer)
|
|
1029
1065
|
- `.claude/rules/` — [N] rule files ([list stacks])
|
|
@@ -1033,20 +1069,25 @@ After all generation steps, run the **Completion Checklist** (at the bottom of t
|
|
|
1033
1069
|
- `.claude/napkin.md` — priorities board
|
|
1034
1070
|
- `.claude/QUICKSTART.md` — onboarding guide
|
|
1035
1071
|
- `.mcp.json` — [N] MCP servers
|
|
1036
|
-
|
|
1072
|
+
|
|
1073
|
+
## Generated files (GitHub Copilot) — only if selected
|
|
1074
|
+
- `.github/copilot-instructions.md` — project rules (no frontmatter, includes session start + quality gate + safety rules)
|
|
1075
|
+
- `.github/instructions/` — [N] per-stack instruction files + sensitive-files guardrail
|
|
1076
|
+
- `.github/agents/` — 5 agent files (with model, tools, mcp-servers)
|
|
1077
|
+
- `.github/skills/` — 4 native skills
|
|
1078
|
+
- `.github/prompts/` — 4 IDE fallback prompts
|
|
1079
|
+
|
|
1080
|
+
## Validation: [X]/[Y] checks passed
|
|
1037
1081
|
|
|
1038
1082
|
## Commands detected
|
|
1039
1083
|
- Build: `[command]`
|
|
1040
1084
|
- Test: `[command]`
|
|
1041
1085
|
|
|
1042
|
-
## Recommended MCPs to configure
|
|
1043
|
-
[List MCPs with placeholder tokens that need user input]
|
|
1044
|
-
|
|
1045
1086
|
## Next steps
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1087
|
+
[Adapt next steps to the selected IDE:]
|
|
1088
|
+
- Claude Code: "Review CLAUDE.md → run /full-workflow"
|
|
1089
|
+
- Copilot: "Review .github/copilot-instructions.md → open Copilot Chat"
|
|
1090
|
+
- All: "Commit the setup"
|
|
1050
1091
|
```
|
|
1051
1092
|
|
|
1052
1093
|
---
|
|
@@ -1065,27 +1106,36 @@ After all generation steps, run the **Completion Checklist** (at the bottom of t
|
|
|
1065
1106
|
|
|
1066
1107
|
Before presenting the Final Report, go through EVERY item. Fix failures before reporting.
|
|
1067
1108
|
|
|
1068
|
-
### Content checks
|
|
1109
|
+
### Content checks (shared — always verify)
|
|
1069
1110
|
- [ ] `.ai/memory/architecture.md` — has constructor/DI signatures table (if project uses DI)
|
|
1070
1111
|
- [ ] `.ai/memory/conventions.md` — has Design System section (if frontend detected)
|
|
1071
1112
|
- [ ] `.ai/memory/testing.md` — has Fakes/Stubs inventory table (if test doubles detected)
|
|
1072
1113
|
- [ ] `.ai/memory/commands.md` — has build + test + dev commands for ALL detected stacks
|
|
1114
|
+
|
|
1115
|
+
### Content checks (Claude Code — only if Claude is a selected target)
|
|
1073
1116
|
- [ ] `CLAUDE.md` — hard rules present, all in English
|
|
1074
1117
|
- [ ] `.claude/agents/` — all 5 have `crewkit:context-start` header with real project data
|
|
1075
1118
|
- [ ] `.claude/QUICKSTART.md` — exists with workflow guide
|
|
1076
1119
|
|
|
1077
|
-
### Validation checks (
|
|
1120
|
+
### Validation checks (Claude Code — only if Claude is a selected target)
|
|
1078
1121
|
- [ ] `.claude/settings.json` — read back, verify valid JSON, has Write(.ai/memory/*), has stack permissions, has MCP permissions (Layer 4)
|
|
1079
1122
|
- [ ] `.mcp.json` — read back, verify valid JSON, has context7
|
|
1080
1123
|
- [ ] `.claude/hooks/*.sh` — run `bash -n` on each, all 4 pass syntax check
|
|
1081
1124
|
- [ ] `.claude/rules/` — at least 1 per detected stack, glob patterns match real files in project
|
|
1082
|
-
- [ ] `.claude/skills/` — all 4 core skills have SKILL.md
|
|
1083
|
-
|
|
1084
|
-
###
|
|
1125
|
+
- [ ] `.claude/skills/` — all 4 core skills have SKILL.md (full-workflow, hotfix, explore-and-plan, review-pr)
|
|
1126
|
+
|
|
1127
|
+
### Content checks (Copilot — only if Copilot is a selected target)
|
|
1128
|
+
- [ ] `.github/copilot-instructions.md` — exists, **NO frontmatter**, contains hard rules + session start + quality gate + safety rules, no Claude-specific sections
|
|
1129
|
+
- [ ] `.github/instructions/` — at least 1 per detected stack with `applyTo:` frontmatter
|
|
1130
|
+
- [ ] `.github/instructions/sensitive-files.instructions.md` — exists with glob for `.env*`, `credentials*`, `secrets*`, `*.key`, `*.pem`
|
|
1131
|
+
- [ ] `.github/agents/` — 5 agent files with `.agent.md` extension, each has `tools:` with canonical aliases (`read`, `edit`, `search`, `execute`), has `model:` converted to Copilot names, body under 30,000 chars
|
|
1132
|
+
- [ ] `.github/agents/coder.agent.md` + `tester.agent.md` — have `mcp-servers:` if `.mcp.json` exists
|
|
1133
|
+
- [ ] `.github/skills/` — 4 native skill files with `name:` + `description:` frontmatter
|
|
1134
|
+
- [ ] `.github/prompts/` — 4 IDE fallback prompts with `description:` + `agent: "agent"` frontmatter
|
|
1135
|
+
|
|
1136
|
+
### Integrity checks (always)
|
|
1085
1137
|
- [ ] `.crewkit/last-scan.md` — exists with full profile including Domain section
|
|
1086
1138
|
- [ ] `.crewkit/scan-phase*.md` — all 4 phase files exist with content
|
|
1087
1139
|
- [ ] No Portuguese in any generated file (only in user-facing output)
|
|
1088
|
-
- [ ] If Copilot target detected: `.github/copilot-instructions.md` exists and contains the project hard rules
|
|
1089
|
-
- [ ] If Cursor target detected: `.cursor/rules/project.md` exists and has `alwaysApply: true` frontmatter
|
|
1090
1140
|
|
|
1091
|
-
|
|
1141
|
+
Count only the checks applicable to the selected IDE targets. Report as: "Validation: X/Y checks passed." If any failed, list which ones and why.
|