diff --git a/CHANGELOG.md b/CHANGELOG.md index ede8928..3389e49 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,27 @@ # Changelog +## [2.3.0] - 2026-02-18 + +### Added +- **Production-Ready Leaderboard**: + - Implemented secure Row-Level Security (RLS) policies for anonymized stat synchronization. + - Enhanced API response to include real-time global ranking. +- **Searchable Documentation**: + - Added full-text search capability to the documentation portal using a pre-built static index. + +### Improved +- **Error Diagnostics**: + - CLI now provides detailed feedback for server-side errors during sync (no more generic 500 errors). + - Synchronous environment validation for Supabase credentials on the server. +- **AI Reliability**: + - Improved Grok API error parsing for rate limits and invalid tokens. + - Optimized fetch timeouts for better responsiveness in low-bandwidth environments. + +### Fixed +- **CLI Stability**: + - Fixed sync failures caused by rigid database permission checks. + - Resolved potential crashes when parsing malformed `autopilot.log` entries. + ## [2.2.0] - 2026-02-14 ### Added diff --git a/autopilot-docs/app/page.tsx b/autopilot-docs/app/page.tsx index 02a3a5b..18fe09b 100644 --- a/autopilot-docs/app/page.tsx +++ b/autopilot-docs/app/page.tsx @@ -99,6 +99,14 @@ export default async function Home() { +
+
+ + npx @traisetech/autopilot guide +
+

New to Autopilot? Run our interactive guide to learn the ropes.

+
+ @@ -169,6 +177,66 @@ export default async function Home() { + {/* Commands Reference */} +
+
+
+

Command Reference

+

+ Master every aspect of the Autopilot CLI with this comprehensive command list. +

+
+ +
+ + + + + + + + + +
+
+
+ {/* Features */} @@ -244,3 +312,36 @@ function PrincipleCard({ icon: Icon, title, description, color, bg }: { icon: an ); } +function CommandCard({ command, description, group }: { command: string, description: string, group: string }) { + return ( +
+ {/* Background Glow */} +
+ +
+
+ + {group} + + +
+ +
+
+ $ + {command} +
+
+ +

+ {description} +

+
+ + {/* Bottom accent line */} +
+
+ ); +} + + diff --git a/bin/autopilot.js b/bin/autopilot.js index 4f83e7c..ad097c2 100644 --- a/bin/autopilot.js +++ b/bin/autopilot.js @@ -14,6 +14,7 @@ const doctor = require('../src/commands/doctor'); const presetCommand = require('../src/commands/preset'); const configCommand = require('../src/commands/config'); const interactiveCommand = require('../src/commands/interactive'); +const guideCommand = require('../src/commands/guide'); const pkg = require('../package.json'); const logger = require('../src/utils/logger'); const { checkForUpdate } = require('../src/utils/update-check'); @@ -32,7 +33,8 @@ const commands = { doctor: doctor, preset: presetCommand, config: configCommand, - interactive: interactiveCommand + interactive: interactiveCommand, + guide: guideCommand }; // Runtime assertion to prevent wiring errors @@ -130,6 +132,11 @@ program .option('-g, --global', 'Set the preference globally') .action(interactiveCommand); +program + .command('guide') + .description('Interactive guide to using Autopilot') + .action(guideCommand); + program .command('doctor') .description('Diagnose and validate autopilot setup') diff --git a/package.json b/package.json index d7ed780..01062e5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@traisetech/autopilot", - "version": "2.2.0", + "version": "2.3.0", "publishConfig": { "access": "public" }, @@ -66,4 +66,4 @@ "prop-types": "^15.8.1", "react": "^19.2.4" } -} +} \ No newline at end of file diff --git a/src/commands/guide.js b/src/commands/guide.js new file mode 100644 index 0000000..f8ea50a --- /dev/null +++ b/src/commands/guide.js @@ -0,0 +1,63 @@ +const logger = require('../utils/logger'); +const path = require('path'); +const fs = require('fs-extra'); + +async function guide() { + const { default: chalk } = await import('chalk'); + + console.log('\n'); + logger.section('🚀 Autopilot Intelligent Guide'); + console.log(chalk.gray('Welcome! Let\'s get you up to speed with Autopilot CLI.\n')); + + const steps = [ + { + title: '1. Initialization', + desc: 'Set up your project with safety rails.', + cmd: 'autopilot init', + tip: 'This creates .autopilotrc.json and .autopilotignore.' + }, + { + title: '2. The Watcher', + desc: 'Start the automation engine.', + cmd: 'autopilot start', + tip: 'Runs in the foreground. Press Ctrl+C to stop.' + }, + { + title: '3. Real-time Dashboard', + desc: 'See exactly what Autopilot is doing.', + cmd: 'autopilot dashboard', + tip: 'Run this in a separate terminal split for the best experience.' + }, + { + title: '4. Productivity Insights', + desc: 'Analyze your coding habits and quality.', + cmd: 'autopilot insights', + tip: 'Try "autopilot insights --export csv" for a detailed report.' + }, + { + title: '5. Global Leaderboard', + desc: 'See where you rank among other developers.', + cmd: 'autopilot leaderboard --sync', + tip: 'Participation is opt-in and anonymized.' + }, + { + title: '6. Safety First: Undoing', + desc: 'Made a mistake? Revert it instantly.', + cmd: 'autopilot undo', + tip: 'Keeps your file changes but removes the git commit.' + } + ]; + + for (const step of steps) { + console.log(chalk.bold.blue(`\n ${step.title}`)); + console.log(` ${chalk.white(step.desc)}`); + console.log(` ${chalk.bgBlack.green(' $ ' + step.cmd)}`); + console.log(` ${chalk.italic.gray(' Tip: ' + step.tip)}`); + } + + console.log('\n'); + logger.info('Pro Tip: Run "autopilot doctor" if you encounter any environment issues.'); + console.log('\n'); +} + +module.exports = guide;