codebakers 2.3.0 → 2.3.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/dist/index.js +331 -208
- package/installers/CodeBakers-Install.bat +207 -0
- package/installers/CodeBakers-Install.command +232 -0
- package/installers/README.md +157 -0
- package/installers/mac/assets/README.txt +31 -0
- package/installers/mac/build-mac-installer.sh +240 -0
- package/installers/windows/CodeBakers.iss +256 -0
- package/installers/windows/assets/README.txt +16 -0
- package/installers/windows/scripts/post-install.bat +15 -0
- package/package.json +1 -1
- package/src/commands/setup.ts +307 -169
- package/src/index.ts +92 -54
package/src/index.ts
CHANGED
|
@@ -30,7 +30,7 @@ import { integrateCommand, INTEGRATIONS } from './commands/integrate.js';
|
|
|
30
30
|
import { websiteCommand } from './commands/website.js';
|
|
31
31
|
import { parseNaturalLanguage } from './utils/nlp.js';
|
|
32
32
|
|
|
33
|
-
const VERSION = '2.3.
|
|
33
|
+
const VERSION = '2.3.4';
|
|
34
34
|
|
|
35
35
|
// ASCII art logo
|
|
36
36
|
const logo = `
|
|
@@ -100,33 +100,52 @@ async function showMainMenu(): Promise<void> {
|
|
|
100
100
|
// ============================================================================
|
|
101
101
|
|
|
102
102
|
async function showStartMenu(config: Config): Promise<void> {
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
103
|
+
while (true) {
|
|
104
|
+
const action = await p.select({
|
|
105
|
+
message: 'What would you like to do?',
|
|
106
|
+
options: [
|
|
107
|
+
{ value: 'website', label: '🌐 Build a website', hint: 'Describe it → AI builds it' },
|
|
108
|
+
{ value: 'new', label: '🆕 Create new project', hint: 'Start fresh with Next.js, React, etc.' },
|
|
109
|
+
{ value: 'prd-maker', label: '✏️ Create a PRD', hint: 'Plan your project first' },
|
|
110
|
+
{ value: 'build', label: '🏗️ Build from PRD', hint: 'Have a PRD file? Build it now' },
|
|
111
|
+
{ value: 'advisors', label: '🌟 Consult advisors', hint: 'Get advice from AI experts' },
|
|
112
|
+
{ value: 'divider1', label: chalk.dim('─────────────────────────────') },
|
|
113
|
+
{ value: 'integrate', label: '🔌 Add integration', hint: 'Stripe, Supabase, Twilio, etc.' },
|
|
114
|
+
{ value: 'settings', label: '⚙️ Settings', hint: 'API keys & preferences' },
|
|
115
|
+
{ value: 'help', label: '❓ Help', hint: 'Learn how to use CodeBakers' },
|
|
116
|
+
{ value: 'divider2', label: chalk.dim('─────────────────────────────') },
|
|
117
|
+
{ value: 'exit', label: '🚪 Return to terminal', hint: 'Exit CodeBakers' },
|
|
118
|
+
],
|
|
119
|
+
});
|
|
120
|
+
|
|
121
|
+
// User pressed Ctrl+C or selected exit
|
|
122
|
+
if (p.isCancel(action) || action === 'exit') {
|
|
123
|
+
console.log('');
|
|
124
|
+
console.log(chalk.cyan(' ─────────────────────────────────────────────────'));
|
|
125
|
+
console.log(chalk.white(' You\'re back in the terminal.'));
|
|
126
|
+
console.log('');
|
|
127
|
+
console.log(chalk.dim(' To start CodeBakers again, type:'));
|
|
128
|
+
console.log(chalk.green(' codebakers'));
|
|
129
|
+
console.log('');
|
|
130
|
+
console.log(chalk.dim(' Quick commands you can run directly:'));
|
|
131
|
+
console.log(chalk.dim(' codebakers website') + chalk.gray(' - Build a website'));
|
|
132
|
+
console.log(chalk.dim(' codebakers code') + chalk.gray(' - Code with AI'));
|
|
133
|
+
console.log(chalk.dim(' codebakers help') + chalk.gray(' - See all commands'));
|
|
134
|
+
console.log(chalk.cyan(' ─────────────────────────────────────────────────'));
|
|
135
|
+
console.log('');
|
|
136
|
+
process.exit(0);
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
// Handle dividers - just continue the loop
|
|
140
|
+
if (action === 'divider1' || action === 'divider2') {
|
|
141
|
+
continue;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
// Handle the selected action
|
|
145
|
+
await handleAction(action as string, config);
|
|
146
|
+
|
|
147
|
+
// After action completes, loop back to show menu again
|
|
127
148
|
}
|
|
128
|
-
|
|
129
|
-
await handleAction(action as string, config);
|
|
130
149
|
}
|
|
131
150
|
|
|
132
151
|
// ============================================================================
|
|
@@ -134,34 +153,53 @@ async function showStartMenu(config: Config): Promise<void> {
|
|
|
134
153
|
// ============================================================================
|
|
135
154
|
|
|
136
155
|
async function showProjectMenu(config: Config): Promise<void> {
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
156
|
+
while (true) {
|
|
157
|
+
const action = await p.select({
|
|
158
|
+
message: 'What would you like to do?',
|
|
159
|
+
options: [
|
|
160
|
+
{ value: 'code', label: '💬 Code with AI', hint: 'Ask AI to build features or fix bugs' },
|
|
161
|
+
{ value: 'deploy', label: '🚀 Deploy', hint: 'Push your project live' },
|
|
162
|
+
{ value: 'check', label: '🔍 Check code', hint: 'Review quality & patterns' },
|
|
163
|
+
{ value: 'fix', label: '🔧 Fix errors', hint: 'AI automatically fixes issues' },
|
|
164
|
+
{ value: 'integrate', label: '🔌 Add integration', hint: 'Stripe, Supabase, Twilio, etc.' },
|
|
165
|
+
{ value: 'generate', label: '⚡ Generate', hint: 'Create components, pages, APIs' },
|
|
166
|
+
{ value: 'divider1', label: chalk.dim('─────────────────────────────') },
|
|
167
|
+
{ value: 'new', label: '🆕 Start new project', hint: 'Create a different project' },
|
|
168
|
+
{ value: 'settings', label: '⚙️ Settings', hint: 'API keys & preferences' },
|
|
169
|
+
{ value: 'help', label: '❓ Help', hint: 'Learn how to use CodeBakers' },
|
|
170
|
+
{ value: 'divider2', label: chalk.dim('─────────────────────────────') },
|
|
171
|
+
{ value: 'exit', label: '🚪 Return to terminal', hint: 'Exit CodeBakers' },
|
|
172
|
+
],
|
|
173
|
+
});
|
|
174
|
+
|
|
175
|
+
// User pressed Ctrl+C or selected exit
|
|
176
|
+
if (p.isCancel(action) || action === 'exit') {
|
|
177
|
+
console.log('');
|
|
178
|
+
console.log(chalk.cyan(' ─────────────────────────────────────────────────'));
|
|
179
|
+
console.log(chalk.white(' You\'re back in the terminal.'));
|
|
180
|
+
console.log('');
|
|
181
|
+
console.log(chalk.dim(' To start CodeBakers again, type:'));
|
|
182
|
+
console.log(chalk.green(' codebakers'));
|
|
183
|
+
console.log('');
|
|
184
|
+
console.log(chalk.dim(' Quick commands you can run directly:'));
|
|
185
|
+
console.log(chalk.dim(' codebakers code') + chalk.gray(' - Code with AI'));
|
|
186
|
+
console.log(chalk.dim(' codebakers deploy') + chalk.gray(' - Deploy your project'));
|
|
187
|
+
console.log(chalk.dim(' codebakers help') + chalk.gray(' - See all commands'));
|
|
188
|
+
console.log(chalk.cyan(' ─────────────────────────────────────────────────'));
|
|
189
|
+
console.log('');
|
|
190
|
+
process.exit(0);
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
// Handle dividers - just continue the loop
|
|
194
|
+
if (action === 'divider1' || action === 'divider2') {
|
|
195
|
+
continue;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
// Handle the selected action
|
|
199
|
+
await handleAction(action as string, config);
|
|
200
|
+
|
|
201
|
+
// After action completes, loop back to show menu again
|
|
162
202
|
}
|
|
163
|
-
|
|
164
|
-
await handleAction(action as string, config);
|
|
165
203
|
}
|
|
166
204
|
|
|
167
205
|
// ============================================================================
|