overlord-cli 0.2607101820.0 → 0.2607122001.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/dist/index.js +25 -1
- package/dist/index.js.map +2 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -7999,6 +7999,9 @@ function applyPollJitter(intervalMs, random = Math.random) {
|
|
|
7999
7999
|
const spread = intervalMs * 0.1;
|
|
8000
8000
|
return Math.round(intervalMs + (random() * 2 - 1) * spread);
|
|
8001
8001
|
}
|
|
8002
|
+
function nextRunnerLastError(pollError) {
|
|
8003
|
+
return pollError;
|
|
8004
|
+
}
|
|
8002
8005
|
function resolveOverlordAppInvocation({
|
|
8003
8006
|
platform: platform2 = process.platform,
|
|
8004
8007
|
homedir: homedir2 = os4.homedir(),
|
|
@@ -9066,6 +9069,23 @@ async function runManagementCommand({
|
|
|
9066
9069
|
else console.log(`Linked ${directory} to project ${projectId}`);
|
|
9067
9070
|
return;
|
|
9068
9071
|
}
|
|
9072
|
+
case "add-url": {
|
|
9073
|
+
const sourceUrl = flagValue(parsed.flags, "--url");
|
|
9074
|
+
if (!sourceUrl) throw new CliError({ message: "Missing --url <git-url>" });
|
|
9075
|
+
const projectId = flagValue(parsed.flags, "--project-id");
|
|
9076
|
+
if (!projectId) throw new CliError({ message: "Missing --project-id for URL resources." });
|
|
9077
|
+
const resource = await runtime.backend.post({
|
|
9078
|
+
path: `/api/projects/${encodeURIComponent(projectId)}/resources`,
|
|
9079
|
+
body: {
|
|
9080
|
+
sourceUrl,
|
|
9081
|
+
resourceKey: flagValue(parsed.flags, "--key"),
|
|
9082
|
+
isPrimary: flagValue(parsed.flags, "--primary") !== "false"
|
|
9083
|
+
}
|
|
9084
|
+
});
|
|
9085
|
+
if (json) printJson({ resource });
|
|
9086
|
+
else console.log(`Linked ${sourceUrl} to project ${projectId}`);
|
|
9087
|
+
return;
|
|
9088
|
+
}
|
|
9069
9089
|
case "create":
|
|
9070
9090
|
case "prompt": {
|
|
9071
9091
|
const objectivesJson = flagValue(parsed.flags, "--objectives-json");
|
|
@@ -9456,7 +9476,9 @@ async function runRunnerSupervisor({
|
|
|
9456
9476
|
lastHeartbeatAt: now.toISOString(),
|
|
9457
9477
|
lastClaimedAt: launched ? now.toISOString() : state.lastClaimedAt,
|
|
9458
9478
|
lastLaunchedAt: launched ? now.toISOString() : state.lastLaunchedAt,
|
|
9459
|
-
|
|
9479
|
+
// Reflect the latest poll's outcome so a resolved failure (e.g. an auth
|
|
9480
|
+
// error from before the user logged in) clears instead of sticking.
|
|
9481
|
+
lastError: nextRunnerLastError(lastError),
|
|
9460
9482
|
currentPollIntervalMs: base
|
|
9461
9483
|
});
|
|
9462
9484
|
await new Promise((resolve) => setTimeout(resolve, applyPollJitter(base)));
|
|
@@ -9666,6 +9688,7 @@ Projects:
|
|
|
9666
9688
|
${primaryCommand} create-project --name "<name>" [--directory <path>|--no-directory]
|
|
9667
9689
|
${primaryCommand} add-cwd [--directory <path>] [--project-id <id>] [--key <resourceKey>] [--primary true|false]
|
|
9668
9690
|
(prompts to pick a project when --project-id is omitted)
|
|
9691
|
+
${primaryCommand} add-url --url <git-url> --project-id <id> [--key <resourceKey>] [--primary true|false]
|
|
9669
9692
|
|
|
9670
9693
|
Missions:
|
|
9671
9694
|
${primaryCommand} create "<objective>" [--objectives-json '[...]'] [--json]
|
|
@@ -9735,6 +9758,7 @@ var KNOWN_COMMANDS = /* @__PURE__ */ new Set([
|
|
|
9735
9758
|
"create-project",
|
|
9736
9759
|
"org-setup",
|
|
9737
9760
|
"add-cwd",
|
|
9761
|
+
"add-url",
|
|
9738
9762
|
"create",
|
|
9739
9763
|
"prompt",
|
|
9740
9764
|
"attach",
|