@cloop/runner 0.2.10 → 0.3.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/README.md CHANGED
@@ -12,6 +12,8 @@ cloop install # register the MCP server with Claude Code / others
12
12
 
13
13
  Credentials live in `~/.cloop/credentials.json`. The API origin comes from `CLOOP_ORIGIN`, the stored value, or the staging default.
14
14
 
15
+ To disconnect a runner, use Disconnect in its ⋯ menu on the Threads page.
16
+
15
17
  ## Commands
16
18
 
17
19
  | Command | What it does |
@@ -49,8 +51,8 @@ user to run `cloop login`.
49
51
 
50
52
  On start, `serve` opens a WebSocket to the cloop-mesh Worker's per-user Durable
51
53
  Object at `{CLOOP_MESH_URL}/mesh/agent?session_key=…` (default
52
- `https://mcp-staging.mycloop.com`; override via `CLOOP_MESH_URL` or the stored
53
- `meshUrl`). The device token rides the first `Sec-WebSocket-Protocol` entry, never
54
+ `https://mcp.mycloop.com`; `--staging` or `CLOOP_MESH_URL` selects another
55
+ mesh, and the choice is stored as `meshUrl`). The device token rides the first `Sec-WebSocket-Protocol` entry, never
54
56
  the URL (query strings leak into edge logs). While it's up, presence
55
57
  beats ride the socket (the DO mirrors them into the heartbeat route) and the HTTP
56
58
  `HeartbeatClient` is the fallback; it reconnects with 1s→60s backoff + jitter.
@@ -1,11 +1,11 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  serveTakeovers
4
- } from "./chunk-C6EODIE5.js";
5
- import "./chunk-HI3HDN35.js";
4
+ } from "./chunk-7CPNLUDI.js";
5
+ import "./chunk-NK6MHHYP.js";
6
6
  import {
7
7
  LocalDriver
8
- } from "./chunk-DHUZXAK2.js";
8
+ } from "./chunk-QLCIEJ4C.js";
9
9
  import {
10
10
  MeshSocket,
11
11
  defaultSocketFactory
@@ -21,32 +21,32 @@ import {
21
21
  probeClaudePermissions,
22
22
  probeCodex,
23
23
  runBoxTool
24
- } from "./chunk-EN7WRLSI.js";
24
+ } from "./chunk-34XAQRBL.js";
25
25
  import {
26
26
  BoxWatch,
27
27
  lockThreadsFile,
28
28
  threadsFilePath,
29
29
  writeRunnerState
30
- } from "./chunk-MWWA2VH7.js";
30
+ } from "./chunk-3B5JV6ZP.js";
31
31
  import {
32
32
  T3Driver,
33
33
  isLocal,
34
34
  readRunnerConfig,
35
35
  showsOtherThreads,
36
36
  writeBoxConfig
37
- } from "./chunk-NX2LAKNU.js";
37
+ } from "./chunk-EN3XHHWJ.js";
38
38
  import "./chunk-UBXT5IDU.js";
39
39
  import {
40
40
  getMachine
41
41
  } from "./chunk-JX6VG5FE.js";
42
42
  import "./chunk-VK6GV757.js";
43
43
  import "./chunk-R3CLO2FB.js";
44
- import "./chunk-VNX4VJAM.js";
45
- import "./chunk-PRJBCKRP.js";
44
+ import "./chunk-3ITSIARB.js";
45
+ import "./chunk-2PVKRGOX.js";
46
46
  import "./chunk-AG6SI6I2.js";
