ultra-dex 1.0.1 → 1.1.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/README.md CHANGED
@@ -99,9 +99,9 @@ Next steps:
99
99
 
100
100
  ## Links
101
101
 
102
- - [Full Template](https://github.com/Srujan0798/Ultra-Dex/blob/main/%40%20Ultra%20DeX/Saas%20plan/Imp%20Template.md)
103
- - [Examples](https://github.com/Srujan0798/Ultra-Dex/tree/main/%40%20Ultra%20DeX/Saas%20plan/Examples)
104
- - [Methodology](https://github.com/Srujan0798/Ultra-Dex/blob/main/%40%20Ultra%20DeX/Saas%20plan/METHODOLOGY.md)
102
+ - [Full Template](https://github.com/Srujan0798/Ultra-Dex/blob/main/@%20Ultra%20DeX/Saas%20plan/04-Imp-Template.md)
103
+ - [Examples](https://github.com/Srujan0798/Ultra-Dex/tree/main/@%20Ultra%20DeX/Saas%20plan/Examples)
104
+ - [Methodology](https://github.com/Srujan0798/Ultra-Dex/blob/main/@%20Ultra%20DeX/Saas%20plan/03-METHODOLOGY.md)
105
105
 
106
106
  ## License
107
107
 
package/bin/ultra-dex.js CHANGED
@@ -50,9 +50,9 @@ const QUICK_START_TEMPLATE = `# {{PROJECT_NAME}} - Quick Start
50
50
  - {{PROBLEM_2}}
51
51
  - {{PROBLEM_3}}
52
52
 
53
- ## 3. MVP Features (5 max)
53
+ ## 3. Core Production Features (5 max)
54
54
 
55
- | Feature | Priority | Why it's MVP? |
55
+ | Feature | Priority | Justification |
56
56
  |---------|----------|---------------|
57
57
  | {{FEATURE_1}} | P0 | |
58
58
  | | P0 | |
@@ -103,7 +103,7 @@ Setting up the implementation plan.
103
103
 
104
104
  ## Resources
105
105
  - [Ultra-Dex Template](https://github.com/Srujan0798/Ultra-Dex)
106
- - [TaskFlow Example](https://github.com/Srujan0798/Ultra-Dex/blob/main/%40%20Ultra%20DeX/Saas%20plan/Examples/TaskFlow-Complete.md)
106
+ - [TaskFlow Example](https://github.com/Srujan0798/Ultra-Dex/blob/main/@%20Ultra%20DeX/Saas%20plan/Examples/TaskFlow-Complete.md)
107
107
  `;
108
108
 
109
109
  program
@@ -162,7 +162,7 @@ program
162
162
  {
163
163
  type: 'input',
164
164
  name: 'feature1',
165
- message: 'Most important MVP feature:',
165
+ message: 'Critical production feature:',
166
166
  default: '',
167
167
  },
168
168
  {
@@ -195,6 +195,12 @@ program
195
195
  message: 'Hosting:',
196
196
  choices: ['Vercel', 'Railway', 'Fly.io', 'AWS', 'Other'],
197
197
  },
198
+ {
199
+ type: 'confirm',
200
+ name: 'includeCursorRules',
201
+ message: 'Include cursor-rules for AI assistants? (Cursor, Copilot)',
202
+ default: true,
203
+ },
198
204
  ]);
199
205
 
200
206
  const spinner = ora('Creating project files...').start();
@@ -255,20 +261,44 @@ ${answers.ideaWhat} for ${answers.ideaFor}.
255
261
 
256
262
  ## Resources
257
263
 
258
- - [Full Template](https://github.com/Srujan0798/Ultra-Dex/blob/main/%40%20Ultra%20DeX/Saas%20plan/Imp%20Template.md)
259
- - [TaskFlow Example](https://github.com/Srujan0798/Ultra-Dex/blob/main/%40%20Ultra%20DeX/Saas%20plan/Examples/TaskFlow-Complete.md)
260
- - [Methodology](https://github.com/Srujan0798/Ultra-Dex/blob/main/%40%20Ultra%20DeX/Saas%20plan/METHODOLOGY.md)
264
+ - [Full Template](https://github.com/Srujan0798/Ultra-Dex/blob/main/@%20Ultra%20DeX/Saas%20plan/04-Imp-Template.md)
265
+ - [TaskFlow Example](https://github.com/Srujan0798/Ultra-Dex/blob/main/@%20Ultra%20DeX/Saas%20plan/Examples/TaskFlow-Complete.md)
266
+ - [Methodology](https://github.com/Srujan0798/Ultra-Dex/blob/main/@%20Ultra%20DeX/Saas%20plan/03-METHODOLOGY.md)
261
267
  `;
262
268
 
263
269
  await fs.writeFile(path.join(outputDir, 'IMPLEMENTATION-PLAN.md'), planContent);
264
270
 
271
+ // Copy cursor-rules if requested
272
+ if (answers.includeCursorRules) {
273
+ const rulesDir = path.join(outputDir, '.cursor', 'rules');
274
+ await fs.mkdir(rulesDir, { recursive: true });
275
+
276
+ const cursorRulesPath = path.resolve(__dirname, '../../cursor-rules');
277
+ try {
278
+ const ruleFiles = await fs.readdir(cursorRulesPath);
279
+ for (const file of ruleFiles.filter(f => f.endsWith('.mdc'))) {
280
+ await fs.copyFile(
281
+ path.join(cursorRulesPath, file),
282
+ path.join(rulesDir, file)
283
+ );
284
+ }
285
+ } catch (err) {
286
+ // Cursor rules not available (npm package, not local)
287
+ console.log(chalk.yellow('\n Note: cursor-rules not bundled. Download from GitHub:'));
288
+ console.log(chalk.blue(' https://github.com/Srujan0798/Ultra-Dex/tree/main/cursor-rules'));
289
+ }
290
+ }
291
+
265
292
  spinner.succeed(chalk.green('Project created successfully!'));
266
293
 
267
294
  console.log('\n' + chalk.bold('Files created:'));
268
295
  console.log(chalk.gray(` ${outputDir}/`));
269
296
  console.log(chalk.gray(' ├── QUICK-START.md'));
270
297
  console.log(chalk.gray(' ├── CONTEXT.md'));
271
- console.log(chalk.gray(' └── IMPLEMENTATION-PLAN.md'));
298
+ console.log(chalk.gray(' ├── IMPLEMENTATION-PLAN.md'));
299
+ if (answers.includeCursorRules) {
300
+ console.log(chalk.gray(' └── .cursor/rules/ (11 AI rule files)'));
301
+ }
272
302
 
273
303
  console.log('\n' + chalk.bold('Next steps:'));
274
304
  console.log(chalk.cyan(` 1. cd ${answers.projectName}`));
@@ -285,6 +315,140 @@ ${answers.ideaWhat} for ${answers.ideaFor}.
285
315
  }
286
316
  });
287
317
 
318
+ program
319
+ .command('audit')
320
+ .description('Audit your Ultra-Dex project for completeness')
321
+ .option('-d, --dir <directory>', 'Project directory to audit', '.')
322
+ .action(async (options) => {
323
+ console.log(chalk.cyan('\n🔍 Ultra-Dex Project Audit\n'));
324
+
325
+ const projectDir = path.resolve(options.dir);
326
+ let score = 0;
327
+ let maxScore = 0;
328
+ const results = [];
329
+
330
+ // Helper function to check file exists and has content
331
+ async function checkFile(filePath, description, points) {
332
+ maxScore += points;
333
+ try {
334
+ const content = await fs.readFile(path.join(projectDir, filePath), 'utf-8');
335
+ if (content.length > 50) {
336
+ score += points;
337
+ results.push({ status: '✅', item: description, points: `+${points}` });
338
+ return content;
339
+ } else {
340
+ results.push({ status: '⚠️', item: `${description} (empty/too short)`, points: '0' });
341
+ return null;
342
+ }
343
+ } catch {
344
+ results.push({ status: '❌', item: `${description} (missing)`, points: '0' });
345
+ return null;
346
+ }
347
+ }
348
+
349
+ // Helper to check content has section
350
+ function hasSection(content, sectionName, points) {
351
+ maxScore += points;
352
+ if (content && content.toLowerCase().includes(sectionName.toLowerCase())) {
353
+ score += points;
354
+ results.push({ status: '✅', item: `Has ${sectionName}`, points: `+${points}` });
355
+ return true;
356
+ } else {
357
+ results.push({ status: '❌', item: `Missing ${sectionName}`, points: '0' });
358
+ return false;
359
+ }
360
+ }
361
+
362
+ // Check core files
363
+ console.log(chalk.bold('Checking project files...\n'));
364
+
365
+ const quickStart = await checkFile('QUICK-START.md', 'QUICK-START.md', 10);
366
+ const context = await checkFile('CONTEXT.md', 'CONTEXT.md', 5);
367
+ const implPlan = await checkFile('IMPLEMENTATION-PLAN.md', 'IMPLEMENTATION-PLAN.md', 5);
368
+ const fullTemplate = await checkFile('04-Imp-Template.md', '04-Imp-Template.md', 10);
369
+
370
+ // Check for alternative file names
371
+ const readme = await checkFile('README.md', 'README.md', 5);
372
+
373
+ // Check content quality if QUICK-START exists
374
+ if (quickStart) {
375
+ hasSection(quickStart, 'idea', 5);
376
+ hasSection(quickStart, 'problem', 5);
377
+ hasSection(quickStart, 'mvp', 5);
378
+ hasSection(quickStart, 'tech stack', 10);
379
+ hasSection(quickStart, 'feature', 5);
380
+ }
381
+
382
+ // Check for implementation details
383
+ if (implPlan) {
384
+ hasSection(implPlan, 'database', 5);
385
+ hasSection(implPlan, 'api', 5);
386
+ hasSection(implPlan, 'auth', 5);
387
+ }
388
+
389
+ // Check for docs folder
390
+ try {
391
+ await fs.access(path.join(projectDir, 'docs'));
392
+ score += 5;
393
+ maxScore += 5;
394
+ results.push({ status: '✅', item: 'docs/ folder exists', points: '+5' });
395
+ } catch {
396
+ maxScore += 5;
397
+ results.push({ status: '⚠️', item: 'docs/ folder (optional)', points: '0' });
398
+ }
399
+
400
+ // Print results
401
+ console.log(chalk.bold('Audit Results:\n'));
402
+ results.forEach(r => {
403
+ const statusColor = r.status === '✅' ? chalk.green : r.status === '❌' ? chalk.red : chalk.yellow;
404
+ console.log(` ${statusColor(r.status)} ${r.item} ${chalk.gray(r.points)}`);
405
+ });
406
+
407
+ // Calculate percentage
408
+ const percentage = Math.round((score / maxScore) * 100);
409
+
410
+ console.log('\n' + chalk.bold('─'.repeat(50)));
411
+ console.log(chalk.bold(`\nScore: ${score}/${maxScore} (${percentage}%)\n`));
412
+
413
+ // Grade
414
+ let grade, gradeColor, message;
415
+ if (percentage >= 90) {
416
+ grade = 'A';
417
+ gradeColor = chalk.green;
418
+ message = 'Excellent! Your project is well-documented.';
419
+ } else if (percentage >= 75) {
420
+ grade = 'B';
421
+ gradeColor = chalk.green;
422
+ message = 'Good! A few more sections would help.';
423
+ } else if (percentage >= 60) {
424
+ grade = 'C';
425
+ gradeColor = chalk.yellow;
426
+ message = 'Fair. Consider filling more sections before coding.';
427
+ } else if (percentage >= 40) {
428
+ grade = 'D';
429
+ gradeColor = chalk.yellow;
430
+ message = 'Needs work. Use QUICK-START.md to define your project.';
431
+ } else {
432
+ grade = 'F';
433
+ gradeColor = chalk.red;
434
+ message = 'Run "npx ultra-dex init" to get started properly.';
435
+ }
436
+
437
+ console.log(gradeColor(`Grade: ${grade}`));
438
+ console.log(chalk.gray(message));
439
+
440
+ // Suggestions
441
+ const missing = results.filter(r => r.status === '❌');
442
+ if (missing.length > 0) {
443
+ console.log(chalk.bold('\n📋 To improve your score:\n'));
444
+ missing.slice(0, 5).forEach(m => {
445
+ console.log(chalk.cyan(` → Add ${m.item.replace(' (missing)', '')}`));
446
+ });
447
+ }
448
+
449
+ console.log('\n' + chalk.gray('Learn more: https://github.com/Srujan0798/Ultra-Dex\n'));
450
+ });
451
+
288
452
  program
289
453
  .command('examples')
290
454
  .description('List available examples')
@@ -295,17 +459,17 @@ program
295
459
  {
296
460
  name: 'TaskFlow',
297
461
  type: 'Task Management',
298
- url: 'https://github.com/Srujan0798/Ultra-Dex/blob/main/%40%20Ultra%20DeX/Saas%20plan/Examples/TaskFlow-Complete.md',
462
+ url: 'https://github.com/Srujan0798/Ultra-Dex/blob/main/@%20Ultra%20DeX/Saas%20plan/Examples/TaskFlow-Complete.md',
299
463
  },
300
464
  {
301
465
  name: 'InvoiceFlow',
302
466
  type: 'Invoicing',
303
- url: 'https://github.com/Srujan0798/Ultra-Dex/blob/main/%40%20Ultra%20DeX/Saas%20plan/Examples/InvoiceFlow-Complete.md',
467
+ url: 'https://github.com/Srujan0798/Ultra-Dex/blob/main/@%20Ultra%20DeX/Saas%20plan/Examples/InvoiceFlow-Complete.md',
304
468
  },
305
469
  {
306
470
  name: 'HabitStack',
307
471
  type: 'Habit Tracking',
308
- url: 'https://github.com/Srujan0798/Ultra-Dex/blob/main/%40%20Ultra%20DeX/Saas%20plan/Examples/HabitStack-Complete.md',
472
+ url: 'https://github.com/Srujan0798/Ultra-Dex/blob/main/@%20Ultra%20DeX/Saas%20plan/Examples/HabitStack-Complete.md',
309
473
  },
310
474
  ];
311
475
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ultra-dex",
3
- "version": "1.0.1",
3
+ "version": "1.1.0",
4
4
  "description": "CLI for Ultra-Dex SaaS Implementation Framework",
5
5
  "keywords": [
6
6
  "saas",
@@ -33,4 +33,4 @@
33
33
  "inquirer": "^9.2.12",
34
34
  "ora": "^8.0.1"
35
35
  }
36
- }
36
+ }