fraim-framework 1.0.5 ā 1.0.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/package.json +1 -1
- package/setup.js +49 -10
package/package.json
CHANGED
package/setup.js
CHANGED
|
@@ -128,6 +128,30 @@ function createGitHubLabels() {
|
|
|
128
128
|
logSuccess('GitHub labels created');
|
|
129
129
|
}
|
|
130
130
|
|
|
131
|
+
function createLabelsConfigFile() {
|
|
132
|
+
const labels = [
|
|
133
|
+
{ name: 'phase:design', color: '0e8a16', description: 'Design phase - RFC creation and review' },
|
|
134
|
+
{ name: 'phase:impl', color: '1d76db', description: 'Implementation phase - coding and testing' },
|
|
135
|
+
{ name: 'phase:tests', color: 'fef2c0', description: 'Testing phase - validation and QA' },
|
|
136
|
+
{ name: 'status:wip', color: 'fbca04', description: 'Work in progress' },
|
|
137
|
+
{ name: 'status:needs-review', color: 'd93f0b', description: 'Ready for review' },
|
|
138
|
+
{ name: 'status:complete', color: '0e8a16', description: 'Completed and approved' },
|
|
139
|
+
{ name: 'status:approved', color: '0e8a16', description: 'Approved and ready to merge' },
|
|
140
|
+
{ name: 'status:changes-requested', color: 'd93f0b', description: 'Changes requested in review' },
|
|
141
|
+
{ name: 'ai-agent:cursor', color: '5319e7', description: 'Assigned to Cursor AI agent' },
|
|
142
|
+
{ name: 'ai-agent:claude', color: 'c2e0c6', description: 'Assigned to Claude AI agent' },
|
|
143
|
+
{ name: 'ai-agent:windsurf', color: 'bfdadc', description: 'Assigned to Windsurf AI agent' }
|
|
144
|
+
];
|
|
145
|
+
|
|
146
|
+
const labelsContent = JSON.stringify(labels, null, 2);
|
|
147
|
+
writeFile('.github/labels.json', labelsContent);
|
|
148
|
+
|
|
149
|
+
logSuccess('GitHub labels configuration file created');
|
|
150
|
+
logInfo('You can import these labels using:');
|
|
151
|
+
logInfo('1. GitHub web interface: Settings > Labels > Import labels');
|
|
152
|
+
logInfo('2. Or manually create each label with the provided colors and descriptions');
|
|
153
|
+
}
|
|
154
|
+
|
|
131
155
|
function createGitHubWorkflows() {
|
|
132
156
|
// Phase change workflow
|
|
133
157
|
const phaseChangeWorkflow = `name: Phase Change Automation
|
|
@@ -259,13 +283,16 @@ async function runWizard() {
|
|
|
259
283
|
logStep('Step 1: Checking Prerequisites');
|
|
260
284
|
|
|
261
285
|
// Check if gh CLI is available
|
|
286
|
+
let ghAvailable = false;
|
|
262
287
|
try {
|
|
263
288
|
execSync('gh --version', { stdio: 'pipe' });
|
|
264
289
|
logSuccess('GitHub CLI (gh) is available');
|
|
290
|
+
ghAvailable = true;
|
|
265
291
|
} catch (error) {
|
|
266
|
-
|
|
267
|
-
logInfo('
|
|
268
|
-
|
|
292
|
+
logWarning('GitHub CLI (gh) is not installed or not available');
|
|
293
|
+
logInfo('You can still set up FRAIM, but GitHub labels will need to be created manually');
|
|
294
|
+
logInfo('Install GitHub CLI: https://cli.github.com/');
|
|
295
|
+
ghAvailable = false;
|
|
269
296
|
}
|
|
270
297
|
|
|
271
298
|
// Check if we're in a git repository
|
|
@@ -301,12 +328,17 @@ async function runWizard() {
|
|
|
301
328
|
|
|
302
329
|
// Step 4: GitHub Labels
|
|
303
330
|
logStep('Step 4: GitHub Labels');
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
331
|
+
if (ghAvailable) {
|
|
332
|
+
const setupLabels = await askQuestion('Would you like to create GitHub labels for FRAIM?', 'y');
|
|
333
|
+
|
|
334
|
+
if (setupLabels === 'y' || setupLabels === 'yes') {
|
|
335
|
+
createGitHubLabels();
|
|
336
|
+
} else {
|
|
337
|
+
logInfo('Skipping GitHub label setup');
|
|
338
|
+
}
|
|
308
339
|
} else {
|
|
309
|
-
logInfo('
|
|
340
|
+
logInfo('GitHub CLI not available - creating labels configuration file instead');
|
|
341
|
+
createLabelsConfigFile();
|
|
310
342
|
}
|
|
311
343
|
|
|
312
344
|
// Step 5: Summary
|
|
@@ -315,8 +347,15 @@ async function runWizard() {
|
|
|
315
347
|
logSuccess('FRAIM has been successfully set up in your repository!');
|
|
316
348
|
logInfo('Next steps:');
|
|
317
349
|
logInfo('1. Commit and push these files to GitHub');
|
|
318
|
-
|
|
319
|
-
|
|
350
|
+
|
|
351
|
+
if (ghAvailable) {
|
|
352
|
+
logInfo('2. GitHub labels have been created automatically');
|
|
353
|
+
} else {
|
|
354
|
+
logInfo('2. Import GitHub labels from .github/labels.json using the web interface');
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
logInfo('3. Create your first issue with phase labels');
|
|
358
|
+
logInfo('4. Start coordinating your AI agents!');
|
|
320
359
|
|
|
321
360
|
logInfo('\nš Learn more about FRAIM:');
|
|
322
361
|
logInfo('https://github.com/mathursrus/Ashley-Calendar-AI/tree/master/FRAIM');
|