47
47
  import {
48
48
  VERSION
49
- } from "./chunk-UL2WHOQJ.js";
49
+ } from "./chunk-NOABXLW3.js";
50
50
  import {
51
51
  getMeshUrl,
52
52
  getToken,
@@ -179,7 +179,7 @@ async function machineHarnesses(cfg) {
179
179
  }
180
180
  async function localDriver(cfg, name) {
181
181
  const bin = cfg.driver === name ? cfg.bin : void 0;
182
- return new LocalDriver({
182
+ const driver = new LocalDriver({
183
183
  dialect: name === "claude-code" ? claudeDialect(bin, cfg.fallbackModels ?? DEFAULT_FALLBACK_MODEL, cfg.askEverything, {
184
184
  ...await probeClaudePermissions(bin)
185
185
  }) : codexDialect(bin),
@@ -188,6 +188,8 @@ async function localDriver(cfg, name) {
188
188
  harnesses: () => machineHarnesses(cfg),
189
189
  log
190
190
  });
191
+ driver.warmHarnesses();
192
+ return driver;
191
193
  }
192
194
  function recordConnected(logLine, write = writeRunnerState) {
193
195
  try {
@@ -390,6 +392,7 @@ export {
390
392
  awaitNewDeviceToken,
391
393
  boxCommand,
392
394
  boxPresence,
395
+ machineHarnesses,
393
396
  recordConnected,
394
397
  run,
395
398
  t3Presence
@@ -5,7 +5,7 @@ import {
5
5
  } from "./chunk-AG6SI6I2.js";
6
6
  import {
7
7
  VERSION
8
- } from "./chunk-UL2WHOQJ.js";
8
+ } from "./chunk-NOABXLW3.js";
9
9
  import {
10
10
  getOrigin,
11
11
  readCredentials,
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  readRunnerState
4
- } from "./chunk-MWWA2VH7.js";
4
+ } from "./chunk-3B5JV6ZP.js";
5
5
  import {
6
6
  BoxToolError,
7
7
  CLOOP_THREAD_PREFIX,
@@ -18,7 +18,7 @@ import {
18
18
  t3BaseDirArgs,
19
19
  t3Candidates,
20
20
  writeBoxConfig
21
- } from "./chunk-NX2LAKNU.js";
21
+ } from "./chunk-EN3XHHWJ.js";
22
22
  import {
23
23
  CLAUDE_FLOOR,
24
24
  claudeTooOld,
@@ -34,17 +34,17 @@ import {
34
34
  } from "./chunk-R3CLO2FB.js";
35
35
  import {
36
36
  connectWebhook
37
- } from "./chunk-VNX4VJAM.js";
37
+ } from "./chunk-3ITSIARB.js";
38
38
  import {
39
39
  ConnectFailure,
40
40
  connectReport,
41
41
  deviceLogin,
42
42
  newAttempt,
43
43
  sendConnectReport
44
- } from "./chunk-PRJBCKRP.js";
44
+ } from "./chunk-2PVKRGOX.js";
45
45
  import {
46
46
  VERSION
47
- } from "./chunk-UL2WHOQJ.js";
47
+ } from "./chunk-NOABXLW3.js";
48
48
  import {
49
49
  STAGING_ORIGIN,
50
50
  getOrigin
@@ -390,9 +390,13 @@ async function probeClaudePermissions(bin = "claude") {
390
390
  return claudePermissionSupport(await exec(bin, ["--help"]));
391
391
  }
392
392
  async function probeClaude(bin = "claude") {
393
- const version = (await exec(bin, ["--version"]))?.trim().split(/\s+/)[0];
393
+ const [versionOut, auth] = await Promise.all([
394
+ exec(bin, ["--version"]),
395
+ exec(bin, ["auth", "status", "--json"])
396
+ ]);
397
+ const version = versionOut?.trim().split(/\s+/)[0];
394
398
  if (!version) return null;
395
- const { signedIn, account } = claudeAccount(await exec(bin, ["auth", "status", "--json"]));
399
+ const { signedIn, account } = claudeAccount(auth);
396
400
  return {
397
401
  id: "claude-code",
398
402
  name: "Claude Code",
@@ -644,9 +648,11 @@ function codexAccount(ok, out2) {
644
648
  return { signedIn: true, account: /chatgpt/i.test(out2) ? "ChatGPT" : "API key" };
645
649
  }
646
650
  async function probeCodex(bin = "codex") {
647
- const version = await exec2(bin, ["--version"]);
651
+ const [version, status] = await Promise.all([
652
+ exec2(bin, ["--version"]),
653
+ exec2(bin, ["login", "status"])
654
+ ]);
648
655
  if (!version.ok) return null;
649
- const status = await exec2(bin, ["login", "status"]);
650
656
  const { signedIn, account } = codexAccount(status.ok, status.out);
651
657
  return {
652
658
  id: "codex",
@@ -1136,7 +1142,7 @@ function parsePicks(answer, max) {
1136
1142
  return [...new Set(picks)];
1137
1143
  }
1138
1144
  function rerunCommand(argv, script = process.argv[1] ?? "") {
1139
- const base = script.includes("/_npx/") ? "npx -y @cloop/runner" : "cloop";
1145
+ const base = script.includes("/_npx/") ? "npx -y @cloop/runner@latest" : "cloop";
1140
1146
  const staging = process.env.CLOOP_ORIGIN === STAGING_ORIGIN ? ["--staging"] : [];
1141
1147
  return [base, "connect", ...staging, ...argv].join(" ");
1142
1148
  }
@@ -1,4 +1,7 @@
1
1
  #!/usr/bin/env node
2
+ import {
3
+ RUN_TEXT_MAX
4
+ } from "./chunk-EN3XHHWJ.js";
2
5
  import {
3
6
  CONFIG_DIR
4
7
  } from "./chunk-3DIGCVL4.js";
@@ -159,7 +162,7 @@ var BoxWatch = class {
159
162
  thread_id: e.thread_id,
160
163
  kind,
161
164
  ...event.kind === "question" ? { question_id: event.question_id } : {},
162
- ...summary ? { summary: summary.slice(0, 500) } : {},
165
+ ...summary ? { summary: summary.slice(0, RUN_TEXT_MAX) } : {},
163
166
  ..."result" in event && event.result ? { result: event.result } : {},
164
167
  ..."pr_url" in event && event.pr_url ? { pr_url: event.pr_url } : {},
165
168
  ..."error" in event && event.error ? { error: event.error } : {},
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  ConnectFailure,
4
4
  deviceLogin
5
- } from "./chunk-PRJBCKRP.js";
5
+ } from "./chunk-2PVKRGOX.js";
6
6
  import {
7
7
  ApiError,
8
8
  ReauthError,
@@ -1,20 +1,20 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  findRun
4
- } from "./chunk-HI3HDN35.js";
4
+ } from "./chunk-NK6MHHYP.js";
5
5
  import {
6
6
  localRunsFilePath,
7
7
  readRunRecords,
8
8
  takeoverSummary
9
- } from "./chunk-DHUZXAK2.js";
9
+ } from "./chunk-QLCIEJ4C.js";
10
10
  import {
11
11
  lockThreadsFile,
12
12
  threadsFilePath
13
- } from "./chunk-MWWA2VH7.js";
13
+ } from "./chunk-3B5JV6ZP.js";
14
14
  import {
15
15
  isLocal,
16
16
  readRunnerConfig
17
- } from "./chunk-NX2LAKNU.js";
17
+ } from "./chunk-EN3XHHWJ.js";
18
18
  import {
19
19
  shortMachineName
20
20
  } from "./chunk-JX6VG5FE.js";
@@ -12,7 +12,8 @@ var RESULT_INSTRUCTION = [
12
12
  "```cloop-result",
13
13
  '{"summary": "One or two sentences on what you did.", "outputs": [{"kind": "pr", "title": "fix: the thing", "url": "https://github.com/org/repo/pull/1"}], "checks": [{"name": "Tests", "outcome": "passed"}]}',
14
14
  "```",
15
- "An output kind is one of: pr or link (title, url), draft (title, body, optional to), doc (title, optional url or body), file (title, path). A check outcome is passed, failed or skipped."
15
+ "An output kind is one of: pr or link (title, url), draft (title, body, optional to), doc (title, optional url or body), file (title, path). A check outcome is passed, failed or skipped.",
16
+ "List as outputs only what this run made. A PR or page you only read, checked or cited goes in the summary, never in outputs."
16
17
  ].join("\n");
17
18
  var text = (v, max) => typeof v === "string" && v.length <= max;
18
19
  var optionalText = (v, max) => v === void 0 || text(v, max);
@@ -24,8 +25,13 @@ var https = (v) => {
24
25
  }
25
26
  };
26
27
  var PR_URL = /https:\/\/github\.com\/[\w.-]+\/[\w.-]+\/pull\/\d+/g;
28
+ var prNumber = (url) => Number(url.slice(url.lastIndexOf("/") + 1));
27
29
  function prUrlIn(text2) {
28
- return text2?.match(PR_URL)?.at(-1) ?? null;
30
+ const urls = text2?.match(PR_URL) ?? [];
31
+ return urls.reduce(
32
+ (newest, url) => newest && prNumber(newest) >= prNumber(url) ? newest : url,
33
+ null
34
+ );
29
35
  }
30
36
  function resultPrUrl(finalMessage) {
31
37
  const result = parseRunResult(finalMessage);
@@ -143,8 +149,9 @@ function isProgressSentence(value) {
143
149
  return typeof value === "string" && /\S[ \t]+\S/.test(value.trim().split(/\r?\n/)[0] ?? "");
144
150
  }
145
151
  var PROGRESS_MS = 3e4;
152
+ var RUN_TEXT_MAX = 4e3;
146
153
  function nextProgress(clock, text2, now, ms = PROGRESS_MS, force = false) {
147
- const summary = (parseRunResult(text2)?.summary ?? text2.split("```cloop-result")[0] ?? "").replace(/\s+/g, " ").trim().slice(0, 200);
154
+ const summary = (parseRunResult(text2)?.summary ?? text2.split("```cloop-result")[0] ?? "").replace(/\s+/g, " ").trim().slice(0, RUN_TEXT_MAX);
148
155
  if (!isProgressSentence(summary)) return null;
149
156
  if (!force && now - clock.lastProgressAt < ms) return null;
150
157
  clock.lastProgressAt = now;
@@ -469,7 +476,7 @@ function outcomeOf(p) {
469
476
  settled,
470
477
  kind: settled ? status === "completed" || !run ? "settled" : "failed" : null,
471
478
  pr_url: resultPrUrl(text2),
472
- last_assistant_text: text2 ? text2.slice(0, 300) : null,
479
+ last_assistant_text: text2 ? text2.slice(0, RUN_TEXT_MAX) : null,
473
480
  ...result ? { result } : {},
474
481
  ...dropped.outputs || dropped.checks ? { dropped } : {}
475
482
  };
@@ -1182,6 +1189,7 @@ export {
1182
1189
  CLOOP_THREAD_PREFIX,
1183
1190
  questionLine,
1184
1191
  isProgressSentence,
1192
+ RUN_TEXT_MAX,
1185
1193
  nextProgress,
1186
1194
  isYes,
1187
1195
  runLogDir,
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  localRunsFilePath,
4
4
  readRunRecords
5
- } from "./chunk-DHUZXAK2.js";
5
+ } from "./chunk-QLCIEJ4C.js";
6
6
  import {
7
7
  STOPPED_SUMMARY,
8
8
  isEndLogLine,
@@ -10,7 +10,7 @@ import {
10
10
  readRunnerConfig,
11
11
  runLogDir,
12
12
  runLogPath
13
- } from "./chunk-NX2LAKNU.js";
13
+ } from "./chunk-EN3XHHWJ.js";
14
14
  import {
15
15
  sanitizeLabel,
16
16
  stripControl
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
 
3
3
  // src/version.ts
4
- var VERSION = true ? "0.2.10" : "0.0.0-dev";
4
+ var VERSION = true ? "0.3.0" : "0.0.0-dev";
5
5
 
6
6
  export {
7
7
  VERSION
@@ -2,6 +2,7 @@
2
2
  import {
3
3
  BoxToolError,
4
4
  RESULT_INSTRUCTION,
5
+ RUN_TEXT_MAX,
5
6
  STOPPED_SUMMARY,
6
7
  appendRunLog,
7
8
  droppedLine,
@@ -15,7 +16,7 @@ import {
15
16
  readRunResult,
16
17
  resultPrUrl,
17
18
  runLogDir
18
- } from "./chunk-NX2LAKNU.js";
19
+ } from "./chunk-EN3XHHWJ.js";
19
20
  import {
20
21
  CONFIG_DIR
21
22
  } from "./chunk-3DIGCVL4.js";
@@ -26,6 +27,50 @@ import { chmodSync, mkdirSync, readFileSync, renameSync, writeFileSync } from "f
26
27
  import { homedir, hostname } from "os";
27
28
  import { basename, dirname, join } from "path";
28
29
  import { createInterface } from "readline";
30
+
31
+ // src/drivers/harness-check.ts
32
+ var HARNESS_STALE_MS = 5 * 6e4;
33
+ var FIRST_CHECK_WAIT_MS = 3e3;
34
+ var HarnessCheck = class {
35
+ constructor(probe, opts) {
36
+ this.probe = probe;
37
+ this.opts = opts;
38
+ }
39
+ probe;
40
+ opts;
41
+ last = null;
42
+ running = null;
43
+ /** Starts a probe unless one is running. It never rejects. */
44
+ refresh() {
45
+ this.running ??= this.probe().then(
46
+ (harnesses) => {
47
+ this.last = { harnesses, at: this.opts.now() };
48
+ },
49
+ (err) => this.opts.log(`harness probe failed: ${err?.message}`)
50
+ ).finally(() => {
51
+ this.running = null;
52
+ });
53
+ return this.running;
54
+ }
55
+ async read() {
56
+ if (!this.last) {
57
+ let timer;
58
+ await Promise.race([
59
+ this.refresh(),
60
+ new Promise((resolve) => {
61
+ timer = setTimeout(resolve, FIRST_CHECK_WAIT_MS);
62
+ })
63
+ ]);
64
+ clearTimeout(timer);
65
+ } else if (this.opts.now() - this.last.at > HARNESS_STALE_MS) {
66
+ void this.refresh();
67
+ }
68
+ const last = this.last;
69
+ return last ? { harnesses: last.harnesses, checkedAt: new Date(last.at).toISOString(), probing: false } : { harnesses: [], checkedAt: null, probing: true };
70
+ }
71
+ };
72
+
73
+ // src/drivers/local.ts
29
74
  var STOPPED = { kind: "failed", summary: STOPPED_SUMMARY };
30
75
  function takeoverSummary(machine) {
31
76
  return `You took this over on ${machine}.`;
@@ -115,6 +160,10 @@ var LocalDriver = class {
115
160
  constructor(deps) {
116
161
  this.deps = deps;
117
162
  this.name = deps.dialect.name;
163
+ this.harnessCheck = new HarnessCheck(
164
+ deps.harnesses ?? (async () => [await deps.dialect.probe()].filter((h) => h !== null)),
165
+ { now: () => this.now(), log: (line) => this.log(line) }
166
+ );
118
167
  this.capabilities = deps.dialect.capabilities;
119
168
  this.runs = new Map(this.load().map((r) => [r.work_id, r]));
120
169
  this.logDir = deps.logDir ?? runLogDir(this.file);
@@ -135,6 +184,7 @@ var LocalDriver = class {
135
184
  stopping = false;
136
185
  logDir;
137
186
  logFailed = false;
187
+ harnessCheck;
138
188
  get repo() {
139
189
  return this.deps.repo ?? gitProbe;
140
190
  }
@@ -157,13 +207,19 @@ var LocalDriver = class {
157
207
  now() {
158
208
  return this.deps.now?.() ?? Date.now();
159
209
  }
210
+ /** Probes the harnesses now, so the first status after the daemon starts answers at once. */
211
+ warmHarnesses() {
212
+ void this.harnessCheck.refresh();
213
+ }
160
214
  async status() {
161
- const harnesses = this.deps.harnesses ? await this.deps.harnesses() : [await this.deps.dialect.probe()].filter((h) => h !== null);
215
+ const { harnesses, checkedAt, probing } = await this.harnessCheck.read();
162
216
  const all = [...this.runs.values()];
163
217
  const unsettled = all.filter((r) => !r.end);
164
218
  return {
165
219
  box: { label: this.deps.label ?? hostname(), driver: this.name },
166
220
  harnesses,
221
+ harnesses_checked_at: checkedAt,
222
+ ...probing ? { probing: true } : {},
167
223
  clients: null,
168
224
  projects: this.deps.repos.map((r) => r.label),
169
225
  threads: {
@@ -517,7 +573,7 @@ ${RESULT_INSTRUCTION}`));
517
573
  await this.end(r, {
518
574
  kind: "settled",
519
575
  ...result ? { result } : {},
520
- ...summary ? { summary: summary.slice(0, SUMMARY_MAX) } : {},
576
+ ...summary ? { summary: summary.slice(0, RUN_TEXT_MAX) } : {},
521
577
  ...pr ? { pr_url: pr } : {}
522
578
  });
523
579
  return;
@@ -39,17 +39,17 @@ import {
39
39
  tilde,
40
40
  unitEnv,
41
41
  unitFor
42
- } from "./chunk-EN7WRLSI.js";
43
- import "./chunk-MWWA2VH7.js";
44
- import "./chunk-NX2LAKNU.js";
42
+ } from "./chunk-34XAQRBL.js";
43
+ import "./chunk-3B5JV6ZP.js";
44
+ import "./chunk-EN3XHHWJ.js";
45
45
  import "./chunk-UBXT5IDU.js";
46
46
  import "./chunk-JX6VG5FE.js";
47
47
  import "./chunk-VK6GV757.js";
48
48
  import "./chunk-R3CLO2FB.js";
49
- import "./chunk-VNX4VJAM.js";
50
- import "./chunk-PRJBCKRP.js";
49
+ import "./chunk-3ITSIARB.js";
50
+ import "./chunk-2PVKRGOX.js";
51
51
  import "./chunk-AG6SI6I2.js";
52
- import "./chunk-UL2WHOQJ.js";
52
+ import "./chunk-NOABXLW3.js";
53
53
  import "./chunk-3DIGCVL4.js";
54
54
  export {
55
55
  DEFAULT_T3_URL,
@@ -1,29 +1,29 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  localRunsFilePath
4
- } from "./chunk-DHUZXAK2.js";
4
+ } from "./chunk-QLCIEJ4C.js";
5
5
  import {
6
6
  installedService,
7
7
  revokeOwnDevice,
8
8
  runSteps,
9
9
  tokenGone
10
- } from "./chunk-EN7WRLSI.js";
10
+ } from "./chunk-34XAQRBL.js";
11
11
  import {
12
12
  runnerStatePath,
13
13
  threadsFilePath
14
- } from "./chunk-MWWA2VH7.js";
14
+ } from "./chunk-3B5JV6ZP.js";
15
15
  import {
16
16
  boxPath,
17
17
  readRunnerConfig
18
- } from "./chunk-NX2LAKNU.js";
18
+ } from "./chunk-EN3XHHWJ.js";
19
19
  import "./chunk-UBXT5IDU.js";
20
20
  import "./chunk-JX6VG5FE.js";
21
21
  import "./chunk-VK6GV757.js";
22
22
  import "./chunk-R3CLO2FB.js";
23
- import "./chunk-VNX4VJAM.js";
24
- import "./chunk-PRJBCKRP.js";
23
+ import "./chunk-3ITSIARB.js";
24
+ import "./chunk-2PVKRGOX.js";
25
25
  import "./chunk-AG6SI6I2.js";
26
- import "./chunk-UL2WHOQJ.js";
26
+ import "./chunk-NOABXLW3.js";
27
27
  import {
28
28
  getOrigin
29
29
  } from "./chunk-3DIGCVL4.js";
@@ -32,7 +32,7 @@ import {
32
32
  import { execFileSync } from "child_process";
33
33
  import { existsSync, readFileSync, rmSync } from "fs";
34
34
  import { homedir } from "os";
35
- var DONE_LINE = "This computer is no longer a Cloop runner. To connect it again: npx -y @cloop/runner connect";
35
+ var DONE_LINE = "This computer is no longer a Cloop runner. To connect it again: npx -y @cloop/runner@latest connect";
36
36
  function unitOrigin(contents) {
37
37
  const plist = /<key>CLOOP_ORIGIN<\/key><string>([^<]+)<\/string>/.exec(contents)?.[1];
38
38
  if (plist) return plist.replace(/&amp;/g, "&");
package/dist/index.js CHANGED
@@ -4,7 +4,7 @@ import {
4
4
  } from "./chunk-UBXT5IDU.js";
5
5
  import {
6
6
  VERSION
7
- } from "./chunk-UL2WHOQJ.js";
7
+ } from "./chunk-NOABXLW3.js";
8
8
  import {
9
9
  applyEnvironmentFlag
10
10
  } from "./chunk-3DIGCVL4.js";
@@ -65,7 +65,7 @@ async function main() {
65
65
  switch (command) {
66
66
  case "login":
67
67
  case "auth": {
68
- const { loginCommand } = await import("./login-DXPJ3ZOA.js");
68
+ const { loginCommand } = await import("./login-XS2IFIUX.js");
69
69
  await loginCommand(argv);
70
70
  break;
71
71
  }
@@ -75,57 +75,57 @@ async function main() {
75
75
  break;
76
76
  }
77
77
  case "serve": {
78
- const { startMcpServer } = await import("./mcp-server-4UMYMJ5P.js");
78
+ const { startMcpServer } = await import("./mcp-server-R47CKE6A.js");
79
79
  await startMcpServer();
80
80
  break;
81
81
  }
82
82
  case "statusline": {
83
- const { statuslineCommand } = await import("./statusline-AV2F2IM4.js");
83
+ const { statuslineCommand } = await import("./statusline-RI62KCQX.js");
84
84
  statuslineCommand();
85
85
  break;
86
86
  }
87
87
  case "connect": {
88
- const { connectCommand } = await import("./connect-GURZFURZ.js");
88
+ const { connectCommand } = await import("./connect-LLURHARY.js");
89
89
  await connectCommand(argv.slice(1));
90
90
  break;
91
91
  }
92
92
  case "use": {
93
- const { useCommand } = await import("./use-52LTRRXJ.js");
93
+ const { useCommand } = await import("./use-2OOFS53J.js");
94
94
  process.exitCode = await useCommand(argv.slice(1));
95
95
  break;
96
96
  }
97
97
  case "disconnect": {
98
- const { disconnectCommand } = await import("./disconnect-HGQW7TVG.js");
98
+ const { disconnectCommand } = await import("./disconnect-WAQTAXN3.js");
99
99
  await disconnectCommand(argv.slice(1));
100
100
  break;
101
101
  }
102
102
  case "box": {
103
- const { boxCommand } = await import("./box-P6LMNVYG.js");
103
+ const { boxCommand } = await import("./box-7SVME4E5.js");
104
104
  await boxCommand(argv.slice(1));
105
105
  break;
106
106
  }
107
107
  case "runs": {
108
- const { runsCommand } = await import("./runs-HRDQ7YCY.js");
108
+ const { runsCommand } = await import("./runs-4ZJOIB5S.js");
109
109
  process.exitCode = runsCommand();
110
110
  break;
111
111
  }
112
112
  case "watch": {
113
- const { watchCommand } = await import("./runs-HRDQ7YCY.js");
113
+ const { watchCommand } = await import("./runs-4ZJOIB5S.js");
114
114
  process.exitCode = await watchCommand(argv.slice(1));
115
115
  break;
116
116
  }
117
117
  case "takeover": {
118
- const { takeoverCommand } = await import("./takeover-PDYTQY5D.js");
118
+ const { takeoverCommand } = await import("./takeover-F5SEY7WI.js");
119
119
  process.exitCode = await takeoverCommand(argv.slice(1));
120
120
  break;
121
121
  }
122
122
  case "resume": {
123
- const { resumeCommand } = await import("./runs-HRDQ7YCY.js");
123
+ const { resumeCommand } = await import("./runs-4ZJOIB5S.js");
124
124
  process.exitCode = await resumeCommand(argv.slice(1));
125
125
  break;
126
126
  }
127
127
  case "runner": {
128
- const { runnerCommand } = await import("./runner-SPOKUMLM.js");
128
+ const { runnerCommand } = await import("./runner-R4Z62XVC.js");
129
129
  await runnerCommand(argv.slice(1));
130
130
  break;
131
131
  }
@@ -3,9 +3,9 @@ import {
3
3
  deviceLogin,
4
4
  loginCommand,
5
5
  refusalSentence
6
- } from "./chunk-PRJBCKRP.js";
6
+ } from "./chunk-2PVKRGOX.js";
7
7
  import "./chunk-AG6SI6I2.js";
8
- import "./chunk-UL2WHOQJ.js";
8
+ import "./chunk-NOABXLW3.js";
9
9
  import "./chunk-3DIGCVL4.js";
10
10
  export {
11
11
  deviceLogin,
@@ -33,7 +33,7 @@ import {
33
33
  } from "./chunk-AG6SI6I2.js";
34
34
  import {
35
35
  VERSION
36
- } from "./chunk-UL2WHOQJ.js";
36
+ } from "./chunk-NOABXLW3.js";
37
37
  import {
38
38
  getMeshUrl,
39
39
  getToken
@@ -2,10 +2,10 @@
2
2
  import {
3
3
  connectWebhook,
4
4
  runnerCommand
5
- } from "./chunk-VNX4VJAM.js";
6
- import "./chunk-PRJBCKRP.js";
5
+ } from "./chunk-3ITSIARB.js";
6
+ import "./chunk-2PVKRGOX.js";
7
7
  import "./chunk-AG6SI6I2.js";
8
- import "./chunk-UL2WHOQJ.js";
8
+ import "./chunk-NOABXLW3.js";
9
9
  import "./chunk-3DIGCVL4.js";
10
10
  export {
11
11
  connectWebhook,
@@ -8,9 +8,9 @@ import {
8
8
  runsCommand,
9
9
  sessionFolder,
10
10
  watchCommand
11
- } from "./chunk-HI3HDN35.js";
12
- import "./chunk-DHUZXAK2.js";
13
- import "./chunk-NX2LAKNU.js";
11
+ } from "./chunk-NK6MHHYP.js";
12
+ import "./chunk-QLCIEJ4C.js";
13
+ import "./chunk-EN3XHHWJ.js";
14
14
  import "./chunk-VK6GV757.js";
15
15
  import "./chunk-3DIGCVL4.js";
16
16
  export {
@@ -7,7 +7,7 @@ import {
7
7
  } from "./chunk-VK6GV757.js";
8
8
  import {
9
9
  VERSION
10
- } from "./chunk-UL2WHOQJ.js";
10
+ } from "./chunk-NOABXLW3.js";
11
11
  import {
12
12
  getToken
13
13
  } from "./chunk-3DIGCVL4.js";
@@ -9,11 +9,11 @@ import {
9
9
  takeoverDir,
10
10
  writeTakeoverReply,
11
11
  writeTakeoverRequest
12
- } from "./chunk-C6EODIE5.js";
13
- import "./chunk-HI3HDN35.js";
14
- import "./chunk-DHUZXAK2.js";
15
- import "./chunk-MWWA2VH7.js";
16
- import "./chunk-NX2LAKNU.js";
12
+ } from "./chunk-7CPNLUDI.js";
13
+ import "./chunk-NK6MHHYP.js";
14
+ import "./chunk-QLCIEJ4C.js";
15
+ import "./chunk-3B5JV6ZP.js";
16
+ import "./chunk-EN3XHHWJ.js";
17
17
  import "./chunk-JX6VG5FE.js";
18
18
  import "./chunk-VK6GV757.js";
19
19
  import "./chunk-AG6SI6I2.js";
@@ -2,20 +2,20 @@
2
2
  import {
3
3
  DRIVER_NAME,
4
4
  runConnect
5
- } from "./chunk-EN7WRLSI.js";
6
- import "./chunk-MWWA2VH7.js";
5
+ } from "./chunk-34XAQRBL.js";
6
+ import "./chunk-3B5JV6ZP.js";
7
7
  import {
8
8
  isLocal,
9
9
  readRunnerConfig
10
- } from "./chunk-NX2LAKNU.js";
10
+ } from "./chunk-EN3XHHWJ.js";
11
11
  import "./chunk-UBXT5IDU.js";
12
12
  import "./chunk-JX6VG5FE.js";
13
13
  import "./chunk-VK6GV757.js";
14
14
  import "./chunk-R3CLO2FB.js";
15
- import "./chunk-VNX4VJAM.js";
16
- import "./chunk-PRJBCKRP.js";
15
+ import "./chunk-3ITSIARB.js";
16
+ import "./chunk-2PVKRGOX.js";
17
17
  import "./chunk-AG6SI6I2.js";
18
- import "./chunk-UL2WHOQJ.js";
18
+ import "./chunk-NOABXLW3.js";
19
19
  import "./chunk-3DIGCVL4.js";
20
20
 
21
21
  // src/commands/use.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cloop/runner",
3
- "version": "0.2.10",
3
+ "version": "0.3.0",
4
4
  "private": false,
5
5
  "license": "MIT",
6
6
  "description": "Make your machine and your agents Cloop runners: device login, the runner daemon, the Cloop MCP server, and Claude Code hooks.",