@cloop/runner 0.3.30 → 0.3.33

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 (25) hide show
  1. package/dist/{box-NK3P3ESD.js → box-PZHNXUDE.js} +158 -37
  2. package/dist/{chunk-OTZDNYX4.js → chunk-5BJGP7FY.js} +2 -2
  3. package/dist/{chunk-HGKTPD5Z.js → chunk-6N6FIYOS.js} +1 -1
  4. package/dist/{chunk-3YJD6J2N.js → chunk-7BLD64A4.js} +1 -1
  5. package/dist/{chunk-IYZLO64O.js → chunk-FAHTEHXP.js} +5 -5
  6. package/dist/{chunk-J4YN6KXM.js → chunk-FIBH3C5S.js} +951 -73
  7. package/dist/{chunk-JQGHB2EJ.js → chunk-FNHXCSH2.js} +1 -1
  8. package/dist/{chunk-DYA2BUDB.js → chunk-LZ2XFUEA.js} +6 -6
  9. package/dist/{chunk-NTXQLEMQ.js → chunk-SBYSVZ7J.js} +94 -2
  10. package/dist/{chunk-EOWS3JIY.js → chunk-WE5HZZLE.js} +25 -10
  11. package/dist/{connect-RYIPSXZK.js → connect-V6SFHRT4.js} +7 -8
  12. package/dist/{disconnect-FLRZVPXW.js → disconnect-VVEZIJU2.js} +7 -8
  13. package/dist/{existing-runner-ATMNX2FX.js → existing-runner-ZEGFLOH2.js} +7 -8
  14. package/dist/{hook-activity-GAJ5NABA.js → hook-activity-3T6IMEM6.js} +2 -3
  15. package/dist/{hook-session-start-5JYNMGX4.js → hook-session-start-DLP77G4H.js} +5 -7
  16. package/dist/index.js +20 -17
  17. package/dist/{login-CNTB5SXY.js → login-3COLQ4I6.js} +3 -3
  18. package/dist/{mcp-server-35YMJHA6.js → mcp-server-5KJ5WZOX.js} +8 -10
  19. package/dist/{runner-JDJUWIGC.js → runner-COQXHA6D.js} +4 -4
  20. package/dist/{runs-CKN4DINY.js → runs-W4K74UPN.js} +2 -2
  21. package/dist/{statusline-UD4OFVWL.js → statusline-C4LLNBIE.js} +1 -1
  22. package/dist/{takeover-M4KKYDHN.js → takeover-ATMQCTKQ.js} +5 -6
  23. package/dist/{use-AFCJUIGA.js → use-KMNUETBR.js} +7 -8
  24. package/package.json +1 -1
  25. package/dist/chunk-ES5BRAKJ.js +0 -88
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
 
3
3
  // src/version.ts
4
- var VERSION = true ? "0.3.30" : "0.0.0-dev";
4
+ var VERSION = true ? "0.3.33" : "0.0.0-dev";
5
5
 
6
6
  export {
7
7
  VERSION
@@ -2,23 +2,23 @@
2
2
  import {
3
3
  findRun,
4
4
  ownHarness
5
- } from "./chunk-HGKTPD5Z.js";
5
+ } from "./chunk-6N6FIYOS.js";
6
6
  import {
7
7
  lockThreadsFile,
8
8
  threadsFilePath
9
- } from "./chunk-3YJD6J2N.js";
9
+ } from "./chunk-7BLD64A4.js";
10
10
  import {
11
11
  localRunsFilePath,
12
12
  readRunRecords,
13
13
  runHarness,
14
14
  takeoverSummary
15
- } from "./chunk-EOWS3JIY.js";
16
- import {
17
- shortMachineName
18
- } from "./chunk-NTXQLEMQ.js";
15
+ } from "./chunk-WE5HZZLE.js";
19
16
  import {
20
17
  sanitizeLabel
21
18
  } from "./chunk-VK6GV757.js";
19
+ import {
20
+ shortMachineName
21
+ } from "./chunk-SBYSVZ7J.js";
22
22
 
23
23
  // src/commands/takeover.ts
24
24
  import { spawnSync } from "child_process";
