@kodycodes/cli 3.28.0 → 3.28.2

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 (46) hide show
  1. package/dist/{auth-W7H6R6G5.js → auth-4MJQCPHH.js} +3 -3
  2. package/dist/bin.js +4 -4
  3. package/dist/{chunk-QFDBRFG5.js → chunk-6UYRLITC.js} +2 -2
  4. package/dist/{chunk-QXP526E7.js → chunk-6YL6C3LL.js} +844 -44
  5. package/dist/chunk-6YL6C3LL.js.map +6 -0
  6. package/dist/{chunk-V35GMVDB.js → chunk-AAPTGBH2.js} +2 -2
  7. package/dist/{chunk-HJMRMBFW.js → chunk-AK7QC5Q6.js} +1 -7
  8. package/dist/chunk-AK7QC5Q6.js.map +6 -0
  9. package/dist/{chunk-NHX6KT7Q.js → chunk-AUY7E5W4.js} +2 -2
  10. package/dist/{chunk-MO2QBCJE.js → chunk-C56EW2UR.js} +130 -36
  11. package/dist/chunk-C56EW2UR.js.map +6 -0
  12. package/dist/{chunk-STHICAUI.js → chunk-ZVKF65ZW.js} +2 -2
  13. package/dist/cli.d.ts +1 -0
  14. package/dist/cli.js +6 -4
  15. package/dist/command-help.d.ts +10 -0
  16. package/dist/{commands-XRZICB4E.js → commands-KJ2LKZPN.js} +2 -57
  17. package/dist/{commands-XRZICB4E.js.map → commands-KJ2LKZPN.js.map} +1 -1
  18. package/dist/{dev-command-7UJGTUZL.js → dev-command-AD3RRODH.js} +4 -4
  19. package/dist/{git-credential-JJBJSSFJ.js → git-credential-AYJBXNYA.js} +4 -4
  20. package/dist/{local-package-run-G7LQHXMJ.js → local-package-run-PUB3K7FH.js} +3 -3
  21. package/dist/mock/mock-server.d.ts +2 -1
  22. package/dist/mock/mock-storage.d.ts +21 -1
  23. package/dist/{mock-dep-resolve-WD4PG7JB.js → mock-dep-resolve-YLYKZ64B.js} +2 -2
  24. package/dist/{mock-server-AVHUTXAL.js → mock-server-TDKUEG5W.js} +2 -2
  25. package/dist/{open-api-client-TAWXGPDD.js → open-api-client-5BVEGHDF.js} +2 -2
  26. package/dist/{remote-execute-HQRDC57G.js → remote-execute-NXD5ASKQ.js} +2 -2
  27. package/dist/{setup-git-L6KMU43V.js → setup-git-DHJHWR2L.js} +3 -3
  28. package/dist/{whoami-J5V52HIV.js → whoami-JXSVR7Y5.js} +3 -3
  29. package/package.json +1 -1
  30. package/dist/chunk-HJMRMBFW.js.map +0 -6
  31. package/dist/chunk-MO2QBCJE.js.map +0 -6
  32. package/dist/chunk-QXP526E7.js.map +0 -6
  33. /package/dist/{auth-W7H6R6G5.js.map → auth-4MJQCPHH.js.map} +0 -0
  34. /package/dist/{chunk-QFDBRFG5.js.map → chunk-6UYRLITC.js.map} +0 -0
  35. /package/dist/{chunk-V35GMVDB.js.map → chunk-AAPTGBH2.js.map} +0 -0
  36. /package/dist/{chunk-NHX6KT7Q.js.map → chunk-AUY7E5W4.js.map} +0 -0
  37. /package/dist/{chunk-STHICAUI.js.map → chunk-ZVKF65ZW.js.map} +0 -0
  38. /package/dist/{dev-command-7UJGTUZL.js.map → dev-command-AD3RRODH.js.map} +0 -0
  39. /package/dist/{git-credential-JJBJSSFJ.js.map → git-credential-AYJBXNYA.js.map} +0 -0
  40. /package/dist/{local-package-run-G7LQHXMJ.js.map → local-package-run-PUB3K7FH.js.map} +0 -0
  41. /package/dist/{mock-dep-resolve-WD4PG7JB.js.map → mock-dep-resolve-YLYKZ64B.js.map} +0 -0
  42. /package/dist/{mock-server-AVHUTXAL.js.map → mock-server-TDKUEG5W.js.map} +0 -0
  43. /package/dist/{open-api-client-TAWXGPDD.js.map → open-api-client-5BVEGHDF.js.map} +0 -0
  44. /package/dist/{remote-execute-HQRDC57G.js.map → remote-execute-NXD5ASKQ.js.map} +0 -0
  45. /package/dist/{setup-git-L6KMU43V.js.map → setup-git-DHJHWR2L.js.map} +0 -0
  46. /package/dist/{whoami-J5V52HIV.js.map → whoami-JXSVR7Y5.js.map} +0 -0
