archondev 2.19.11 → 2.19.12

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.
Files changed (2) hide show
  1. package/dist/index.js +117 -47
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -3947,6 +3947,7 @@ async function handleContinueSession(cwd, state) {
3947
3947
  if (response.trim()) {
3948
3948
  const handled = await handleFreeformJourneyInput(cwd, response);
3949
3949
  if (handled) {
3950
+ await showMainMenu();
3950
3951
  return;
3951
3952
  }
3952
3953
  }
@@ -3979,54 +3980,54 @@ function checkForHandoff(cwd) {
3979
3980
  }
3980
3981
  async function showMainMenu() {
3981
3982
  const cwd = process.cwd();
3982
- const state = detectProjectState(cwd);
3983
- console.log(chalk6.bold("What would you like to do?\n"));
3984
- if (state.isWebProject) {
3985
- const { loadWebChecks, formatWebCheckStatus } = await import("./web-checks-4BSYXWDF.js");
3986
- const prefs = await loadWebChecks(cwd);
3987
- console.log(chalk6.dim("Web checks status:"));
3988
- console.log(chalk6.dim(` A11y: ${formatWebCheckStatus(prefs.lastRun?.a11y)}`));
3989
- console.log(chalk6.dim(` SEO: ${formatWebCheckStatus(prefs.lastRun?.seo)}`));
3990
- console.log(chalk6.dim(` GEO: ${formatWebCheckStatus(prefs.lastRun?.geo)}`));
3983
+ while (true) {
3984
+ const state = detectProjectState(cwd);
3985
+ console.log(chalk6.bold("What would you like to do?\n"));
3986
+ if (state.isWebProject) {
3987
+ const { loadWebChecks, formatWebCheckStatus } = await import("./web-checks-4BSYXWDF.js");
3988
+ const prefs = await loadWebChecks(cwd);
3989
+ console.log(chalk6.dim("Web checks status:"));
3990
+ console.log(chalk6.dim(` A11y: ${formatWebCheckStatus(prefs.lastRun?.a11y)}`));
3991
+ console.log(chalk6.dim(` SEO: ${formatWebCheckStatus(prefs.lastRun?.seo)}`));
3992
+ console.log(chalk6.dim(` GEO: ${formatWebCheckStatus(prefs.lastRun?.geo)}`));
3993
+ console.log();
3994
+ }
3995
+ const choices = [
3996
+ { key: "1", label: "Plan a new task", action: () => planTask() },
3997
+ { key: "2", label: "List atoms", action: () => listAtoms() },
3998
+ { key: "3", label: "Execute next atom", action: () => executeNext() },
3999
+ { key: "4", label: "Report a bug", action: () => reportBug() },
4000
+ { key: "5", label: "View status", action: () => viewStatus() },
4001
+ { key: "6", label: "Code Review", action: () => reviewCode() },
4002
+ ...state.isWebProject ? [{ key: "w", label: "Web checks (SEO/GEO/A11y)", action: async () => {
4003
+ await showWebChecksMenu();
4004
+ } }] : [],
4005
+ { key: "7", label: "Settings & Preferences", action: () => settingsMenu() },
4006
+ { key: "8", label: "Upgrade tier", action: async () => {
4007
+ const { showUpgradeMenu } = await import("./tier-selection-XFBM4SZ4.js");
4008
+ await showUpgradeMenu();
4009
+ } },
4010
+ { key: "q", label: "Quit", action: async () => process.exit(0) }
4011
+ ];
4012
+ for (const choice2 of choices) {
4013
+ console.log(` ${chalk6.cyan(choice2.key)}) ${choice2.label}`);
4014
+ }
4015
+ console.log(chalk6.dim(' (Type "/" for quick commands, or "upgrade"/"help" anytime)'));
3991
4016
  console.log();
3992
- }
3993
- const choices = [
3994
- { key: "1", label: "Plan a new task", action: () => planTask() },
3995
- { key: "2", label: "List atoms", action: () => listAtoms() },
3996
- { key: "3", label: "Execute next atom", action: () => executeNext() },
3997
- { key: "4", label: "Report a bug", action: () => reportBug() },
3998
- { key: "5", label: "View status", action: () => viewStatus() },
3999
- { key: "6", label: "Code Review", action: () => reviewCode() },
4000
- ...state.isWebProject ? [{ key: "w", label: "Web checks (SEO/GEO/A11y)", action: async () => {
4001
- await showWebChecksMenu();
4002
- await showMainMenu();
4003
- } }] : [],
4004
- { key: "7", label: "Settings & Preferences", action: () => settingsMenu() },
4005
- { key: "8", label: "Upgrade tier", action: async () => {
4006
- const { showUpgradeMenu } = await import("./tier-selection-XFBM4SZ4.js");
4007
- await showUpgradeMenu();
4008
- await showMainMenu();
4009
- } },
4010
- { key: "q", label: "Quit", action: async () => process.exit(0) }
4011
- ];
4012
- for (const choice2 of choices) {
4013
- console.log(` ${chalk6.cyan(choice2.key)}) ${choice2.label}`);
4014
- }
4015
- console.log(chalk6.dim(' (Type "upgrade" or "help" anytime)'));
4016
- console.log();
4017
- const selected = await promptWithCommands("Tell me what you want to do (or enter a shortcut)", { allowMultiline: true });
4018
- const choice = choices.find((c) => c.key === selected.toLowerCase());
4019
- if (choice) {
4020
- await choice.action();
4021
- } else if (selected.trim()) {
4022
- const handled = await handleFreeformJourneyInput(cwd, selected.trim());
4023
- if (!handled) {
4024
- console.log(chalk6.yellow("I did not catch that. Try describing your goal in one sentence."));
4025
- await showMainMenu();
4017
+ const selected = await promptWithCommands("Tell me what you want to do (or enter a shortcut)", { allowMultiline: true });
4018
+ const choice = choices.find((c) => c.key === selected.toLowerCase());
4019
+ if (choice) {
4020
+ await choice.action();
4021
+ continue;
4022
+ }
4023
+ if (selected.trim()) {
4024
+ const handled = await handleFreeformJourneyInput(cwd, selected.trim());
4025
+ if (!handled) {
4026
+ console.log(chalk6.yellow("I did not catch that. Try describing your goal in one sentence."));
4027
+ }
4028
+ continue;
4026
4029
  }
4027
- } else {
4028
4030
  console.log(chalk6.yellow("Invalid choice. Please try again."));
4029
- await showMainMenu();
4030
4031
  }
4031
4032
  }
4032
4033
  async function handleFreeformJourneyInput(cwd, input) {
@@ -4230,7 +4231,6 @@ async function viewStatus() {
4230
4231
  async function settingsMenu() {
4231
4232
  const { interactiveSettings } = await import("./preferences-4V4C7MVD.js");
4232
4233
  await interactiveSettings();
4233
- await showMainMenu();
4234
4234
  }
4235
4235
  async function reviewCode() {
4236
4236
  const cwd = process.cwd();
@@ -4279,7 +4279,6 @@ async function reviewCode() {
4279
4279
  break;
4280
4280
  }
4281
4281
  case "b":
4282
- await showMainMenu();
4283
4282
  return;
4284
4283
  default:
4285
4284
  if (raw.trim()) {
@@ -4294,6 +4293,16 @@ async function reviewCode() {
4294
4293
  }
4295
4294
  async function handleInSessionCommand(input) {
4296
4295
  const normalized = input.toLowerCase().trim();
4296
+ if (normalized === "/" || normalized === "/help") {
4297
+ showSlashCommandMenu();
4298
+ return true;
4299
+ }
4300
+ if (normalized.startsWith("/")) {
4301
+ const slashHandled = await handleSlashCommand(input.trim());
4302
+ if (slashHandled) {
4303
+ return true;
4304
+ }
4305
+ }
4297
4306
  if (normalized === "upgrade" || normalized === "archon upgrade" || normalized === "pricing" || normalized === "archon pricing") {
4298
4307
  const { showUpgradeMenu } = await import("./tier-selection-XFBM4SZ4.js");
4299
4308
  await showUpgradeMenu();
@@ -4326,6 +4335,67 @@ async function handleInSessionCommand(input) {
4326
4335
  }
4327
4336
  return false;
4328
4337
  }
4338
+ function showSlashCommandMenu() {
4339
+ console.log();
4340
+ console.log(chalk6.bold("Quick Commands"));
4341
+ console.log(chalk6.dim(" /plan <task> Create a plan from a one-line task"));
4342
+ console.log(chalk6.dim(" /list List atoms"));
4343
+ console.log(chalk6.dim(" /execute Execute next atom"));
4344
+ console.log(chalk6.dim(" /review Open code review menu"));
4345
+ console.log(chalk6.dim(" /status Show account/status"));
4346
+ console.log(chalk6.dim(" /settings Open settings & preferences"));
4347
+ console.log(chalk6.dim(" /upgrade Open tier upgrade menu"));
4348
+ console.log(chalk6.dim(" /quit Exit ArchonDev"));
4349
+ console.log();
4350
+ }
4351
+ async function handleSlashCommand(input) {
4352
+ const trimmed = input.trim();
4353
+ if (!trimmed.startsWith("/")) {
4354
+ return false;
4355
+ }
4356
+ const parts = trimmed.split(/\s+/);
4357
+ const command = parts[0]?.toLowerCase() ?? "";
4358
+ const arg = parts.slice(1).join(" ").trim();
4359
+ switch (command) {
4360
+ case "/plan": {
4361
+ const { plan: plan2 } = await import("./plan-AR6Y4QUD.js");
4362
+ if (arg) {
4363
+ await plan2(arg, {});
4364
+ } else {
4365
+ const description = await promptWithCommands("Describe what you want to build", { allowMultiline: true });
4366
+ if (description.trim()) {
4367
+ await plan2(description, {});
4368
+ }
4369
+ }
4370
+ return true;
4371
+ }
4372
+ case "/list":
4373
+ await listAtoms();
4374
+ return true;
4375
+ case "/execute":
4376
+ await executeNext();
4377
+ return true;
4378
+ case "/review":
4379
+ await reviewCode();
4380
+ return true;
4381
+ case "/status":
4382
+ await viewStatus();
4383
+ return true;
4384
+ case "/settings":
4385
+ await settingsMenu();
4386
+ return true;
4387
+ case "/upgrade": {
4388
+ const { showUpgradeMenu } = await import("./tier-selection-XFBM4SZ4.js");
4389
+ await showUpgradeMenu();
4390
+ return true;
4391
+ }
4392
+ case "/quit":
4393
+ case "/exit":
4394
+ console.log(chalk6.dim("Goodbye!"));
4395
+ process.exit(0);
4396
+ }
4397
+ return false;
4398
+ }
4329
4399
  function prompt(question) {
4330
4400
  return new Promise((resolve) => {
4331
4401
  const rl = readline.createInterface({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "archondev",
3
- "version": "2.19.11",
3
+ "version": "2.19.12",
4
4
  "description": "Local-first AI-powered development governance system",
5
5
  "main": "dist/index.js",
6
6
  "bin": {