@@ -1,7 +1,85 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
- api
4
- } from "./chunk-ES5BRAKJ.js";
3
+ getOrigin,
4
+ getToken
5
+ } from "./chunk-D5UZW42X.js";
6
+
7
+ // src/api.ts
8
+ var REAUTH_MESSAGE = "Cloop session expired or unauthenticated. Run `cloop login`.";
9
+ var ReauthError = class extends Error {
10
+ constructor(message = REAUTH_MESSAGE) {
11
+ super(message);
12
+ this.name = "ReauthError";
13
+ }
14
+ };
15
+ var ApiError = class extends Error {
16
+ constructor(status, message, body = "") {
17
+ super(message);
18
+ this.status = status;
19
+ this.body = body;
20
+ this.name = "ApiError";
21
+ }
22
+ status;
23
+ body;
24
+ };
25
+ function buildUrl(origin, path, query) {
26
+ const url = new URL(path, `${origin}/`);
27
+ if (query) {
28
+ for (const [key, value] of Object.entries(query)) {
29
+ if (value !== void 0) url.searchParams.set(key, value);
30
+ }
31
+ }
32
+ return url.toString();
33
+ }
34
+ async function api(path, opts = {}) {
35
+ const {
36
+ method = "GET",
37
+ body,
38
+ query,
39
+ auth = true,
40
+ fetchFn = fetch,
41
+ origin = getOrigin(),
42
+ timeoutMs
43
+ } = opts;
44
+ const headers = { accept: "application/json" };
45
+ if (auth) {
46
+ const token = getToken();
47
+ if (!token) throw new ReauthError();
48
+ headers.authorization = `Bearer ${token}`;
49
+ }
50
+ if (body !== void 0) headers["content-type"] = "application/json";
51
+ const url = buildUrl(origin, path, query);
52
+ const init = {
53
+ method,
54
+ headers,
55
+ ...body !== void 0 ? { body: JSON.stringify(body) } : {}
56
+ };
57
+ const attempt = () => fetchFn(url, timeoutMs ? { ...init, signal: AbortSignal.timeout(timeoutMs) } : init);
58
+ let res;
59
+ try {
60
+ res = await attempt();
61
+ } catch (err) {
62
+ try {
63
+ res = await attempt();
64
+ } catch {
65
+ const detail = err instanceof Error ? err.message : String(err);
66
+ throw new ApiError(0, `Network error reaching ${url}: ${detail}`);
67
+ }
68
+ }
69
+ if (res.status === 401) throw new ReauthError();
70
+ if (!res.ok) {
71
+ const text2 = await res.text().catch(() => "");
72
+ throw new ApiError(
73
+ res.status,
74
+ `Cloop API ${res.status} for ${path}: ${text2.slice(0, 300)}`,
75
+ text2
76
+ );
77
+ }
78
+ if (res.status === 204) return void 0;
79
+ const text = await res.text();
80
+ if (!text) return void 0;
81
+ return JSON.parse(text);
82
+ }
5
83
 
6
84
  // src/presence.ts
7
85
  import { execFileSync as execFileSync2 } from "child_process";
