ccraft 1.0.5 → 1.0.7
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 +271 -0
- package/package.json +9 -2
- package/src/utils/preflight.js +1 -1
package/README.md
ADDED
|
@@ -0,0 +1,271 @@
|
|
|
1
|
+
<div align="center">
|
|
2
|
+
|
|
3
|
+
# ccraft
|
|
4
|
+
|
|
5
|
+
**Intelligent Claude Code project configurator** — analyzes your codebase, scores your stack, and generates role-aware agents, skills, rules, MCPs, and workflows in seconds.
|
|
6
|
+
|
|
7
|
+
[](https://www.npmjs.com/package/ccraft)
|
|
8
|
+
[](https://opensource.org/licenses/MIT)
|
|
9
|
+
[](https://nodejs.org/)
|
|
10
|
+
|
|
11
|
+
[Getting Started](#getting-started) • [How It Works](#how-it-works) • [Commands](#commands) • [Supported Stacks](#supported-stacks) • [FAQ](#faq)
|
|
12
|
+
|
|
13
|
+
</div>
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## The Problem
|
|
18
|
+
|
|
19
|
+
Setting up Claude Code for a real project takes hours. You need to write agents for your role, configure MCP servers for your tools, create rules for your stack, define skills for your workflows, and wire it all together in `.claude/`. Most developers either skip it entirely or copy a generic config that doesn't match their codebase.
|
|
20
|
+
|
|
21
|
+
**ccraft fixes this in one command.** A scoring engine analyzes your project — languages, frameworks, architecture, complexity — and your role as a developer, then selects and generates the exact Claude Code configuration your project needs.
|
|
22
|
+
|
|
23
|
+
## Getting Started
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
# 1. Install globally
|
|
27
|
+
npm install -g ccraft
|
|
28
|
+
|
|
29
|
+
# 2. Authenticate
|
|
30
|
+
ccraft auth YOUR_API_KEY
|
|
31
|
+
|
|
32
|
+
# 3. Configure your existing project
|
|
33
|
+
cd your-project
|
|
34
|
+
ccraft install
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
That's it. Your `.claude/` directory is now populated with agents, skills, rules, MCPs, and workflows — all scored and tailored to your stack and role.
|
|
38
|
+
|
|
39
|
+
### Starting a New Project?
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
ccraft create
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
The `create` command scaffolds a new project from scratch, runs Claude Code's bootstrap, then generates the full `.claude/` configuration on top.
|
|
46
|
+
|
|
47
|
+
## How It Works
|
|
48
|
+
|
|
49
|
+
```
|
|
50
|
+
Your Codebase Scoring Engine .claude/ Output
|
|
51
|
+
┌──────────────┐ analyze ┌──────────────────┐ render ┌──────────────────┐
|
|
52
|
+
│ Languages │───────────────>│ Score components │──────────>│ agents/ │
|
|
53
|
+
│ Frameworks │ │ Match role │ │ skills/ │
|
|
54
|
+
│ Architecture │ │ Select MCPs │ │ rules/ │
|
|
55
|
+
│ Complexity │ │ Apply intents │ │ commands/ │
|
|
56
|
+
│ CI/CD │ │ Build config │ │ workflows/ │
|
|
57
|
+
│ Dependencies │ └──────────────────┘ │ settings.json │
|
|
58
|
+
└──────────────┘ ▲ │ CLAUDE.md │
|
|
59
|
+
│ └──────────────────┘
|
|
60
|
+
Your Profile
|
|
61
|
+
(role, intents, tools)
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
1. **Analyze** — Deep scans your codebase: file distribution, dependency graphs, config files, architecture patterns, test infrastructure, CI/CD pipelines
|
|
65
|
+
2. **Profile** — Asks your developer role (web, mobile, data, DevOps, security, QA) and work intents (implementing, debugging, refactoring, testing, reviewing, documenting)
|
|
66
|
+
3. **Score** — A scoring engine evaluates 200+ components from the catalog and selects the ones that match your stack, role, and intents
|
|
67
|
+
4. **Integrate** — Detects your source control (GitHub, GitLab, Bitbucket, Azure DevOps) and PM tools (Linear, Jira, Notion, etc.) to configure MCP servers
|
|
68
|
+
5. **Generate** — Renders everything into your `.claude/` directory, ready to use
|
|
69
|
+
|
|
70
|
+
## What Gets Generated
|
|
71
|
+
|
|
72
|
+
```
|
|
73
|
+
.claude/
|
|
74
|
+
├── CLAUDE.md # Project instructions, build commands, conventions
|
|
75
|
+
├── settings.json # Hooks, MCP server configs, permissions
|
|
76
|
+
├── agents/ # Role-aware agent definitions
|
|
77
|
+
│ ├── architect.md # System design & trade-off analysis
|
|
78
|
+
│ ├── debugger.md # Bug investigation with Playwright
|
|
79
|
+
│ ├── reviewer.md # Multi-lens code review
|
|
80
|
+
│ └── ... # Scored & selected for your stack
|
|
81
|
+
├── skills/ # Task-specific workflows
|
|
82
|
+
│ ├── tdd.md # Test-driven development
|
|
83
|
+
│ ├── deploy.md # Pre-deployment checklists
|
|
84
|
+
│ └── ... # Matched to your work intents
|
|
85
|
+
├── rules/ # Coding standards & conventions
|
|
86
|
+
│ ├── error-handling.md # Error patterns for your framework
|
|
87
|
+
│ ├── testing.md # Test pyramid & coverage targets
|
|
88
|
+
│ └── ... # Stack-specific rules
|
|
89
|
+
├── commands/ # Slash commands for common tasks
|
|
90
|
+
├── workflows/ # Multi-step orchestration workflows
|
|
91
|
+
└── .claude-craft/ # Internal state (analysis cache, manifest)
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
Every file is selected by the scoring engine — not a static template. A React + TypeScript web app gets different agents than a Go microservice or a Python ML pipeline.
|
|
95
|
+
|
|
96
|
+
## Commands
|
|
97
|
+
|
|
98
|
+
### `ccraft auth <key>`
|
|
99
|
+
|
|
100
|
+
Store your API key for the claude-craft server.
|
|
101
|
+
|
|
102
|
+
```bash
|
|
103
|
+
ccraft auth sk-xxxxxxxxxxxx
|
|
104
|
+
ccraft auth sk-xxxxxxxxxxxx --server https://custom-server.example.com
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
### `ccraft install`
|
|
108
|
+
|
|
109
|
+
Generate Claude Code configuration for an existing project. The main command most users need.
|
|
110
|
+
|
|
111
|
+
```bash
|
|
112
|
+
ccraft install # Interactive mode
|
|
113
|
+
ccraft install -y # Non-interactive (accept defaults)
|
|
114
|
+
ccraft install -p nextjs # Apply a framework preset
|
|
115
|
+
ccraft install -d /path/to/project # Target a specific directory
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
**Available presets:** `nextjs`, `go-api`, `python`, `rust`, `aspnet`, `cmake`
|
|
119
|
+
|
|
120
|
+
### `ccraft create`
|
|
121
|
+
|
|
122
|
+
Scaffold a new project from scratch with Claude Code configuration built in.
|
|
123
|
+
|
|
124
|
+
```bash
|
|
125
|
+
ccraft create # Interactive mode
|
|
126
|
+
ccraft create -y --name my-app # Non-interactive with project name
|
|
127
|
+
ccraft create -y --name my-app --description "REST API for inventory management"
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
### `ccraft update`
|
|
131
|
+
|
|
132
|
+
Re-analyze your project and install new components for any stack changes. Run this after adding new frameworks or dependencies.
|
|
133
|
+
|
|
134
|
+
```bash
|
|
135
|
+
ccraft update # Re-analyze and delta install
|
|
136
|
+
ccraft update -y # Non-interactive
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
### `ccraft logout`
|
|
140
|
+
|
|
141
|
+
Remove your stored API key.
|
|
142
|
+
|
|
143
|
+
```bash
|
|
144
|
+
ccraft logout
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
## Supported Stacks
|
|
148
|
+
|
|
149
|
+
### 16 Languages
|
|
150
|
+
|
|
151
|
+
JavaScript, TypeScript, Python, Go, Rust, Java, C#, Ruby, PHP, Swift, Kotlin, Dart, SQL, Solidity, C, C++
|
|
152
|
+
|
|
153
|
+
### 80+ Frameworks
|
|
154
|
+
|
|
155
|
+
| Category | Frameworks |
|
|
156
|
+
|----------|-----------|
|
|
157
|
+
| **Web** | Next.js, React, Vue, Angular, Svelte, Astro, Nuxt, Remix, Gatsby |
|
|
158
|
+
| **Backend** | Express, Fastify, NestJS, Django, Flask, FastAPI, Gin, Echo, Fiber, Spring Boot, ASP.NET Core, Rails, Laravel, Actix, Axum |
|
|
159
|
+
| **Mobile** | React Native, Expo, Flutter, Jetpack Compose, .NET MAUI, Tauri |
|
|
160
|
+
| **Data / AI** | LangChain, LlamaIndex, PyTorch, TensorFlow, scikit-learn, Hugging Face, Pandas, Airflow, Streamlit, dbt |
|
|
161
|
+
| **Blockchain** | Hardhat, Foundry, Web3 |
|
|
162
|
+
| **Game** | Phaser, Three.js, Babylon.js, Unity, Godot, Unreal Engine, SDL, SFML |
|
|
163
|
+
| **Desktop** | Electron, Qt, GTK, Dear ImGui, wxWidgets |
|
|
164
|
+
| **Infra** | Terraform, Serverless Framework, Docker, Kubernetes |
|
|
165
|
+
| **C/C++** | CMake, Meson, Bazel, Boost, gRPC, OpenCV, FreeRTOS, ESP-IDF, Zephyr |
|
|
166
|
+
|
|
167
|
+
### Architecture Detection
|
|
168
|
+
|
|
169
|
+
Monorepo, microservices, monolith, clean architecture, hexagonal, event-driven, serverless, MVC — automatically detected and scored.
|
|
170
|
+
|
|
171
|
+
### Tool Integrations (MCP Servers)
|
|
172
|
+
|
|
173
|
+
| Platform | Integration |
|
|
174
|
+
|----------|------------|
|
|
175
|
+
| **Source Control** | GitHub, GitLab, Bitbucket, Azure DevOps |
|
|
176
|
+
| **Project Management** | Linear, Jira, ClickUp, Asana, Shortcut, Monday.com, YouTrack, Trello, Plane |
|
|
177
|
+
| **Documentation** | Notion, Confluence, Google Docs |
|
|
178
|
+
|
|
179
|
+
MCP servers are configured automatically based on your tool selections, with guided API key setup.
|
|
180
|
+
|
|
181
|
+
## Developer Roles
|
|
182
|
+
|
|
183
|
+
ccraft tailors the configuration to how **you** work, not just what your code looks like.
|
|
184
|
+
|
|
185
|
+
| Role | What Gets Optimized |
|
|
186
|
+
|------|-------------------|
|
|
187
|
+
| **Web Developer** | Frontend/backend agents, component skills, API rules |
|
|
188
|
+
| **Mobile Developer** | Platform-specific agents, build skills, device testing rules |
|
|
189
|
+
| **Game Developer** | Engine agents, performance skills, rendering rules |
|
|
190
|
+
| **Blockchain Developer** | Smart contract agents, security skills, gas optimization rules |
|
|
191
|
+
| **Embedded Developer** | Low-level agents, firmware skills, memory management rules |
|
|
192
|
+
| **DevOps** | Infrastructure agents, CI/CD skills, deployment rules |
|
|
193
|
+
| **Data Scientist** | ML agents, experiment skills, model evaluation rules |
|
|
194
|
+
| **Data Engineer** | Pipeline agents, ETL skills, data quality rules |
|
|
195
|
+
| **QA Engineer** | Testing agents, automation skills, coverage rules |
|
|
196
|
+
| **Cybersecurity** | Security agents, audit skills, vulnerability rules |
|
|
197
|
+
| **Product & Design** | Design system agents, UX skills, spec writing rules |
|
|
198
|
+
|
|
199
|
+
## Why ccraft?
|
|
200
|
+
|
|
201
|
+
| | Manual Setup | ccraft |
|
|
202
|
+
|---|---|---|
|
|
203
|
+
| **Time to configure** | 1-3 hours | 2 minutes |
|
|
204
|
+
| **Components selected** | Whatever you remember | Scored from 200+ catalog |
|
|
205
|
+
| **Role awareness** | Generic for everyone | Tailored to your role & intents |
|
|
206
|
+
| **Stack detection** | You list it yourself | Auto-detected from codebase |
|
|
207
|
+
| **MCP setup** | Read docs, copy JSON | Guided setup with key prompts |
|
|
208
|
+
| **Stays current** | Manual updates | `ccraft update` detects changes |
|
|
209
|
+
| **Architecture-aware** | If you think of it | Auto-detects patterns |
|
|
210
|
+
|
|
211
|
+
## FAQ
|
|
212
|
+
|
|
213
|
+
<details>
|
|
214
|
+
<summary><strong>Do I need Claude Code installed?</strong></summary>
|
|
215
|
+
|
|
216
|
+
Yes. ccraft generates configuration files that Claude Code uses. Install Claude Code first: `npm install -g @anthropic-ai/claude-code`
|
|
217
|
+
</details>
|
|
218
|
+
|
|
219
|
+
<details>
|
|
220
|
+
<summary><strong>What's the API key for?</strong></summary>
|
|
221
|
+
|
|
222
|
+
The API key authenticates with the claude-craft scoring server, which runs the component selection algorithm and returns your tailored configuration. It is **not** your Anthropic API key.
|
|
223
|
+
</details>
|
|
224
|
+
|
|
225
|
+
<details>
|
|
226
|
+
<summary><strong>Does it overwrite my existing .claude/ config?</strong></summary>
|
|
227
|
+
|
|
228
|
+
`ccraft install` shows you a confirmation summary before writing any files. The `update` command only adds new components — it won't remove or overwrite existing files.
|
|
229
|
+
</details>
|
|
230
|
+
|
|
231
|
+
<details>
|
|
232
|
+
<summary><strong>Can I use it without the interactive prompts?</strong></summary>
|
|
233
|
+
|
|
234
|
+
Yes. Pass `-y` (or `--yes`) to any command to accept defaults. Combine with `--preset` for fully non-interactive setup:
|
|
235
|
+
|
|
236
|
+
```bash
|
|
237
|
+
ccraft install -y -p nextjs
|
|
238
|
+
```
|
|
239
|
+
</details>
|
|
240
|
+
|
|
241
|
+
<details>
|
|
242
|
+
<summary><strong>What if my framework isn't supported?</strong></summary>
|
|
243
|
+
|
|
244
|
+
The scoring engine handles unlisted frameworks gracefully — it still detects your languages, architecture, and complexity. The component selection works at the pattern level, not just the framework level. Run `ccraft update` as support expands.
|
|
245
|
+
</details>
|
|
246
|
+
|
|
247
|
+
<details>
|
|
248
|
+
<summary><strong>Is my code sent to the server?</strong></summary>
|
|
249
|
+
|
|
250
|
+
No. Only the **analysis metadata** is sent (language distribution, framework names, architecture pattern, complexity score). Your source code never leaves your machine.
|
|
251
|
+
</details>
|
|
252
|
+
|
|
253
|
+
## Requirements
|
|
254
|
+
|
|
255
|
+
- **Node.js** >= 18
|
|
256
|
+
- **Claude Code** installed globally
|
|
257
|
+
- **API key** from claude-craft (run `ccraft auth`)
|
|
258
|
+
|
|
259
|
+
## License
|
|
260
|
+
|
|
261
|
+
[MIT](LICENSE)
|
|
262
|
+
|
|
263
|
+
---
|
|
264
|
+
|
|
265
|
+
<div align="center">
|
|
266
|
+
|
|
267
|
+
**Built for developers who want Claude Code to actually understand their project.**
|
|
268
|
+
|
|
269
|
+
[Get Started](#getting-started) • [Report a Bug](https://github.com/nicholasgriffintn/claude-craft/issues) • [Website](https://claude-craft.dev)
|
|
270
|
+
|
|
271
|
+
</div>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ccraft",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.7",
|
|
4
4
|
"description": "Intelligent Claude Code project configurator — role-aware agents, skills, rules, MCPs, and workflows",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -16,8 +16,15 @@
|
|
|
16
16
|
"keywords": [
|
|
17
17
|
"claude",
|
|
18
18
|
"claude-code",
|
|
19
|
+
"ai-coding",
|
|
20
|
+
"ai-agents",
|
|
21
|
+
"configurator",
|
|
22
|
+
"mcp",
|
|
19
23
|
"scaffolding",
|
|
20
|
-
"cli"
|
|
24
|
+
"cli",
|
|
25
|
+
"agentic",
|
|
26
|
+
"code-generation",
|
|
27
|
+
"project-setup"
|
|
21
28
|
],
|
|
22
29
|
"author": "",
|
|
23
30
|
"license": "MIT",
|
package/src/utils/preflight.js
CHANGED
|
@@ -84,7 +84,7 @@ export async function runPreflight(options = {}) {
|
|
|
84
84
|
console.log(' ' + dotPad('API key', colors.success('valid')));
|
|
85
85
|
} else {
|
|
86
86
|
console.log(' ' + dotPad('API key', colors.error('invalid')));
|
|
87
|
-
envErrors.push('API key is invalid or expired. Run: ccraft auth <new-key
|
|
87
|
+
envErrors.push('API key is invalid or expired. Run: ccraft auth <new-key>\n Get a new key at https://claude-craft.cc/');
|
|
88
88
|
}
|
|
89
89
|
} catch (err) {
|
|
90
90
|
if (err instanceof ApiError && err.code === 'NETWORK_ERROR') {
|