package/dist/cli.js CHANGED
@@ -3,6 +3,7 @@ import {
3
3
  apiUrlFrom,
4
4
  argvIncludesJsonFlag,
5
5
  buildExecuteToolArgs,
6
+ cliFlagNames,
6
7
  executeSourcesConflict,
7
8
  formatCliErrorJson,
8
9
  packagePublishParams,
@@ -14,11 +15,11 @@ import {
14
15
  resolvePackagePublishTarget,
15
16
  runCli,
16
17
  storedApiTokenAfterLoginNotice
17
- } from "./chunk-QXP526E7.js";
18
+ } from "./chunk-6YL6C3LL.js";
18
19
  import "./chunk-E4R3Y6MM.js";
19
20
  import {
20
21
  resolveLocalExecuteBearer
21
- } from "./chunk-V35GMVDB.js";
22
+ } from "./chunk-AAPTGBH2.js";
22
23
  import "./chunk-46IJPEID.js";
23
24
  import "./chunk-NKQRWYSY.js";
24
25
  import "./chunk-MIT3TUWB.js";
@@ -33,11 +34,11 @@ import {
33
34
  parseCliScopesFlag,
34
35
  redeemBootstrapCode,
35
36
  resolveCliTokenLifetime
36
- } from "./chunk-STHICAUI.js";
37
+ } from "./chunk-ZVKF65ZW.js";
37
38
  import "./chunk-6ZYUGXVW.js";
38
39
  import "./chunk-CWWHR4FH.js";
39
40
  import "./chunk-CASGRYOF.js";
40
- import "./chunk-HJMRMBFW.js";
41
+ import "./chunk-AK7QC5Q6.js";
41
42
  import "./chunk-TTZ6FYMT.js";
