@aiconstructions/claude-kit 1.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/LICENSE +21 -0
- package/README.md +70 -0
- package/bin/cli.js +21 -0
- package/package.json +51 -0
- package/src/generator.js +81 -0
- package/src/index.js +94 -0
- package/src/plugin-installer.js +85 -0
- package/src/prompts.js +122 -0
- package/templates/agents/analyzer.md.ejs +282 -0
- package/templates/agents/asana.md.ejs +171 -0
- package/templates/agents/backend.md.ejs +657 -0
- package/templates/agents/cicd.md.ejs +586 -0
- package/templates/agents/frontend.md.ejs +249 -0
- package/templates/agents/git.md.ejs +248 -0
- package/templates/agents/manager.md.ejs +142 -0
- package/templates/agents/n8n.md.ejs +262 -0
- package/templates/agents/offline.md.ejs +201 -0
- package/templates/agents/planner.md.ejs +355 -0
- package/templates/agents/qa.md.ejs +337 -0
- package/templates/agents/security.md.ejs +356 -0
- package/templates/base/.claude/context/AGENT_CONTEXT.md.ejs +60 -0
- package/templates/base/.claude/context/api-spec.md +34 -0
- package/templates/base/.claude/context/infra-state.md +21 -0
- package/templates/base/.claude/context/test-report.md +11 -0
- package/templates/base/CLAUDE.md.ejs +230 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 aiconstructions
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# @aiconstructions/claude-kit
|
|
2
|
+
|
|
3
|
+
Interactive CLI to scaffold a multi-agent Claude Code workspace for your project.
|
|
4
|
+
|
|
5
|
+
## Quick Start
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npx @aiconstructions/claude-kit
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## What You Get
|
|
12
|
+
|
|
13
|
+
A fully configured Claude Code workspace with:
|
|
14
|
+
|
|
15
|
+
- **CLAUDE.md** — Master orchestration guide adapted to your stack
|
|
16
|
+
- **12 specialist agents** — manager, planner, backend, frontend, qa, security, analyzer, git, offline, cicd, asana, n8n (included based on your selections)
|
|
17
|
+
- **Shared context files** — API spec, infrastructure state, test reports
|
|
18
|
+
- **Plugin auto-install** — Superpowers, GSD, ui-ux-pro-max
|
|
19
|
+
|
|
20
|
+
## Supported Stacks
|
|
21
|
+
|
|
22
|
+
### Mobile
|
|
23
|
+
- Expo + React Native + NativeWind
|
|
24
|
+
- Flutter
|
|
25
|
+
|
|
26
|
+
### Web
|
|
27
|
+
- React + Vite + Tailwind CSS
|
|
28
|
+
- Next.js
|
|
29
|
+
- Nuxt.js
|
|
30
|
+
- Svelte
|
|
31
|
+
|
|
32
|
+
### Backend
|
|
33
|
+
- Python + FastAPI + SQLAlchemy
|
|
34
|
+
- Python + Django
|
|
35
|
+
- Node.js + Express
|
|
36
|
+
- Node.js + NestJS
|
|
37
|
+
|
|
38
|
+
### Integrations
|
|
39
|
+
- GitHub Actions (CI/CD)
|
|
40
|
+
- AWS (EC2, RDS, S3, CloudFront)
|
|
41
|
+
- Asana
|
|
42
|
+
- n8n
|
|
43
|
+
|
|
44
|
+
## Prerequisites
|
|
45
|
+
|
|
46
|
+
- Node.js >= 18
|
|
47
|
+
- [Claude Code CLI](https://docs.anthropic.com/en/docs/claude-code) (for Superpowers plugin install)
|
|
48
|
+
|
|
49
|
+
## Options
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
npx @aiconstructions/claude-kit [directory] [options]
|
|
53
|
+
|
|
54
|
+
Options:
|
|
55
|
+
--no-plugins Skip plugin installation
|
|
56
|
+
-V, --version Output version number
|
|
57
|
+
-h, --help Display help
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## Plugins Installed
|
|
61
|
+
|
|
62
|
+
| Plugin | Source | Method |
|
|
63
|
+
|--------|--------|--------|
|
|
64
|
+
| [Superpowers](https://github.com/obra/superpowers) | Claude Plugin Marketplace | `claude plugin install` |
|
|
65
|
+
| [GSD](https://github.com/gsd-build/get-shit-done) | npm | `npx get-shit-done-cc` |
|
|
66
|
+
| [ui-ux-pro-max](https://github.com/nextlevelbuilder/ui-ux-pro-max-skill) | GitHub | Direct download |
|
|
67
|
+
|
|
68
|
+
## License
|
|
69
|
+
|
|
70
|
+
MIT
|
package/bin/cli.js
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
import { program } from 'commander';
|
|
4
|
+
import { run } from '../src/index.js';
|
|
5
|
+
|
|
6
|
+
program
|
|
7
|
+
.name('claude-kit')
|
|
8
|
+
.description('Scaffold a multi-agent Claude Code workspace')
|
|
9
|
+
.version('1.0.0')
|
|
10
|
+
.argument('[directory]', 'target directory (defaults to current)')
|
|
11
|
+
.option('--no-plugins', 'skip plugin installation')
|
|
12
|
+
.action(async (directory, options) => {
|
|
13
|
+
try {
|
|
14
|
+
await run({ directory, skipPlugins: !options.plugins });
|
|
15
|
+
} catch (err) {
|
|
16
|
+
console.error(err.message);
|
|
17
|
+
process.exit(1);
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
program.parse();
|
package/package.json
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@aiconstructions/claude-kit",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "Interactive CLI to scaffold a multi-agent Claude Code workspace",
|
|
5
|
+
"bin": {
|
|
6
|
+
"claude-kit": "./bin/cli.js"
|
|
7
|
+
},
|
|
8
|
+
"main": "src/index.js",
|
|
9
|
+
"type": "module",
|
|
10
|
+
"engines": {
|
|
11
|
+
"node": ">=18"
|
|
12
|
+
},
|
|
13
|
+
"scripts": {
|
|
14
|
+
"test": "node --experimental-vm-modules ./node_modules/jest/bin/jest.js",
|
|
15
|
+
"lint": "eslint src/"
|
|
16
|
+
},
|
|
17
|
+
"keywords": [
|
|
18
|
+
"claude",
|
|
19
|
+
"claude-code",
|
|
20
|
+
"ai",
|
|
21
|
+
"agents",
|
|
22
|
+
"scaffolding",
|
|
23
|
+
"cli"
|
|
24
|
+
],
|
|
25
|
+
"author": "aiconstructions",
|
|
26
|
+
"license": "MIT",
|
|
27
|
+
"publishConfig": {
|
|
28
|
+
"access": "public",
|
|
29
|
+
"registry": "https://registry.npmjs.org/"
|
|
30
|
+
},
|
|
31
|
+
"dependencies": {
|
|
32
|
+
"chalk": "^5.3.0",
|
|
33
|
+
"commander": "^12.1.0",
|
|
34
|
+
"ejs": "^3.1.10",
|
|
35
|
+
"fs-extra": "^11.2.0",
|
|
36
|
+
"giget": "^1.2.3",
|
|
37
|
+
"inquirer": "^9.3.0",
|
|
38
|
+
"ora": "^8.1.0"
|
|
39
|
+
},
|
|
40
|
+
"devDependencies": {
|
|
41
|
+
"jest": "^29.7.0",
|
|
42
|
+
"@jest/globals": "^29.7.0"
|
|
43
|
+
},
|
|
44
|
+
"files": [
|
|
45
|
+
"bin/",
|
|
46
|
+
"src/",
|
|
47
|
+
"templates/",
|
|
48
|
+
"README.md",
|
|
49
|
+
"LICENSE"
|
|
50
|
+
]
|
|
51
|
+
}
|
package/src/generator.js
ADDED
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
// src/generator.js
|
|
2
|
+
import fs from 'fs-extra';
|
|
3
|
+
import path from 'path';
|
|
4
|
+
import ejs from 'ejs';
|
|
5
|
+
import { fileURLToPath } from 'url';
|
|
6
|
+
|
|
7
|
+
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
8
|
+
const TEMPLATES_DIR = path.join(__dirname, '..', 'templates');
|
|
9
|
+
|
|
10
|
+
const AGENT_RULES = {
|
|
11
|
+
'manager.md.ejs': () => true,
|
|
12
|
+
'planner.md.ejs': () => true,
|
|
13
|
+
'analyzer.md.ejs': () => true,
|
|
14
|
+
'qa.md.ejs': () => true,
|
|
15
|
+
'security.md.ejs': () => true,
|
|
16
|
+
'git.md.ejs': () => true,
|
|
17
|
+
'backend.md.ejs': (vars) => vars.modules.backend,
|
|
18
|
+
'frontend.md.ejs': (vars) => vars.modules.mobile || vars.modules.web,
|
|
19
|
+
'offline.md.ejs': (vars) => vars.modules.mobile,
|
|
20
|
+
'cicd.md.ejs': (vars) => vars.integrations.cicd,
|
|
21
|
+
'asana.md.ejs': (vars) => vars.integrations.asana,
|
|
22
|
+
'n8n.md.ejs': (vars) => vars.integrations.n8n,
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
async function renderTemplate(templatePath, vars) {
|
|
26
|
+
const template = await fs.readFile(templatePath, 'utf8');
|
|
27
|
+
return ejs.render(template, vars, { filename: templatePath });
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
async function copyStatic(src, dest) {
|
|
31
|
+
await fs.ensureDir(path.dirname(dest));
|
|
32
|
+
await fs.copyFile(src, dest);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export async function generate(targetDir, vars) {
|
|
36
|
+
await fs.ensureDir(targetDir);
|
|
37
|
+
|
|
38
|
+
// 1. Render CLAUDE.md
|
|
39
|
+
const claudeContent = await renderTemplate(
|
|
40
|
+
path.join(TEMPLATES_DIR, 'base', 'CLAUDE.md.ejs'),
|
|
41
|
+
vars
|
|
42
|
+
);
|
|
43
|
+
await fs.writeFile(path.join(targetDir, 'CLAUDE.md'), claudeContent);
|
|
44
|
+
|
|
45
|
+
// 2. Render AGENT_CONTEXT.md
|
|
46
|
+
const contextDir = path.join(targetDir, '.claude', 'context');
|
|
47
|
+
await fs.ensureDir(contextDir);
|
|
48
|
+
|
|
49
|
+
const agentCtxContent = await renderTemplate(
|
|
50
|
+
path.join(TEMPLATES_DIR, 'base', '.claude', 'context', 'AGENT_CONTEXT.md.ejs'),
|
|
51
|
+
vars
|
|
52
|
+
);
|
|
53
|
+
await fs.writeFile(path.join(contextDir, 'AGENT_CONTEXT.md'), agentCtxContent);
|
|
54
|
+
|
|
55
|
+
// 3. Copy static context files
|
|
56
|
+
const staticContextFiles = ['api-spec.md', 'infra-state.md', 'test-report.md'];
|
|
57
|
+
for (const file of staticContextFiles) {
|
|
58
|
+
await copyStatic(
|
|
59
|
+
path.join(TEMPLATES_DIR, 'base', '.claude', 'context', file),
|
|
60
|
+
path.join(contextDir, file)
|
|
61
|
+
);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
// 4. Render agent templates based on inclusion rules
|
|
65
|
+
const agentsDir = path.join(targetDir, '.claude', 'agents');
|
|
66
|
+
await fs.ensureDir(agentsDir);
|
|
67
|
+
|
|
68
|
+
for (const [templateFile, shouldInclude] of Object.entries(AGENT_RULES)) {
|
|
69
|
+
if (shouldInclude(vars)) {
|
|
70
|
+
const content = await renderTemplate(
|
|
71
|
+
path.join(TEMPLATES_DIR, 'agents', templateFile),
|
|
72
|
+
vars
|
|
73
|
+
);
|
|
74
|
+
const outputName = templateFile.replace('.ejs', '');
|
|
75
|
+
await fs.writeFile(path.join(agentsDir, outputName), content);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
// Export for testing
|
|
81
|
+
export { AGENT_RULES };
|
package/src/index.js
ADDED
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
// src/index.js
|
|
2
|
+
import inquirer from 'inquirer';
|
|
3
|
+
import chalk from 'chalk';
|
|
4
|
+
import ora from 'ora';
|
|
5
|
+
import path from 'path';
|
|
6
|
+
import fs from 'fs-extra';
|
|
7
|
+
import { buildPromptConfig, normalizeAnswers } from './prompts.js';
|
|
8
|
+
import { generate } from './generator.js';
|
|
9
|
+
import { installPlugins, checkPrerequisites } from './plugin-installer.js';
|
|
10
|
+
|
|
11
|
+
function printBanner() {
|
|
12
|
+
console.log('');
|
|
13
|
+
console.log(chalk.bold.cyan(' AIC Claude Kit'));
|
|
14
|
+
console.log(chalk.dim(' Multi-Agent Setup CLI'));
|
|
15
|
+
console.log('');
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export async function run({ directory, skipPlugins = false } = {}) {
|
|
19
|
+
printBanner();
|
|
20
|
+
|
|
21
|
+
// Interactive prompts
|
|
22
|
+
const prompts = buildPromptConfig();
|
|
23
|
+
const rawAnswers = await inquirer.prompt(prompts);
|
|
24
|
+
const vars = normalizeAnswers(rawAnswers);
|
|
25
|
+
|
|
26
|
+
// Resolve target directory
|
|
27
|
+
const targetDir = path.resolve(directory || vars.projectName);
|
|
28
|
+
|
|
29
|
+
// Check if directory exists and has .claude
|
|
30
|
+
if (await fs.pathExists(path.join(targetDir, '.claude'))) {
|
|
31
|
+
const { overwrite } = await inquirer.prompt([{
|
|
32
|
+
type: 'confirm',
|
|
33
|
+
name: 'overwrite',
|
|
34
|
+
message: `${targetDir} already has a .claude/ directory. Overwrite?`,
|
|
35
|
+
default: false
|
|
36
|
+
}]);
|
|
37
|
+
if (!overwrite) {
|
|
38
|
+
console.log(chalk.yellow('Aborted.'));
|
|
39
|
+
return;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
// Scaffold
|
|
44
|
+
const scaffoldSpinner = ora('Scaffolding project...').start();
|
|
45
|
+
try {
|
|
46
|
+
await generate(targetDir, vars);
|
|
47
|
+
scaffoldSpinner.succeed('Project scaffolded');
|
|
48
|
+
} catch (err) {
|
|
49
|
+
scaffoldSpinner.fail('Scaffolding failed');
|
|
50
|
+
throw err;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
// Plugin installation
|
|
54
|
+
if (!skipPlugins) {
|
|
55
|
+
const prereqs = checkPrerequisites();
|
|
56
|
+
|
|
57
|
+
if (!prereqs.claude && vars.plugins.superpowers) {
|
|
58
|
+
console.log(chalk.yellow(' Warning: claude CLI not found in PATH — Superpowers will be skipped'));
|
|
59
|
+
vars.plugins.superpowers = false;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
let activeSpinner = null;
|
|
63
|
+
|
|
64
|
+
await installPlugins(targetDir, vars.plugins, {
|
|
65
|
+
onStart: (name) => {
|
|
66
|
+
activeSpinner = ora(`Installing ${name}...`).start();
|
|
67
|
+
},
|
|
68
|
+
onDone: (name) => {
|
|
69
|
+
if (activeSpinner) {
|
|
70
|
+
activeSpinner.succeed(`${name} installed`);
|
|
71
|
+
activeSpinner = null;
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
onError: (name, error) => {
|
|
75
|
+
if (activeSpinner) {
|
|
76
|
+
activeSpinner.warn(`${name} failed: ${error}`);
|
|
77
|
+
activeSpinner = null;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
});
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
// Done
|
|
84
|
+
console.log('');
|
|
85
|
+
console.log(chalk.green.bold('Your project is ready!'));
|
|
86
|
+
|
|
87
|
+
const relPath = path.relative(process.cwd(), targetDir);
|
|
88
|
+
if (relPath && relPath !== '.') {
|
|
89
|
+
console.log(chalk.dim(` cd ${relPath} && claude`));
|
|
90
|
+
} else {
|
|
91
|
+
console.log(chalk.dim(' claude'));
|
|
92
|
+
}
|
|
93
|
+
console.log('');
|
|
94
|
+
}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import { execSync } from 'child_process';
|
|
2
|
+
import path from 'path';
|
|
3
|
+
|
|
4
|
+
export function getInstallCommands(targetDir, plugins) {
|
|
5
|
+
const commands = [];
|
|
6
|
+
|
|
7
|
+
if (plugins.superpowers) {
|
|
8
|
+
commands.push({
|
|
9
|
+
name: 'Superpowers',
|
|
10
|
+
type: 'exec',
|
|
11
|
+
command: 'claude plugin install superpowers@claude-plugins-official'
|
|
12
|
+
});
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
if (plugins.gsd) {
|
|
16
|
+
commands.push({
|
|
17
|
+
name: 'GSD',
|
|
18
|
+
type: 'exec',
|
|
19
|
+
command: 'npx get-shit-done-cc@latest --claude --local'
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
if (plugins.uiUxProMax) {
|
|
24
|
+
commands.push({
|
|
25
|
+
name: 'ui-ux-pro-max',
|
|
26
|
+
type: 'giget',
|
|
27
|
+
source: 'github:nextlevelbuilder/ui-ux-pro-max-skill',
|
|
28
|
+
dest: path.join(targetDir, '.claude', 'skills', 'ui-ux-pro-max')
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
return commands;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export function checkPrerequisites() {
|
|
36
|
+
const results = { node: false, claude: false };
|
|
37
|
+
|
|
38
|
+
try {
|
|
39
|
+
const nodeVersion = execSync('node --version', { encoding: 'utf8' }).trim();
|
|
40
|
+
const major = parseInt(nodeVersion.replace('v', '').split('.')[0], 10);
|
|
41
|
+
results.node = major >= 18;
|
|
42
|
+
} catch {
|
|
43
|
+
results.node = false;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
try {
|
|
47
|
+
execSync('claude --version', { encoding: 'utf8', stdio: 'pipe' });
|
|
48
|
+
results.claude = true;
|
|
49
|
+
} catch {
|
|
50
|
+
results.claude = false;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
return results;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export async function installPlugins(targetDir, plugins, { onStart, onDone, onError } = {}) {
|
|
57
|
+
const commands = getInstallCommands(targetDir, plugins);
|
|
58
|
+
const results = [];
|
|
59
|
+
|
|
60
|
+
for (const cmd of commands) {
|
|
61
|
+
onStart?.(cmd.name);
|
|
62
|
+
|
|
63
|
+
try {
|
|
64
|
+
if (cmd.type === 'exec') {
|
|
65
|
+
execSync(cmd.command, {
|
|
66
|
+
cwd: targetDir,
|
|
67
|
+
encoding: 'utf8',
|
|
68
|
+
stdio: 'pipe',
|
|
69
|
+
timeout: 120_000
|
|
70
|
+
});
|
|
71
|
+
} else if (cmd.type === 'giget') {
|
|
72
|
+
const { downloadTemplate } = await import('giget');
|
|
73
|
+
await downloadTemplate(cmd.source, { dir: cmd.dest, force: true });
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
onDone?.(cmd.name);
|
|
77
|
+
results.push({ name: cmd.name, success: true });
|
|
78
|
+
} catch (err) {
|
|
79
|
+
onError?.(cmd.name, err.message);
|
|
80
|
+
results.push({ name: cmd.name, success: false, error: err.message });
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
return results;
|
|
85
|
+
}
|
package/src/prompts.js
ADDED
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
// src/prompts.js
|
|
2
|
+
|
|
3
|
+
export const FRAMEWORK_OPTIONS = {
|
|
4
|
+
mobile: [
|
|
5
|
+
{ name: 'Expo + React Native + NativeWind', value: 'expo-rn-nativewind' },
|
|
6
|
+
{ name: 'Flutter', value: 'flutter' }
|
|
7
|
+
],
|
|
8
|
+
web: [
|
|
9
|
+
{ name: 'React + Vite + Tailwind CSS', value: 'react-vite-tailwind' },
|
|
10
|
+
{ name: 'Next.js', value: 'nextjs' },
|
|
11
|
+
{ name: 'Nuxt.js', value: 'nuxtjs' },
|
|
12
|
+
{ name: 'Svelte', value: 'svelte' }
|
|
13
|
+
],
|
|
14
|
+
backend: [
|
|
15
|
+
{ name: 'Python + FastAPI + SQLAlchemy', value: 'fastapi-sqlalchemy' },
|
|
16
|
+
{ name: 'Python + Django', value: 'django' },
|
|
17
|
+
{ name: 'Node.js + Express', value: 'express' },
|
|
18
|
+
{ name: 'Node.js + NestJS', value: 'nestjs' }
|
|
19
|
+
]
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
export const INTEGRATION_OPTIONS = [
|
|
23
|
+
{ name: 'GitHub Actions (CI/CD)', value: 'cicd', checked: true },
|
|
24
|
+
{ name: 'AWS (EC2, RDS, S3, CloudFront)', value: 'aws' },
|
|
25
|
+
{ name: 'Asana', value: 'asana' },
|
|
26
|
+
{ name: 'n8n (automation)', value: 'n8n' }
|
|
27
|
+
];
|
|
28
|
+
|
|
29
|
+
export const PLUGIN_OPTIONS = [
|
|
30
|
+
{ name: 'Superpowers (skills & workflows)', value: 'superpowers', checked: true },
|
|
31
|
+
{ name: 'GSD (Get Shit Done)', value: 'gsd', checked: true },
|
|
32
|
+
{ name: 'ui-ux-pro-max (design intelligence)', value: 'uiUxProMax', checked: true }
|
|
33
|
+
];
|
|
34
|
+
|
|
35
|
+
export function buildPromptConfig() {
|
|
36
|
+
return [
|
|
37
|
+
{
|
|
38
|
+
type: 'input',
|
|
39
|
+
name: 'projectName',
|
|
40
|
+
message: 'Project name:',
|
|
41
|
+
default: 'my-app',
|
|
42
|
+
validate: (input) => {
|
|
43
|
+
if (!input.trim()) return 'Project name is required';
|
|
44
|
+
if (/[^a-zA-Z0-9-_]/.test(input)) return 'Use only letters, numbers, hyphens, underscores';
|
|
45
|
+
return true;
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
type: 'checkbox',
|
|
50
|
+
name: 'modules',
|
|
51
|
+
message: 'Select your modules:',
|
|
52
|
+
choices: [
|
|
53
|
+
{ name: 'Mobile', value: 'mobile' },
|
|
54
|
+
{ name: 'Web', value: 'web' },
|
|
55
|
+
{ name: 'Backend', value: 'backend' }
|
|
56
|
+
],
|
|
57
|
+
validate: (input) => input.length > 0 ? true : 'Select at least one module'
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
type: 'list',
|
|
61
|
+
name: 'mobileFramework',
|
|
62
|
+
message: 'Mobile framework:',
|
|
63
|
+
choices: FRAMEWORK_OPTIONS.mobile,
|
|
64
|
+
when: (answers) => answers.modules.includes('mobile')
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
type: 'list',
|
|
68
|
+
name: 'webFramework',
|
|
69
|
+
message: 'Web framework:',
|
|
70
|
+
choices: FRAMEWORK_OPTIONS.web,
|
|
71
|
+
when: (answers) => answers.modules.includes('web')
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
type: 'list',
|
|
75
|
+
name: 'backendFramework',
|
|
76
|
+
message: 'Backend framework:',
|
|
77
|
+
choices: FRAMEWORK_OPTIONS.backend,
|
|
78
|
+
when: (answers) => answers.modules.includes('backend')
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
type: 'checkbox',
|
|
82
|
+
name: 'integrations',
|
|
83
|
+
message: 'Integrations:',
|
|
84
|
+
choices: INTEGRATION_OPTIONS
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
type: 'checkbox',
|
|
88
|
+
name: 'plugins',
|
|
89
|
+
message: 'Install plugins:',
|
|
90
|
+
choices: PLUGIN_OPTIONS
|
|
91
|
+
}
|
|
92
|
+
];
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
export function normalizeAnswers(answers) {
|
|
96
|
+
const hasMobile = answers.modules.includes('mobile');
|
|
97
|
+
const hasWeb = answers.modules.includes('web');
|
|
98
|
+
const hasBackend = answers.modules.includes('backend');
|
|
99
|
+
|
|
100
|
+
return {
|
|
101
|
+
projectName: answers.projectName,
|
|
102
|
+
modules: {
|
|
103
|
+
mobile: hasMobile,
|
|
104
|
+
web: hasWeb,
|
|
105
|
+
backend: hasBackend
|
|
106
|
+
},
|
|
107
|
+
mobileFramework: answers.mobileFramework || null,
|
|
108
|
+
webFramework: answers.webFramework || null,
|
|
109
|
+
backendFramework: answers.backendFramework || null,
|
|
110
|
+
integrations: {
|
|
111
|
+
cicd: answers.integrations.includes('cicd'),
|
|
112
|
+
aws: answers.integrations.includes('aws'),
|
|
113
|
+
asana: answers.integrations.includes('asana'),
|
|
114
|
+
n8n: answers.integrations.includes('n8n')
|
|
115
|
+
},
|
|
116
|
+
plugins: {
|
|
117
|
+
superpowers: answers.plugins.includes('superpowers'),
|
|
118
|
+
gsd: answers.plugins.includes('gsd'),
|
|
119
|
+
uiUxProMax: answers.plugins.includes('uiUxProMax')
|
|
120
|
+
}
|
|
121
|
+
};
|
|
122
|
+
}
|