@@ -73,6 +151,16 @@ function resolveMachine() {
73
151
  function shortMachineName(machine = getMachine()) {
74
152
  return machine.split(".")[0] || machine;
75
153
  }
154
+ function defaultDeviceName() {
155
+ if (osPlatform() === "darwin") {
156
+ try {
157
+ const name = execFileSync2("scutil", ["--get", "ComputerName"], SCUTIL_OPTS).trim();
158
+ if (name) return name;
159
+ } catch {
160
+ }
161
+ }
162
+ return shortMachineName();
163
+ }
76
164
  var PLATFORM_LABELS = {
77
165
  claude: "Claude Code",
78
166
  codex: "Codex",
@@ -139,8 +227,12 @@ var HeartbeatClient = class {
139
227
  };
140
228
 
141
229
  export {
230
+ ReauthError,
231
+ ApiError,
232
+ api,
142
233
  getMachine,
143
234
  shortMachineName,
235
+ defaultDeviceName,
144
236
  getName,
145
237
  getSurface,
146
238
  detectPlatform,
@@ -139,7 +139,8 @@ function runLogPath(dir, workId) {
139
139
  return SAFE_ID.test(workId) ? join3(dir, `${workId}.log`) : null;
140
140
  }
141
141
  var SECRETS = [
142
- [/-----BEGIN [A-Z ]*PRIVATE KEY-----.*/g, "[redacted private key]"],
142
+ // The whole block, to its END line or the end of the text: a cut-off paste still hides its body.
143
+ [/-----BEGIN ([A-Z0-9 ]+)-----[\s\S]*?(?:-----END \1-----|$)/g, "[redacted key block]"],
143
144
  [/\b(Bearer|Basic)\s+[A-Za-z0-9._~+/=-]{8,}/gi, "$1 [redacted]"],
144
145
  [/(:\/\/)[^\s/@:]+:[^\s/@]+@/g, "$1[redacted]@"],
145
146
  [
@@ -154,7 +155,7 @@ var SECRETS = [
154
155
  /(--?[\w-]*(?:token|secret|password|api-key|apikey)[\w-]*[ =])["']?[^\s"']{4,}["']?/gi,
155
156
  "$1[redacted]"
156
157
  ],
157
- [/\b(?:sk|pk|rk)-[A-Za-z0-9_-]{16,}/g, "[redacted]"],
158
+ [/\b(?:sk|pk|rk)[-_][A-Za-z0-9_-]{16,}/g, "[redacted]"],
158
159
  [/\b(?:gh[pousr]_[A-Za-z0-9]{20,}|github_pat_[A-Za-z0-9_]{20,})/g, "[redacted]"],
159
160
  [/\bxox[abprs]-[A-Za-z0-9-]{10,}/g, "[redacted]"],
160
161
  [/\b(?:AKIA|ASIA)[0-9A-Z]{16}\b/g, "[redacted]"],
@@ -578,6 +579,7 @@ var RESULT_INSTRUCTION = [
578
579
  "When the ask is to find, compare, summarise or research something, put the whole answer in a doc output with a body, so the owner has one page to read; the summary stays one or two sentences."
579
580
  ].join("\n");
580
581
  var SUMMARY_MAX = 4e3;
582
+ var ASKS_MAX = 1e3;
581
583
  var DOC_BODY_MAX = 8e3;
582
584
  var ITEMS_MAX = 10;
583
585
  var BLOCK = /```cloop-result\s*\n([\s\S]*?)```/g;
@@ -660,6 +662,7 @@ function readRunResult(message) {
660
662
  const summary = typeof value?.summary === "string" ? value.summary.trim() : "";
661
663
  if (!summary) return none;
662
664
  const list = (v) => Array.isArray(v) ? v : [];
665
+ const asks = typeof value?.asks === "string" ? value.asks.trim() : "";
663
666
  const outputs = list(value?.outputs).flatMap((o) => readOutput(o) ?? []);
664
667
  const checks = list(value?.checks).flatMap((c) => readCheck(c) ?? []);
665
668
  return {
@@ -667,7 +670,8 @@ function readRunResult(message) {
667
670
  summary: summary.length > SUMMARY_MAX ? `${summary.slice(0, SUMMARY_MAX - 1)}\u2026` : summary,
668
671
  outputs: outputs.slice(0, ITEMS_MAX),
669
672
  checks: checks.slice(0, ITEMS_MAX),
670
- ...value?.nothing_new === true ? { nothing_new: true } : {}
673
+ ...value?.nothing_new === true ? { nothing_new: true } : {},
674
+ ...asks ? { asks: asks.length > ASKS_MAX ? `${asks.slice(0, ASKS_MAX - 1)}\u2026` : asks } : {}
671
675
  },
672
676
  dropped: { outputs: list(value?.outputs).length - outputs.length, checks: list(value?.checks).length - checks.length }
673
677
  };
@@ -1597,7 +1601,10 @@ var T3Driver = class {
1597
1601
  type: "worktree",
1598
1602
  baseRef: this.baseRefFor(project.workspaceRoot)
1599
1603
  },
1604
+ // Stored images belong to the thread their ids name, so the thread takes that id.
1605
+ ...photos2.attachments.length ? { threadId: a.work_id } : {},
1600
1606
  initialMessage: {
1607
+ ...photos2.attachments.length ? { messageId: a.work_id } : {},
1601
1608
  text: [a.prompt, photos2.line, RESULT_INSTRUCTION].filter(Boolean).join("\n\n"),
1602
1609
  attachments: photos2.attachments
1603
1610
  }
@@ -1626,23 +1633,30 @@ var T3Driver = class {
1626
1633
  ...launched.resumed ? {} : delivery(a.attachments, photos2.attachments.length)
1627
1634
  };
1628
1635
  }
1629
- /** The Task's photos as T3 image attachments, which T3 shows in the thread and hands its harness. */
1636
+ /**
1637
+ * The Task's photos, stored in T3 as image attachments, which T3 shows in the
1638
+ * thread and hands its harness. The work_id is the thread and message id, so a
1639
+ * retried launch stores the same bytes under the same ids.
1640
+ */
1630
1641
  async photos(a) {
1631
1642
  if (!a.attachments?.length) return { attachments: [], line: "" };
1632
1643
  const { images, missed } = await fetchImages(a.attachments, {
1633
1644
  log: (line) => this.log(`${line} work=${a.work_id}`)
1634
1645
  });
1635
1646
  this.log(`attachments work=${a.work_id} attached=${images.length} missed=${missed}`);
1636
- return {
1647
+ if (!images.length) return { attachments: [], line: attachedLine(0, missed) };
1648
+ const stored = await this.t3.rpc("assets.persistChatAttachments", {
1649
+ threadId: a.work_id,
1650
+ messageId: a.work_id,
1637
1651
  attachments: images.map((image) => ({
1638
1652
  type: "image",
1639
1653
  name: image.name,
1640
- mimeType: image.type,
1654
+ mimeType: image.type.toLowerCase(),
1641
1655
  sizeBytes: image.data.length,
1642
- dataUrl: `data:${image.type};base64,${image.data.toString("base64")}`
1643
- })),
1644
- line: attachedLine(images.length, missed)
1645
- };
1656
+ dataUrl: `data:${image.type.toLowerCase()};base64,${image.data.toString("base64")}`
1657
+ }))
1658
+ });
1659
+ return { attachments: stored.attachments, line: attachedLine(images.length, missed) };
1646
1660
  }
1647
1661
  /**
1648
1662
  * Say something to a thread. While the thread waits on a question, only
@@ -3068,6 +3082,7 @@ export {
3068
3082
  writeBoxConfig,
3069
3083
  runLogDir,
3070
3084
  runLogPath,
3085
+ redactSecrets,
3071
3086
  STOPPED_SUMMARY,
3072
3087
  isEndLogLine,
3073
3088
  commandFor,
@@ -53,18 +53,17 @@ import {
53
53
  which,
54
54
  workFolder,
55
55
  workFolderLine
56
- } from "./chunk-J4YN6KXM.js";
56
+ } from "./chunk-FIBH3C5S.js";
57
57
  import "./chunk-52CUSFDQ.js";
58
- import "./chunk-3YJD6J2N.js";
59
- import "./chunk-EOWS3JIY.js";
60
- import "./chunk-NTXQLEMQ.js";
58
+ import "./chunk-7BLD64A4.js";
59
+ import "./chunk-WE5HZZLE.js";
61
60
  import "./chunk-VK6GV757.js";
62
61
  import "./chunk-365HFCQQ.js";
63
62
  import "./chunk-PKIEWBR7.js";
64
- import "./chunk-OTZDNYX4.js";
65
- import "./chunk-IYZLO64O.js";
66
- import "./chunk-ES5BRAKJ.js";
67
- import "./chunk-JQGHB2EJ.js";
63
+ import "./chunk-5BJGP7FY.js";
64
+ import "./chunk-FAHTEHXP.js";
65
+ import "./chunk-SBYSVZ7J.js";
66
+ import "./chunk-FNHXCSH2.js";
68
67
  import "./chunk-D5UZW42X.js";
69
68
  export {
70
69
  DEFAULT_T3_URL,
@@ -7,18 +7,17 @@ import {
7
7
  runnerOrigin,
8
8
  stopService,
9
9
  unitOrigin
10
- } from "./chunk-J4YN6KXM.js";
10
+ } from "./chunk-FIBH3C5S.js";
11
11
  import "./chunk-52CUSFDQ.js";
12
- import "./chunk-3YJD6J2N.js";
13
- import "./chunk-EOWS3JIY.js";
14
- import "./chunk-NTXQLEMQ.js";
12
+ import "./chunk-7BLD64A4.js";
13
+ import "./chunk-WE5HZZLE.js";
15
14
  import "./chunk-VK6GV757.js";
16
15
  import "./chunk-365HFCQQ.js";
17
16
  import "./chunk-PKIEWBR7.js";
18
- import "./chunk-OTZDNYX4.js";
19
- import "./chunk-IYZLO64O.js";
20
- import "./chunk-ES5BRAKJ.js";
21
- import "./chunk-JQGHB2EJ.js";
17
+ import "./chunk-5BJGP7FY.js";
18
+ import "./chunk-FAHTEHXP.js";
19
+ import "./chunk-SBYSVZ7J.js";
20
+ import "./chunk-FNHXCSH2.js";
22
21
  import "./chunk-D5UZW42X.js";
23
22
  export {
24
23
  disconnect,
@@ -2,18 +2,17 @@
2
2
  import {
3
3
  existingRunnerEnvironment,
4
4
  pinExistingRunner
5
- } from "./chunk-J4YN6KXM.js";
5
+ } from "./chunk-FIBH3C5S.js";
6
6
  import "./chunk-52CUSFDQ.js";
7
- import "./chunk-3YJD6J2N.js";
8
- import "./chunk-EOWS3JIY.js";
9
- import "./chunk-NTXQLEMQ.js";
7
+ import "./chunk-7BLD64A4.js";
8
+ import "./chunk-WE5HZZLE.js";
10
9
  import "./chunk-VK6GV757.js";
11
10
  import "./chunk-365HFCQQ.js";
12
11
  import "./chunk-PKIEWBR7.js";
13
- import "./chunk-OTZDNYX4.js";
14
- import "./chunk-IYZLO64O.js";
15
- import "./chunk-ES5BRAKJ.js";
16
- import "./chunk-JQGHB2EJ.js";
12
+ import "./chunk-5BJGP7FY.js";
13
+ import "./chunk-FAHTEHXP.js";
14
+ import "./chunk-SBYSVZ7J.js";
15
+ import "./chunk-FNHXCSH2.js";
17
16
  import "./chunk-D5UZW42X.js";
18
17
  export {
19
18
  existingRunnerEnvironment,
@@ -5,6 +5,7 @@ import {
5
5
  toolPhrase,
6
6
  writeSessionState
7
7
  } from "./chunk-EVIVOEJY.js";
8
+ import "./chunk-VK6GV757.js";
8
9
  import {
9
10
  HeartbeatClient,
10
11
  detectPlatform,
@@ -12,9 +13,7 @@ import {
12
13
  getName,
13
14
  getSurface,
14
15
  sanitizeSessionKey
15
- } from "./chunk-NTXQLEMQ.js";
16
- import "./chunk-VK6GV757.js";
17
- import "./chunk-ES5BRAKJ.js";
16
+ } from "./chunk-SBYSVZ7J.js";
18
17
  import {
19
18
  getToken
20
19
  } from "./chunk-D5UZW42X.js";
@@ -1,18 +1,16 @@
1
1
  #!/usr/bin/env node
2
+ import {
3
+ sanitizeLabel
4
+ } from "./chunk-VK6GV757.js";
2
5
  import {
3
6
  HeartbeatClient,
7
+ api,
4
8
  detectPlatform,
5
9
  getMachine,
6
10
  getName,
7
11
  getSurface,
8
12
  newSessionKey
9
- } from "./chunk-NTXQLEMQ.js";
10
- import {
11
- sanitizeLabel
12
- } from "./chunk-VK6GV757.js";
13
- import {
14
- api
15
- } from "./chunk-ES5BRAKJ.js";
13
+ } from "./chunk-SBYSVZ7J.js";
16
14
  import {
17
15
  getToken
18
16
  } from "./chunk-D5UZW42X.js";
package/dist/index.js CHANGED
@@ -4,7 +4,7 @@ import {
4
4
  } from "./chunk-365HFCQQ.js";
5
5
  import {
6
6
  VERSION
7
- } from "./chunk-JQGHB2EJ.js";
7
+ } from "./chunk-FNHXCSH2.js";
8
8
  import {
9
9
  applyEnvironmentFlag
10
10
  } from "./chunk-D5UZW42X.js";
@@ -40,7 +40,10 @@ Usage:
40
40
  link from T3 Code (Settings, Connections,
41
41
  Create pairing link) at the question, or pass
42
42
  it with --t3-pair. Cloop shows the threads you
43
- started yourself; --hide-other-threads hides them
43
+ started yourself; --hide-other-threads hides them.
44
+ Cloop also reads what you and your agents say
45
+ and do in those threads, redacted here, never
46
+ tool output or files
44
47
  cloop use t3|claude-code|codex Run Cloop work here with that harness. It reconnects
45
48
  this machine, swaps its service, and keeps the choice
46
49
  cloop disconnect [--yes] Stop being a Cloop machine in one environment: revoke
@@ -65,7 +68,7 @@ Add --staging to any command to use Cloop staging instead of production.
65
68
  A production machine and a staging machine can run side by side on one computer.
66
69
  `;
67
70
  async function pinExistingRunner() {
68
- const { pinExistingRunner: pin } = await import("./existing-runner-ATMNX2FX.js");
71
+ const { pinExistingRunner: pin } = await import("./existing-runner-ZEGFLOH2.js");
69
72
  const { note } = pin();
70
73
  if (note) console.error(note);
71
74
  }
@@ -73,7 +76,7 @@ async function main() {
73
76
  switch (command) {
74
77
  case "login":
75
78
  case "auth": {
76
- const { loginCommand } = await import("./login-CNTB5SXY.js");
79
+ const { loginCommand } = await import("./login-3COLQ4I6.js");
77
80
  await loginCommand(argv);
78
81
  break;
79
82
  }
@@ -83,61 +86,61 @@ async function main() {
83
86
  break;
84
87
  }
85
88
  case "serve": {
86
- const { startMcpServer } = await import("./mcp-server-35YMJHA6.js");
89
+ const { startMcpServer } = await import("./mcp-server-5KJ5WZOX.js");
87
90
  await startMcpServer();
88
91
  break;
89
92
  }
90
93
  case "statusline": {
91
- const { statuslineCommand } = await import("./statusline-UD4OFVWL.js");
94
+ const { statuslineCommand } = await import("./statusline-C4LLNBIE.js");
92
95
  statuslineCommand();
93
96
  break;
94
97
  }
95
98
  case "connect": {
96
- const { connectCommand } = await import("./connect-RYIPSXZK.js");
99
+ const { connectCommand } = await import("./connect-V6SFHRT4.js");
97
100
  await connectCommand(argv.slice(1));
98
101
  break;
99
102
  }
100
103
  case "use": {
101
- const { useCommand } = await import("./use-AFCJUIGA.js");
104
+ const { useCommand } = await import("./use-KMNUETBR.js");
102
105
  process.exitCode = await useCommand(argv.slice(1));
103
106
  break;
104
107
  }
105
108
  case "disconnect": {
106
- const { disconnectCommand } = await import("./disconnect-FLRZVPXW.js");
109
+ const { disconnectCommand } = await import("./disconnect-VVEZIJU2.js");
107
110
  await disconnectCommand(argv.slice(1));
108
111
  break;
109
112
  }
110
113
  case "box": {
111
- const { boxCommand } = await import("./box-NK3P3ESD.js");
114
+ const { boxCommand } = await import("./box-PZHNXUDE.js");
112
115
  await boxCommand(argv.slice(1));
113
116
  break;
114
117
  }
115
118
  case "runs": {
116
119
  await pinExistingRunner();
117
- const { runsCommand } = await import("./runs-CKN4DINY.js");
120
+ const { runsCommand } = await import("./runs-W4K74UPN.js");
118
121
  process.exitCode = runsCommand();
119
122
  break;
120
123
  }
121
124
  case "watch": {
122
125
  await pinExistingRunner();
123
- const { watchCommand } = await import("./runs-CKN4DINY.js");
126
+ const { watchCommand } = await import("./runs-W4K74UPN.js");
124
127
  process.exitCode = await watchCommand(argv.slice(1));
125
128
  break;
126
129
  }
127
130
  case "takeover": {
128
131
  await pinExistingRunner();
129
- const { takeoverCommand } = await import("./takeover-M4KKYDHN.js");
132
+ const { takeoverCommand } = await import("./takeover-ATMQCTKQ.js");
130
133
  process.exitCode = await takeoverCommand(argv.slice(1));
131
134
  break;
132
135
  }
133
136
  case "resume": {
134
137
  await pinExistingRunner();
135
- const { resumeCommand } = await import("./runs-CKN4DINY.js");
138
+ const { resumeCommand } = await import("./runs-W4K74UPN.js");
136
139
  process.exitCode = await resumeCommand(argv.slice(1));
137
140
  break;
138
141
  }
139
142
  case "runner": {
140
- const { runnerCommand } = await import("./runner-JDJUWIGC.js");
143
+ const { runnerCommand } = await import("./runner-COQXHA6D.js");
141
144
  await runnerCommand(argv.slice(1));
142
145
  break;
143
146
  }
@@ -146,10 +149,10 @@ async function main() {
146
149
  const { runnerPermissionHook } = await import("./read-permissions-EGSGI4HL.js");
147
150
  await runnerPermissionHook();
148
151
  } else if (argv[1] === "session-start") {
149
- const { hookSessionStart } = await import("./hook-session-start-5JYNMGX4.js");
152
+ const { hookSessionStart } = await import("./hook-session-start-DLP77G4H.js");
150
153
  await hookSessionStart();
151
154
  } else if (argv[1] === "activity") {
152
- const { hookActivity } = await import("./hook-activity-GAJ5NABA.js");
155
+ const { hookActivity } = await import("./hook-activity-3T6IMEM6.js");
153
156
  await hookActivity();
154
157
  } else {
155
158
  console.error(`Unknown hook: ${argv[1] ?? "(none)"}`);
@@ -3,9 +3,9 @@ import {
3
3
  deviceLogin,
4
4
  loginCommand,
5
5
  refusalSentence
6
- } from "./chunk-IYZLO64O.js";
7
- import "./chunk-ES5BRAKJ.js";
8
- import "./chunk-JQGHB2EJ.js";
6
+ } from "./chunk-FAHTEHXP.js";
7
+ import "./chunk-SBYSVZ7J.js";
8
+ import "./chunk-FNHXCSH2.js";
9
9
  import "./chunk-D5UZW42X.js";
10
10
  export {
11
11
  deviceLogin,
@@ -15,25 +15,23 @@ import {
15
15
  MeshSocket,
16
16
  defaultSocketFactory
17
17
  } from "./chunk-52CUSFDQ.js";
18
+ import {
19
+ sanitizeLabel,
20
+ sanitizeUntrusted
21
+ } from "./chunk-VK6GV757.js";
18
22
  import {
19
23
  HeartbeatClient,
24
+ ReauthError,
25
+ api,
20
26
  detectPlatform,
21
27
  getMachine,
22
28
  getName,
23
29
  getSurface,
24
30
  newSessionKey
25
- } from "./chunk-NTXQLEMQ.js";
26
- import {
27
- sanitizeLabel,
28
- sanitizeUntrusted
29
- } from "./chunk-VK6GV757.js";
30
- import {
31
- ReauthError,
32
- api
33
- } from "./chunk-ES5BRAKJ.js";
31
+ } from "./chunk-SBYSVZ7J.js";
34
32
  import {
35
33
  VERSION
36
- } from "./chunk-JQGHB2EJ.js";
34
+ } from "./chunk-FNHXCSH2.js";
37
35
  import {
38
36
  getMeshUrl,
39
37
  getToken
@@ -2,10 +2,10 @@
2
2
  import {
3
3
  connectWebhook,
4
4
  runnerCommand
5
- } from "./chunk-OTZDNYX4.js";
6
- import "./chunk-IYZLO64O.js";
7
- import "./chunk-ES5BRAKJ.js";
8
- import "./chunk-JQGHB2EJ.js";
5
+ } from "./chunk-5BJGP7FY.js";
6
+ import "./chunk-FAHTEHXP.js";
7
+ import "./chunk-SBYSVZ7J.js";
8
+ import "./chunk-FNHXCSH2.js";
9
9
  import "./chunk-D5UZW42X.js";
10
10
  export {
11
11
  connectWebhook,
@@ -9,8 +9,8 @@ import {
9
9
  runsCommand,
10
10
  sessionFolder,
11
11
  watchCommand
12
- } from "./chunk-HGKTPD5Z.js";
13
- import "./chunk-EOWS3JIY.js";
12
+ } from "./chunk-6N6FIYOS.js";
13
+ import "./chunk-WE5HZZLE.js";
14
14
  import "./chunk-VK6GV757.js";
15
15
  import "./chunk-D5UZW42X.js";
16
16
  export {
@@ -7,7 +7,7 @@ import {
7
7
  } from "./chunk-VK6GV757.js";
8
8
  import {
9
9
  VERSION
10
- } from "./chunk-JQGHB2EJ.js";
10
+ } from "./chunk-FNHXCSH2.js";
11
11
  import {
12
12
  getToken
13
13
  } from "./chunk-D5UZW42X.js";
@@ -9,13 +9,12 @@ import {
9
9
  takeoverDir,
10
10
  writeTakeoverReply,
11
11
  writeTakeoverRequest
12
- } from "./chunk-DYA2BUDB.js";
13
- import "./chunk-HGKTPD5Z.js";
14
- import "./chunk-3YJD6J2N.js";
15
- import "./chunk-EOWS3JIY.js";
16
- import "./chunk-NTXQLEMQ.js";
12
+ } from "./chunk-LZ2XFUEA.js";
13
+ import "./chunk-6N6FIYOS.js";
14
+ import "./chunk-7BLD64A4.js";
15
+ import "./chunk-WE5HZZLE.js";
17
16
  import "./chunk-VK6GV757.js";
18
- import "./chunk-ES5BRAKJ.js";
17
+ import "./chunk-SBYSVZ7J.js";
19
18
  import "./chunk-D5UZW42X.js";
20
19
  export {
21
20
  endInFile,
@@ -3,21 +3,20 @@ import {
3
3
  DRIVER_NAME,
4
4
  pinExistingRunner,
5
5
  runConnect
6
- } from "./chunk-J4YN6KXM.js";
6
+ } from "./chunk-FIBH3C5S.js";
7
7
  import "./chunk-52CUSFDQ.js";
8
- import "./chunk-3YJD6J2N.js";
8
+ import "./chunk-7BLD64A4.js";
9
9
  import {
10
10
  isLocal,
11
11
  readRunnerConfig
12
- } from "./chunk-EOWS3JIY.js";
13
- import "./chunk-NTXQLEMQ.js";
12
+ } from "./chunk-WE5HZZLE.js";
14
13
  import "./chunk-VK6GV757.js";
15
14
  import "./chunk-365HFCQQ.js";
16
15
  import "./chunk-PKIEWBR7.js";
17
- import "./chunk-OTZDNYX4.js";
18
- import "./chunk-IYZLO64O.js";
19
- import "./chunk-ES5BRAKJ.js";
20
- import "./chunk-JQGHB2EJ.js";
16
+ import "./chunk-5BJGP7FY.js";
17
+ import "./chunk-FAHTEHXP.js";
18
+ import "./chunk-SBYSVZ7J.js";
19
+ import "./chunk-FNHXCSH2.js";
21
20
  import "./chunk-D5UZW42X.js";
22
21
 
23
22
  // src/commands/use.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cloop/runner",
3
- "version": "0.3.30",
3
+ "version": "0.3.33",
4
4
  "private": false,
5
5
  "license": "MIT",
6
6
  "description": "Make your computer and your agents Cloop machines: device login, the machine daemon, the Cloop MCP server, and Claude Code hooks.",