42
43
  import {
43
44
  readApiToken,
@@ -58,6 +59,7 @@ export {
58
59
  authBootstrapWithScopes,
59
60
  bootstrapRedeemRequestBody,
60
61
  buildExecuteToolArgs,
62
+ cliFlagNames,
61
63
  cliTokenLifetimeAliases,
62
64
  cliTokenLifetimeMissingError,
63
65
  cliTokenLifetimePolicy,
@@ -0,0 +1,10 @@
1
+ export type CommandHelpNode = {
2
+ name: string;
3
+ summary: string;
4
+ usage: Array<string>;
5
+ flags?: Array<[flag: string, description: string]>;
6
+ notes?: Array<string>;
7
+ subcommands?: Array<CommandHelpNode>;
8
+ };
9
+ export declare const commandHelpTree: Array<CommandHelpNode>;
10
+ export declare function buildCommandHelp(path: Array<string>): string | null;
@@ -4832,61 +4832,6 @@ Run \`kody daemon\` in a terminal, or fix that and run: kody daemon install --co
4832
4832
  );
4833
4833
  return 0;
4834
4834
  }
4835
- if (input.command === "context" && sub === "acknowledge") {
4836
- const ref = rest[0];
4837
- if (!ref) throw new Error("Usage: kody context acknowledge <name|ec id>");
4838
- const token = await input.token();
4839
- const id = encodeURIComponent(ref);
4840
- const read = await apiJson({
4841
- ...base,
4842
- token,
4843
- method: "GET",
4844
- path: `/v1/execution-contexts/${id}`
4845
- });
4846
- const context = read.context ?? {};
4847
- const ack = context.acknowledgment;
4848
- const name = context.name ?? ref;
4849
- if (!ack?.required || !ack.fingerprint) {
4850
- out(
4851
- input,
4852
- { acknowledged: true, alreadyCurrent: true },
4853
- `Nothing to acknowledge on ${name}: you operate it, are its login, or already acknowledged what it runs as.`
4854
- );
4855
- return 0;
4856
- }
4857
- const login = ack.login;
4858
- const who = login?.handle ? `@${login.handle}` : "its owner";
4859
- const runsAs = login?.kind === "profile" ? `the agent profile ${login.profileName ? `"${login.profileName}" ` : ""}of ${who}` : `the account ${who}`;
4860
- const lines = [
4861
- `${name} runs as ${runsAs}, on a machine operated by @${context.operator?.handle ?? "unknown"}.`,
4862
- "Your runs use only your own Kody access, never the machine login's. Anyone with host access on the machine acts with its login.",
4863
- ack.excessCount ? `Its login can do ${ack.excessCount} thing${ack.excessCount === 1 ? "" : "s"} you can't:` : "Its login has no access you lack.",
4864
- ...(ack.entries ?? []).map(
4865
- (entry) => ` - ${entry.permission === "owner" ? "everything (an org Owner)" : entry.resource ? `${entry.permission} on ${entry.resource}` : entry.permission}`
4866
- )
4867
- ];
4868
- const confirm = input.service?.confirm ?? terminalConfirm();
4869
- if (!confirm) {
4870
- throw new Error(
4871
- `Acknowledging needs you at a terminal: run \`kody context acknowledge ${ref}\` yourself, or choose Acknowledge on ${name}'s page in Kody.`
4872
- );
4873
- }
4874
- input.write(`${lines.join("\n")}
4875
- `);
4876
- if (!await confirm(`Acknowledge what ${name} runs as?`, false)) {
4877
- input.write("Not acknowledged; runs on it stay refused.\n");
4878
- return 1;
4879
- }
4880
- const body = await apiJson({
4881
- ...base,
4882
- token,
4883
- method: "POST",
4884
- path: `/v1/execution-contexts/${id}/acknowledge`,
4885
- body: { fingerprint: ack.fingerprint }
4886
- });
4887
- out(input, body, `Acknowledged ${name}. Your runs can use it now.`);
4888
- return 0;
4889
- }
4890
4835
  if (input.command === "context" && sub === "cancel-run") {
4891
4836
  const [ref, runId] = rest;
4892
4837
  if (!ref || !runId) {
@@ -5291,7 +5236,7 @@ Run \`kody daemon\` in a terminal, or fix that and run: kody daemon install --co
5291
5236
  return stayStoppedExitCode;
5292
5237
  }
5293
5238
  throw new Error(
5294
- "Usage: kody context register --name <name> [--org <slug>] | kody context list | kody context revoke <name> | kody context delete <name> | kody context acknowledge <name> | kody context cancel-run <name> <run id> | kody context policy [show | allow <path> [--mode ro|rw] | remove <path>] | kody context commands [status | on | off] [--context <name>] | kody chain show | add <name> | remove <name> | kody connect --name <name> | kody daemon [--context <ec id>] [--max-concurrent <n>] | kody daemon install | status | logs | restart | start | stop | uninstall | auto-update [on | off | status] | kody update"
5239
+ "Usage: kody context register --name <name> [--org <slug>] | kody context list | kody context revoke <name> | kody context delete <name> | kody context cancel-run <name> <run id> | kody context policy [show | allow <path> [--mode ro|rw] | remove <path>] | kody context commands [status | on | off] [--context <name>] | kody chain show | add <name> | remove <name> | kody connect --name <name> | kody daemon [--context <ec id>] [--max-concurrent <n>] | kody daemon install | status | logs | restart | start | stop | uninstall | auto-update [on | off | status] | kody update"
5295
5240
  );
5296
5241
  }
5297
5242
  async function resolveContextId(input) {
@@ -5468,4 +5413,4 @@ export {
5468
5413
  maxConcurrentRuns,
5469
5414
  runExecutionContextCommand
5470
5415
  };
5471
- //# sourceMappingURL=commands-XRZICB4E.js.map
5416
+ //# sourceMappingURL=commands-KJ2LKZPN.js.map