vigthoria-cli 1.6.54 → 1.6.56

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 CHANGED
@@ -66,6 +66,11 @@ const repo_js_1 = require("./commands/repo.js");
66
66
  const deploy_js_1 = require("./commands/deploy.js");
67
67
  const bridge_js_1 = require("./commands/bridge.js");
68
68
  const workflow_js_1 = require("./commands/workflow.js");
69
+ const preview_js_1 = require("./commands/preview.js");
70
+ const legion_js_1 = require("./commands/legion.js");
71
+ const history_js_1 = require("./commands/history.js");
72
+ const replay_js_1 = require("./commands/replay.js");
73
+ const fork_js_1 = require("./commands/fork.js");
69
74
  const config_js_2 = require("./utils/config.js");
70
75
  const logger_js_1 = require("./utils/logger.js");
71
76
  const chalk_1 = __importDefault(require("chalk"));
@@ -661,6 +666,78 @@ async function main() {
661
666
  project: options.project
662
667
  });
663
668
  });
669
+ // ==================== PREVIEW COMMAND ====================
670
+ program
671
+ .command('preview')
672
+ .description('Preview project locally with visual diffs and proof validation')
673
+ .option('-p, --project <path>', 'Project directory path', process.cwd())
674
+ .option('-e, --entry <file>', 'Entry HTML file (auto-detected if omitted)')
675
+ .option('--port <number>', 'Local server port', parseInt)
676
+ .option('--no-open', 'Do not auto-open browser')
677
+ .option('--diff', 'Show consolidated diff of recent agent changes')
678
+ .option('--proof', 'Run Template Service preview gate and persist proof bundle')
679
+ .option('--screenshot', 'Capture screenshot via Puppeteer')
680
+ .action(async (options) => {
681
+ const preview = new preview_js_1.PreviewCommand(config, logger);
682
+ await preview.run({
683
+ project: options.project,
684
+ entry: options.entry,
685
+ port: options.port,
686
+ open: options.open,
687
+ diff: options.diff,
688
+ proof: options.proof,
689
+ screenshot: options.screenshot,
690
+ });
691
+ });
692
+ // ==================== LEGION COMMAND ====================
693
+ program
694
+ .command('legion [request]')
695
+ .description('Run parallel tasks via Hyper Loop Legion orchestrator')
696
+ .option('--workers', 'List available Legion workers')
697
+ .option('--status', 'Show Legion infrastructure status')
698
+ .option('-w, --worker <name>', 'Execute a specific worker')
699
+ .option('-p, --project <path>', 'Project directory', process.cwd())
700
+ .action(async (request, options) => {
701
+ const legion = new legion_js_1.LegionCommand(config, logger);
702
+ await legion.run(request, {
703
+ workers: options.workers,
704
+ status: options.status,
705
+ worker: options.worker,
706
+ project: options.project,
707
+ });
708
+ });
709
+ // ==================== REPLAY & FORK COMMANDS ====================
710
+ program
711
+ .command('history')
712
+ .alias('runs')
713
+ .description('List recent V3 agent runs')
714
+ .option('-n, --limit <count>', 'Number of runs to show', '20')
715
+ .option('-p, --project <path>', 'Project directory', process.cwd())
716
+ .option('--json', 'Machine-readable JSON output', false)
717
+ .action(async (options) => {
718
+ const history = new history_js_1.HistoryCommand(config, logger);
719
+ await history.run({ limit: parseInt(options.limit, 10) || 20, json: options.json, project: options.project });
720
+ });
721
+ program
722
+ .command('replay <runId>')
723
+ .description('Replay events from a V3 agent run step-by-step')
724
+ .option('-s, --speed <ms>', 'Delay between events in ms', '200')
725
+ .option('-p, --project <path>', 'Project directory', process.cwd())
726
+ .option('--json', 'Machine-readable JSON output', false)
727
+ .action(async (runId, options) => {
728
+ const replay = new replay_js_1.ReplayCommand(config, logger);
729
+ await replay.run(runId, { speed: parseInt(options.speed, 10) || 200, json: options.json, project: options.project });
730
+ });
731
+ program
732
+ .command('fork <runId> [message]')
733
+ .description('Fork from an existing V3 agent run with new instructions')
734
+ .option('-e, --event-index <index>', 'Fork from specific event index', '0')
735
+ .option('-p, --project <path>', 'Project directory', process.cwd())
736
+ .option('--json', 'Machine-readable JSON output', false)
737
+ .action(async (runId, message, options) => {
738
+ const fork = new fork_js_1.ForkCommand(config, logger);
739
+ await fork.run(runId, message || '', { eventIndex: parseInt(options.eventIndex, 10) || 0, project: options.project, json: options.json });
740
+ });
664
741
  // ==================== AUTH COMMANDS ====================
665
742
  // Auth commands
666
743
  program
@@ -39,6 +39,7 @@ export interface V3AgentWorkflowResponse {
39
39
  contextId?: string | null;
40
40
  backendUrl: string;
41
41
  partial?: boolean;
42
+ changedFiles?: Record<string, string>;
42
43
  metadata?: Record<string, unknown>;
43
44
  }
44
45
  export interface FrontendPreviewGateResult {
package/dist/utils/api.js CHANGED
@@ -2831,6 +2831,7 @@ document.addEventListener('DOMContentLoaded', () => {
2831
2831
  contextId: finalContextId,
2832
2832
  backendUrl: baseUrl,
2833
2833
  partial: continuationData.checkpointed === true,
2834
+ changedFiles: continuationData.files || data.files || {},
2834
2835
  metadata: { source: 'v3-agent', mode: 'agent', contextId: finalContextId, continuations, previewGate },
2835
2836
  };
2836
2837
  }
@@ -2849,6 +2850,7 @@ document.addEventListener('DOMContentLoaded', () => {
2849
2850
  taskId: data.task_id || null,
2850
2851
  contextId,
2851
2852
  backendUrl: baseUrl,
2853
+ changedFiles: data.files || {},
2852
2854
  metadata: { source: 'v3-agent', mode: 'agent', contextId, mcpContextId, previewGate },
2853
2855
  };
2854
2856
  }
@@ -2864,6 +2866,7 @@ document.addEventListener('DOMContentLoaded', () => {
2864
2866
  contextId: error.partialData.context_id || requestExecutionContext.contextId || executionContext.contextId || null,
2865
2867
  backendUrl: baseUrl,
2866
2868
  partial: true,
2869
+ changedFiles: error.partialData.files || {},
2867
2870
  metadata: { source: 'v3-agent', mode: 'agent', partial: true, contextId: error.partialData.context_id || requestExecutionContext.contextId || executionContext.contextId || null, mcpContextId: requestExecutionContext.mcpContextId || executionContext.mcpContextId || null, previewGate },
2868
2871
  };
2869
2872
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vigthoria-cli",
3
- "version": "1.6.54",
3
+ "version": "1.6.56",
4
4
  "description": "Vigthoria Coder CLI - AI-powered terminal coding assistant",
5
5
  "main": "dist/index.js",
6
6
  "files": [