@axiomatic-labs/cli 1.0.3 → 1.0.4
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/lib/init.js +45 -15
- package/package.json +1 -1
package/lib/init.js
CHANGED
|
@@ -69,18 +69,56 @@ async function run() {
|
|
|
69
69
|
|
|
70
70
|
ui.done(`Axiomatic ${version} installed.`);
|
|
71
71
|
|
|
72
|
-
// Detect
|
|
73
|
-
const
|
|
74
|
-
const
|
|
75
|
-
|
|
76
|
-
const
|
|
77
|
-
|
|
72
|
+
// Detect project type: greenfield, single-stack, or multi-stack
|
|
73
|
+
const MANIFESTS = ['package.json', 'pyproject.toml', 'Gemfile', 'go.mod', 'Cargo.toml', 'composer.json'];
|
|
74
|
+
const SKIP_DIRS = new Set(['node_modules', 'vendor', '__pycache__', 'dist', 'build', '.next', '.nuxt', '.output', '.claude']);
|
|
75
|
+
|
|
76
|
+
const rootHasManifest = MANIFESTS.some((f) => fs.existsSync(path.join(process.cwd(), f)));
|
|
77
|
+
|
|
78
|
+
// Scan first-level subdirs for manifests (multi-stack detection)
|
|
79
|
+
const stackDirs = [];
|
|
80
|
+
try {
|
|
81
|
+
const entries = fs.readdirSync(process.cwd(), { withFileTypes: true });
|
|
82
|
+
for (const entry of entries) {
|
|
83
|
+
if (!entry.isDirectory() || entry.name.startsWith('.') || SKIP_DIRS.has(entry.name)) continue;
|
|
84
|
+
if (MANIFESTS.some((f) => fs.existsSync(path.join(process.cwd(), entry.name, f)))) {
|
|
85
|
+
stackDirs.push(entry.name);
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
} catch {}
|
|
89
|
+
|
|
90
|
+
const isMultiStack = stackDirs.length > 1 || (rootHasManifest && stackDirs.length > 0);
|
|
91
|
+
const isSingleStack = rootHasManifest && stackDirs.length === 0;
|
|
92
|
+
const isGreenfield = !rootHasManifest && stackDirs.length === 0;
|
|
78
93
|
|
|
79
94
|
console.log(` ${ui.BOLD}Getting started:${ui.RESET}`);
|
|
80
95
|
console.log('');
|
|
81
96
|
console.log(` 1. Run ${ui.CYAN}claude${ui.RESET} to start Claude Code`);
|
|
82
97
|
|
|
83
|
-
if (
|
|
98
|
+
if (isGreenfield) {
|
|
99
|
+
console.log(` 2. Describe what you want to build:`);
|
|
100
|
+
console.log('');
|
|
101
|
+
console.log(` ${ui.DIM}"create a SaaS landing page"${ui.RESET}`);
|
|
102
|
+
console.log(` ${ui.DIM}"build a task management app with Next.js"${ui.RESET}`);
|
|
103
|
+
console.log('');
|
|
104
|
+
console.log(` ${ui.DIM}Axiomatic will scaffold your stack, generate project-specific${ui.RESET}`);
|
|
105
|
+
console.log(` ${ui.DIM}skills, plan the architecture, and build it — all automatically.${ui.RESET}`);
|
|
106
|
+
} else if (isMultiStack) {
|
|
107
|
+
console.log(` 2. Type ${ui.CYAN}setup${ui.RESET} to detect your stacks and generate project-specific skills`);
|
|
108
|
+
console.log('');
|
|
109
|
+
ui.info(`Multi-stack project detected: ${stackDirs.join(', ')}${rootHasManifest ? ' + root' : ''}`);
|
|
110
|
+
ui.info('Setup will analyze each stack and generate specialized skills for all of them.');
|
|
111
|
+
console.log('');
|
|
112
|
+
console.log(` ${ui.BOLD}After setup:${ui.RESET}`);
|
|
113
|
+
console.log(` ${ui.DIM}Just describe what you want — Axiomatic handles the rest:${ui.RESET}`);
|
|
114
|
+
console.log(` ${ui.DIM}"add user authentication across frontend and backend"${ui.RESET}`);
|
|
115
|
+
console.log(` ${ui.DIM}"refactor the API layer"${ui.RESET}`);
|
|
116
|
+
console.log('');
|
|
117
|
+
console.log(` ${ui.BOLD}Commands:${ui.RESET}`);
|
|
118
|
+
console.log(` ${ui.CYAN}setup${ui.RESET} ${ui.DIM}Detect stacks, generate skills and agents${ui.RESET}`);
|
|
119
|
+
console.log(` ${ui.CYAN}review${ui.RESET} ${ui.DIM}Review current changes for quality, security & accessibility${ui.RESET}`);
|
|
120
|
+
} else {
|
|
121
|
+
// Single-stack existing project
|
|
84
122
|
console.log(` 2. Type ${ui.CYAN}setup${ui.RESET} to detect your stack and generate project-specific skills`);
|
|
85
123
|
console.log(` 3. Tell Claude what you want — it handles the rest`);
|
|
86
124
|
console.log('');
|
|
@@ -91,14 +129,6 @@ async function run() {
|
|
|
91
129
|
console.log(` ${ui.DIM}To build, just describe what you want:${ui.RESET}`);
|
|
92
130
|
console.log(` ${ui.DIM}"add a user authentication system"${ui.RESET}`);
|
|
93
131
|
console.log(` ${ui.DIM}"refactor the payment module"${ui.RESET}`);
|
|
94
|
-
} else {
|
|
95
|
-
console.log(` 2. Describe what you want to build:`);
|
|
96
|
-
console.log('');
|
|
97
|
-
console.log(` ${ui.DIM}"create a SaaS landing page"${ui.RESET}`);
|
|
98
|
-
console.log(` ${ui.DIM}"build a task management app with Next.js"${ui.RESET}`);
|
|
99
|
-
console.log('');
|
|
100
|
-
console.log(` ${ui.DIM}Axiomatic will scaffold your stack, generate project-specific${ui.RESET}`);
|
|
101
|
-
console.log(` ${ui.DIM}skills, plan the architecture, and build it — all automatically.${ui.RESET}`);
|
|
102
132
|
}
|
|
103
133
|
|
|
104
134
|
console.log('');
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@axiomatic-labs/cli",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"description": "AI-powered development toolkit for Claude Code. Skills, agents, hooks, and quality gates that ship production apps — not prototypes.",
|
|
5
5
|
"bin": {
|
|
6
6
|
"axiomatic": "./bin/cli.js"
|