@locusai/cli 0.4.13 → 0.4.16

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/bin/locus.js +21 -3
  2. package/package.json +2 -2
package/bin/locus.js CHANGED
@@ -30788,7 +30788,7 @@ ${c.success("✅ Orchestrator finished")}`);
30788
30788
  const potentialPaths = [];
30789
30789
  const currentModulePath = fileURLToPath2(import.meta.url);
30790
30790
  const currentModuleDir = dirname2(currentModulePath);
30791
- potentialPaths.push(join4(currentModuleDir, "agent", "worker.js"), join4(currentModuleDir, "worker.js"));
30791
+ potentialPaths.push(join4(currentModuleDir, "agent", "worker.js"), join4(currentModuleDir, "worker.js"), join4(currentModuleDir, "agent", "worker.ts"));
30792
30792
  const workerPath = potentialPaths.find((p) => existsSync4(p));
30793
30793
  if (!workerPath) {
30794
30794
  throw new Error(`Worker file not found. Checked: ${potentialPaths.join(", ")}. ` + `Make sure the SDK is properly built and installed.`);
@@ -30995,6 +30995,14 @@ class ConfigManager {
30995
30995
  }
30996
30996
  return null;
30997
30997
  }
30998
+ updateVersion(version) {
30999
+ const config = this.loadConfig();
31000
+ if (config && config.version !== version) {
31001
+ config.version = version;
31002
+ const path3 = getLocusPath(this.projectPath, "configFile");
31003
+ writeFileSync2(path3, JSON.stringify(config, null, 2));
31004
+ }
31005
+ }
30998
31006
  }
30999
31007
 
31000
31008
  // src/tree-summarizer.ts
@@ -31108,6 +31116,7 @@ async function runCommand(args) {
31108
31116
  });
31109
31117
  const projectPath = values.dir || process.cwd();
31110
31118
  requireInitialization(projectPath, "run");
31119
+ new ConfigManager(projectPath).updateVersion(VERSION3);
31111
31120
  const apiKey = values["api-key"] || process.env.LOCUS_API_KEY;
31112
31121
  const anthropicApiKey = values["anthropic-api-key"] || process.env.ANTHROPIC_API_KEY;
31113
31122
  const workspaceId = values.workspace || process.env.LOCUS_WORKSPACE_ID;
@@ -31128,6 +31137,14 @@ async function runCommand(args) {
31128
31137
  orchestrator.on("task:assigned", (data) => console.log(`ℹ [CLAIMED] ${data.title}`));
31129
31138
  orchestrator.on("task:completed", (data) => console.log(`✓ [COMPLETED] ${data.taskId}`));
31130
31139
  orchestrator.on("task:failed", (data) => console.log(`✗ [FAILED] ${data.taskId}: ${data.error}`));
31140
+ const handleSignal = async (signal) => {
31141
+ console.log(`
31142
+ ${c.info(`Received ${signal}. Stopping agents...`)}`);
31143
+ await orchestrator.stop();
31144
+ process.exit(0);
31145
+ };
31146
+ process.on("SIGINT", () => handleSignal("SIGINT"));
31147
+ process.on("SIGTERM", () => handleSignal("SIGTERM"));
31131
31148
  console.log(`${c.primary("\uD83D\uDE80 Starting agent in")} ${c.bold(projectPath)}...`);
31132
31149
  await orchestrator.start();
31133
31150
  }
@@ -31139,6 +31156,7 @@ async function indexCommand(args) {
31139
31156
  });
31140
31157
  const projectPath = values.dir || process.cwd();
31141
31158
  requireInitialization(projectPath, "index");
31159
+ new ConfigManager(projectPath).updateVersion(VERSION3);
31142
31160
  const summarizer = new TreeSummarizer(projectPath);
31143
31161
  const indexer = new CodebaseIndexer(projectPath);
31144
31162
  console.log(`${c.primary("\uD83D\uDD0D Indexing codebase in")} ${c.bold(projectPath)}...`);
@@ -31171,7 +31189,7 @@ Next steps:
31171
31189
  1. Run '${c.primary("locus index")}' to index your codebase
31172
31190
  2. Run '${c.primary("locus run")}' to start an agent (requires --api-key and --workspace)
31173
31191
 
31174
- For more information, visit: ${c.underline("https://locus.dev/docs")}
31192
+ For more information, visit: ${c.underline("https://locusai.dev/docs")}
31175
31193
  `);
31176
31194
  }
31177
31195
  async function main() {
@@ -31210,7 +31228,7 @@ Environment Variables:
31210
31228
  LOCUS_WORKSPACE_ID Workspace ID
31211
31229
  ANTHROPIC_API_KEY Optional Anthropic API key
31212
31230
 
31213
- For more information, visit: https://locus.dev/docs
31231
+ For more information, visit: https://locusai.dev/docs
31214
31232
  `);
31215
31233
  }
31216
31234
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@locusai/cli",
3
- "version": "0.4.13",
3
+ "version": "0.4.16",
4
4
  "description": "Local-first AI development platform & engineering workspace",
5
5
  "type": "module",
6
6
  "bin": {
@@ -31,7 +31,7 @@
31
31
  "author": "",
32
32
  "license": "MIT",
33
33
  "dependencies": {
34
- "@locusai/sdk": "^0.4.13"
34
+ "@locusai/sdk": "^0.4.16"
35
35
  },
36
36
  "devDependencies": {}
37
37
  }