@dreamlake/dreamlake-cli 0.111.1 → 0.112.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.
Files changed (129) hide show
  1. package/dist/api/skills.js +1 -1
  2. package/dist/cli/agents/index.js +20 -20
  3. package/dist/cli/agents/manage.js +1 -1
  4. package/dist/cli/artifact/index.js +5 -5
  5. package/dist/cli/artifact/meta.js +1 -1
  6. package/dist/cli/auth/commands.d.ts +2 -2
  7. package/dist/cli/auth/commands.js +9 -9
  8. package/dist/cli/auth/device-flow.js +2 -2
  9. package/dist/cli/auth/materialized.d.ts +1 -1
  10. package/dist/cli/auth/materialized.js +1 -1
  11. package/dist/cli/compat/http.js +2 -2
  12. package/dist/cli/compat/presignedTransfer.js +2 -2
  13. package/dist/cli/config.js +2 -2
  14. package/dist/cli/connection/index.js +8 -8
  15. package/dist/cli/connection/oauth.js +3 -3
  16. package/dist/cli/connection/write.js +6 -6
  17. package/dist/cli/create/index.js +2 -2
  18. package/dist/cli/declare/index.js +14 -14
  19. package/dist/cli/delete/index.js +4 -4
  20. package/dist/cli/download/index.js +3 -3
  21. package/dist/cli/env/compose.js +1 -1
  22. package/dist/cli/env/index.js +9 -9
  23. package/dist/cli/experiments/index.js +2 -2
  24. package/dist/cli/experiments/native-commands.js +1 -1
  25. package/dist/cli/experiments/native-run-data.js +1 -1
  26. package/dist/cli/graphql.js +1 -1
  27. package/dist/cli/help-examples.generated.js +253 -253
  28. package/dist/cli/hosts/bootstrap-source.d.ts +1 -1
  29. package/dist/cli/hosts/bootstrap-source.js +1 -1
  30. package/dist/cli/hosts/inventory.js +2 -2
  31. package/dist/cli/hosts/picker.js +2 -2
  32. package/dist/cli/hosts/ssh.js +1 -1
  33. package/dist/cli/hosts/upgrade.d.ts +2 -2
  34. package/dist/cli/hosts/upgrade.js +3 -3
  35. package/dist/cli/index.js +7 -3
  36. package/dist/cli/lakeshore/connections.js +1 -1
  37. package/dist/cli/lakeshore/index.d.ts +1 -1
  38. package/dist/cli/lakeshore/index.js +4 -4
  39. package/dist/cli/launch/index.js +10 -10
  40. package/dist/cli/library/add.js +4 -4
  41. package/dist/cli/library/cache.js +1 -1
  42. package/dist/cli/library/discover.js +1 -1
  43. package/dist/cli/library/freshness.js +1 -1
  44. package/dist/cli/library/index.js +1 -1
  45. package/dist/cli/library/info.js +1 -1
  46. package/dist/cli/library/manifest.js +1 -1
  47. package/dist/cli/library/pull.js +1 -1
  48. package/dist/cli/library/push.js +2 -2
  49. package/dist/cli/library/rm.js +2 -2
  50. package/dist/cli/library/search.js +2 -2
  51. package/dist/cli/library/stat.js +1 -1
  52. package/dist/cli/library/tools.js +1 -1
  53. package/dist/cli/library/wire.js +1 -1
  54. package/dist/cli/list/index.js +4 -4
  55. package/dist/cli/memos/document.d.ts +1 -1
  56. package/dist/cli/memos/document.js +1 -1
  57. package/dist/cli/memos/edit-commands.d.ts +2 -2
  58. package/dist/cli/memos/edit-commands.js +2 -2
  59. package/dist/cli/memos/files-commands.d.ts +1 -1
  60. package/dist/cli/memos/files-commands.js +2 -2
  61. package/dist/cli/memos/index.js +7 -7
  62. package/dist/cli/memos/media-commands.js +1 -1
  63. package/dist/cli/memos/move-command.js +2 -2
  64. package/dist/cli/memos/rm-command.d.ts +1 -1
  65. package/dist/cli/memos/rm-command.js +2 -2
  66. package/dist/cli/namespace.js +2 -2
  67. package/dist/cli/nymph/index.js +4 -4
  68. package/dist/cli/ownership/index.js +1 -1
  69. package/dist/cli/ownership/metadata-transfer.js +2 -2
  70. package/dist/cli/page/index.js +5 -5
  71. package/dist/cli/pipeline/index.js +5 -5
  72. package/dist/cli/project/attachments.js +1 -1
  73. package/dist/cli/project/grants.js +1 -1
  74. package/dist/cli/project/index.js +1 -1
  75. package/dist/cli/project/move.js +3 -3
  76. package/dist/cli/project/stream.js +2 -2
  77. package/dist/cli/provider/dreamdir.js +2 -2
  78. package/dist/cli/provider/index.js +18 -18
  79. package/dist/cli/provider/lifecycle.js +14 -14
  80. package/dist/cli/python.js +4 -4
  81. package/dist/cli/queues/index.js +4 -4
  82. package/dist/cli/queues/slurm.js +2 -2
  83. package/dist/cli/resources.js +2 -2
  84. package/dist/cli/run/index.js +1 -1
  85. package/dist/cli/runconfig/index.js +3 -3
  86. package/dist/cli/runnable/bound.js +3 -3
  87. package/dist/cli/runnable/index.js +14 -14
  88. package/dist/cli/runnable/path.d.ts +1 -1
  89. package/dist/cli/runnable/path.js +1 -1
  90. package/dist/cli/self-update/alias-migration.d.ts +11 -0
  91. package/dist/cli/self-update/alias-migration.js +56 -0
  92. package/dist/cli/self-update/index.d.ts +1 -1
  93. package/dist/cli/self-update/index.js +5 -5
  94. package/dist/cli/self-update/install.js +2 -2
  95. package/dist/cli/self-update/update.d.ts +1 -1
  96. package/dist/cli/self-update/update.js +7 -7
  97. package/dist/cli/session-affiliation.js +1 -1
  98. package/dist/cli/sessions/control.d.ts +1 -1
  99. package/dist/cli/sessions/control.js +2 -2
  100. package/dist/cli/sessions/index.js +5 -5
  101. package/dist/cli/sessions/live.js +1 -1
  102. package/dist/cli/sessions/runner/serve.js +1 -1
  103. package/dist/cli/sessions/wrap.d.ts +2 -2
  104. package/dist/cli/sessions/wrap.js +8 -8
  105. package/dist/cli/skill/index.js +22 -22
  106. package/dist/cli/skill/prefs.js +1 -1
  107. package/dist/cli/skill/read.js +3 -3
  108. package/dist/cli/skill/registry.js +2 -2
  109. package/dist/cli/snapshot/index.js +9 -9
  110. package/dist/cli/source/access.js +3 -3
  111. package/dist/cli/source/control.js +8 -8
  112. package/dist/cli/source/delete.js +6 -6
  113. package/dist/cli/source/index.js +14 -14
  114. package/dist/cli/source/share.js +8 -8
  115. package/dist/cli/source/upload.d.ts +1 -1
  116. package/dist/cli/source/upload.js +2 -2
  117. package/dist/cli/source/write.js +2 -2
  118. package/dist/cli/spawn.js +1 -1
  119. package/dist/cli/tasks/index.js +1 -1
  120. package/dist/cli/update/index.js +2 -2
  121. package/dist/cli/upload/index.js +3 -3
  122. package/dist/cli/upload/multipart.js +1 -1
  123. package/dist/cli/vault/index.js +1 -1
  124. package/dist/cli/vault/sshSync.js +1 -1
  125. package/dist/cli/version.d.ts +1 -1
  126. package/dist/cli/version.js +1 -1
  127. package/dist/cli/workflow/index.d.ts +1 -1
  128. package/dist/cli/workflow/index.js +6 -6
  129. package/package.json +10 -10
@@ -1,4 +1,4 @@
1
- // The engine behind `dreamlake provider|storage|queue-def …` — one generic
1
+ // The engine behind `dl provider|storage|queue-def …` — one generic
2
2
  // implementation of the five verbs dreamlake-server exposes for its three
3
3
  // lakeshore resource collections.
4
4
  //
@@ -10,7 +10,7 @@
10
10
  // (LAKESHORE_COLLECTIONS, :59-95). `declare`'s own header comment already ruled
11
11
  // on that shape once — "Five groups would be five copies of one function."
12
12
  //
13
- // But `dreamlake lakeshore lakeshore-providers list` is not a command anybody
13
+ // But `dl lakeshore lakeshore-providers list` is not a command anybody
14
14
  // types, and every other group in this CLI is a noun: runnable, runconfig,
15
15
  // pipeline, dataset, project, source, org, team. So the LOGIC lives here, once,
16
16
  // and `provider/index.ts` spends its lines on help text rather than on copies.
@@ -81,13 +81,13 @@ export const COLLECTIONS = [
81
81
  async function ctx(nsFlag) {
82
82
  const token = resolveToken();
83
83
  if (!token) {
84
- fail("not authenticated — run 'dreamlake login' first");
84
+ fail("not authenticated — run 'dl login' first");
85
85
  return null;
86
86
  }
87
87
  const remote = resolveRemote();
88
88
  const ns = await resolveNamespace(nsFlag, { token, remote });
89
89
  if (!ns) {
90
- fail("could not resolve namespace — run 'dreamlake login' or pass --namespace");
90
+ fail("could not resolve namespace — run 'dl login' or pass --namespace");
91
91
  return null;
92
92
  }
93
93
  return { token, remote, ns };
@@ -1,4 +1,4 @@
1
- // `dreamlake launch <script>` — run a repo script on the fabric. The control
1
+ // `dl launch <script>` — run a repo script on the fabric. The control
2
2
  // plane picks the node; nothing here names a machine, and that is the point.
3
3
  //
4
4
  // The script is put on a QUEUE as an `Invocation`. A worker whose host key
@@ -43,7 +43,7 @@ export function isSnapshotRef(value) {
43
43
  function noQueueMessage(script) {
44
44
  return [
45
45
  "no queue — a launch has to say where it runs. Any one of:",
46
- ` dreamlake launch ${script} --queue cpu`,
46
+ ` dl launch ${script} --queue cpu`,
47
47
  " export LAKESHORE_QUEUE=cpu",
48
48
  " queue: cpu # at the top level of .dreamrc",
49
49
  ].join("\n");
@@ -76,13 +76,13 @@ export function resolveQueue(flag) {
76
76
  function shortCommit(commit) {
77
77
  return commit ? commit.slice(0, 7) : "(unknown)";
78
78
  }
79
- // ─── dreamlake launch ────────────────────────────────────────────────────────
79
+ // ─── dl launch ────────────────────────────────────────────────────────
80
80
  export async function runLaunch(script, opts, deps = {}) {
81
81
  // ── ALL local validation first. Each of these returns 1 having spawned
82
82
  // nothing at all: a missing queue must not cost an upload. ──
83
83
  const namespace = resolveCpNamespace(opts.namespace);
84
84
  if (!script || !script.trim()) {
85
- return reject(opts, "no script given — usage: dreamlake launch <script>", {
85
+ return reject(opts, "no script given — usage: dl launch <script>", {
86
86
  script: script ?? "",
87
87
  server: "",
88
88
  namespace,
@@ -188,7 +188,7 @@ export async function runLaunch(script, opts, deps = {}) {
188
188
  }
189
189
  ok(`launched ${record.invocationId ?? "(no id)"} on queue '${record.queue}'`);
190
190
  if (!didWait) {
191
- process.stdout.write(` dreamlake launch ${script} --queue ${record.queue} # re-run\n`);
191
+ process.stdout.write(` dl launch ${script} --queue ${record.queue} # re-run\n`);
192
192
  return 0;
193
193
  }
194
194
  // The script's own streams, verbatim and unwrapped. Anything this command
@@ -227,7 +227,7 @@ function reject(opts, message, where, kind) {
227
227
  // ─── registration ────────────────────────────────────────────────────────────
228
228
  //
229
229
  // NO `--version` OPTION HERE, EVER — `program.version()` resolves from any
230
- // descendant, so one would make `dreamlake launch --version` print 0.6.0 and
230
+ // descendant, so one would make `dl launch --version` print 0.6.0 and
231
231
  // exit 0 without launching anything.
232
232
  function collect(value, previous) {
233
233
  return [...previous, value];
@@ -259,12 +259,12 @@ export function registerLaunchCommand(program) {
259
259
  "stdout and stderr are printed through verbatim; under --json they are the",
260
260
  "`stdout` / `stderr` fields and the real number is `exitCode`.",
261
261
  "",
262
- "This talks to the control plane only — it needs no `dreamlake login`.",
262
+ "This talks to the control plane only — it needs no `dl login`.",
263
263
  "",
264
264
  "Examples:",
265
- " dreamlake launch train.py --queue cpu",
266
- " dreamlake launch train.py --arg --epochs --arg 10",
267
- " dreamlake launch eval.py --snapshot 665f0a1b2c3d4e5f60718293 --no-wait",
265
+ " dl launch train.py --queue cpu",
266
+ " dl launch train.py --arg --epochs --arg 10",
267
+ " dl launch eval.py --snapshot 665f0a1b2c3d4e5f60718293 --no-wait",
268
268
  ].join("\n"))
269
269
  .action(async (script, opts) => process.exit(await runLaunch(script, opts)));
270
270
  }
@@ -1,4 +1,4 @@
1
- // `dreamlake library add <spec> <path>` — add ONE asset to a remote library
1
+ // `dl library add <spec> <path>` — add ONE asset to a remote library
2
2
  // without holding a full local copy (RFC 0008 §5.7).
3
3
  //
4
4
  // The mechanism is the register contract itself: register serves whatever
@@ -41,7 +41,7 @@ const ADD_CONCURRENCY = 4;
41
41
  export async function fetchRemoteLibrary(base, token, spec) {
42
42
  const detail = await jsonRequest("GET", base, token);
43
43
  if (detail.status === 404) {
44
- return { error: `library ${spec} not found — create it with \`dreamlake library push\`` };
44
+ return { error: `library ${spec} not found — create it with \`dl library push\`` };
45
45
  }
46
46
  if (detail.status !== 200) {
47
47
  return { error: `could not read the library → ${detail.status}: ${errorMessage(detail)}` };
@@ -50,7 +50,7 @@ export async function fetchRemoteLibrary(base, token, spec) {
50
50
  const revision = typeof rev === "number" ? rev : 0;
51
51
  const mRes = await jsonRequest("GET", `${base}/manifest`, token);
52
52
  if (mRes.status === 404) {
53
- return { error: `library ${spec} not found — create it with \`dreamlake library push\`` };
53
+ return { error: `library ${spec} not found — create it with \`dl library push\`` };
54
54
  }
55
55
  if (mRes.status !== 200) {
56
56
  return { error: `could not read the remote manifest → ${mRes.status}: ${errorMessage(mRes)}` };
@@ -298,7 +298,7 @@ export async function runLibraryAdd(args, deps = {}) {
298
298
  if (reg.status < 200 || reg.status >= 300) {
299
299
  fail(`could not register the library → ${reg.status}: ${errorMessage(reg)}`);
300
300
  if (reg.status === 409) {
301
- process.stderr.write(` another writer is racing this add — re-run \`dreamlake library add\`.\n`);
301
+ process.stderr.write(` another writer is racing this add — re-run \`dl library add\`.\n`);
302
302
  }
303
303
  return 1;
304
304
  }
@@ -1,4 +1,4 @@
1
- // Push-time caches for `dreamlake library` — both DISPOSABLE, both under
1
+ // Push-time caches for `dl library` — both DISPOSABLE, both under
2
2
  // `~/.dreamlake/cache/libraries/`:
3
3
  //
4
4
  // hashes.json absPath → {mtimeMs, size, sha256}, so an
@@ -1,4 +1,4 @@
1
- // Asset discovery for `dreamlake library push` — the half of the authoring
1
+ // Asset discovery for `dl library push` — the half of the authoring
2
2
  // model that turns a plain directory into a list of assets, before any hash
3
3
  // or network I/O.
4
4
  //
@@ -1,4 +1,4 @@
1
- // Freshness primitives for `dreamlake library` — the consumer-side twin of
1
+ // Freshness primitives for `dl library` — the consumer-side twin of
2
2
  // the push diff (RFC 0008 §5.5).
3
3
  //
4
4
  // `diffAgainstManifest` answers "is my local copy current?" with the REMOTE
@@ -1,4 +1,4 @@
1
- // `dreamlake library push|pull|list|search` — Asset Libraries.
1
+ // `dl library push|pull|list|search` — Asset Libraries.
2
2
  //
3
3
  // A library is a PLAIN local directory: the user's asset files plus one
4
4
  // optional `dreamlake.yml` (metadata, discovery globs). Push discovers the
@@ -1,4 +1,4 @@
1
- // `dreamlake library info <spec>` — one library's statistical portrait, or
1
+ // `dl library info <spec>` — one library's statistical portrait, or
2
2
  // (with --asset) one asset's full decision card.
3
3
  //
4
4
  // RFC 0008's `summary` and `peek` verbs, computed CLIENT-side from exactly
@@ -1,4 +1,4 @@
1
- // Wire-manifest handling for `dreamlake library` — the dreamlake.assets/v1
1
+ // Wire-manifest handling for `dl library` — the dreamlake.assets/v1
2
2
  // document the CLI GENERATES at push (into the cache dir, uploaded to
3
3
  // `files/.dreamlake/manifest.json`) and reads back from the server for
4
4
  // diffing and pulling. Users never author this file: their input is the
@@ -1,4 +1,4 @@
1
- // `dreamlake library pull <ns>/<name>` — materialize a library (or one asset)
1
+ // `dl library pull <ns>/<name>` — materialize a library (or one asset)
2
2
  // from its remote manifest.
3
3
  //
4
4
  // By DEFAULT a pull materializes the USER's files only — the clean source
@@ -1,4 +1,4 @@
1
- // `dreamlake library push <dir>` — publish an Asset Library from a PLAIN
1
+ // `dl library push <dir>` — publish an Asset Library from a PLAIN
2
2
  // source directory.
3
3
  //
4
4
  // The authoring model: the user's input is their files plus one optional
@@ -579,7 +579,7 @@ export async function runLibraryPush(args, deps = {}) {
579
579
  if (reg.status < 200 || reg.status >= 300) {
580
580
  fail(`uploaded ${uploads.length} file(s) but could not register the library → ${reg.status}: ${errorMessage(reg)}`);
581
581
  if (reg.status === 409) {
582
- process.stderr.write(` another push is racing this one — re-run \`dreamlake library push\`.\n`);
582
+ process.stderr.write(` another push is racing this one — re-run \`dl library push\`.\n`);
583
583
  }
584
584
  return 1;
585
585
  }
@@ -1,4 +1,4 @@
1
- // `dreamlake library rm <spec> <assetId...>` — remove assets from a remote
1
+ // `dl library rm <spec> <assetId...>` — remove assets from a remote
2
2
  // library without holding a full local copy (RFC 0008 §5.7).
3
3
  //
4
4
  // No payload bytes move: the edit is the manifest itself. Read the remote
@@ -160,7 +160,7 @@ export async function runLibraryRm(args, deps = {}) {
160
160
  if (reg.status < 200 || reg.status >= 300) {
161
161
  fail(`could not register the library → ${reg.status}: ${errorMessage(reg)}`);
162
162
  if (reg.status === 409) {
163
- process.stderr.write(` another writer is racing this rm — re-run \`dreamlake library rm\`.\n`);
163
+ process.stderr.write(` another writer is racing this rm — re-run \`dl library rm\`.\n`);
164
164
  }
165
165
  return 1;
166
166
  }
@@ -1,4 +1,4 @@
1
- // `dreamlake library search <query>` — search assets across libraries.
1
+ // `dl library search <query>` — search assets across libraries.
2
2
  //
3
3
  // GET /library-search over an explicit `--library ns/a,ns/b` scope, or —
4
4
  // when no scope is given — the caller's visible libraries from GET
@@ -159,7 +159,7 @@ export async function runLibrarySearch(args) {
159
159
  warn(`skipped ${str(s.library)}: ${str(s.reason)}`);
160
160
  }
161
161
  if (hits.length > 0) {
162
- process.stdout.write("download: dreamlake library pull <ns>/<lib> --asset <id>\n");
162
+ process.stdout.write("download: dl library pull <ns>/<lib> --asset <id>\n");
163
163
  }
164
164
  return 0;
165
165
  }
@@ -1,4 +1,4 @@
1
- // `dreamlake library stat <ns>/<name>` — is my local copy current?
1
+ // `dl library stat <ns>/<name>` — is my local copy current?
2
2
  //
3
3
  // The consumer-side freshness verb (RFC 0008 §5.5): GET the catalog row (for
4
4
  // `revision`) and the manifest, hash the local directory through the shared
@@ -1,4 +1,4 @@
1
- // Push-time generators for `dreamlake library push --thumbnails/--embed` —
1
+ // Push-time generators for `dl library push --thumbnails/--embed` —
2
2
  // thin shells around the Python reference tools in dreamlake-py, located and
3
3
  // invoked EXACTLY the way `env compose` finds its engine (env/compose.ts):
4
4
  // DREAMLAKE_PYTHON wins outright, otherwise python3 then python; the module
@@ -1,4 +1,4 @@
1
- // Wire-manifest construction for `dreamlake library push` — discovered
1
+ // Wire-manifest construction for `dl library push` — discovered
2
2
  // assets + hashes + generated artifacts → the dreamlake.assets/v1 document
3
3
  // that uploads to `files/.dreamlake/manifest.json`.
4
4
  //
@@ -19,12 +19,12 @@ export async function runListAssets(opts) {
19
19
  const remote = resolveRemote();
20
20
  const token = resolveToken();
21
21
  if (!token) {
22
- fail("not authenticated. run 'dreamlake login' first");
22
+ fail("not authenticated. run 'dl login' first");
23
23
  return 1;
24
24
  }
25
25
  const namespace = await resolveNamespace(t.namespace, { token, remote });
26
26
  if (!namespace) {
27
- fail("namespace not specified and no authenticated user found. run 'dreamlake login'");
27
+ fail("namespace not specified and no authenticated user found. run 'dl login'");
28
28
  return 1;
29
29
  }
30
30
  t.namespace = namespace;
@@ -87,12 +87,12 @@ export async function runListProjects(opts) {
87
87
  const remote = resolveRemote();
88
88
  const token = resolveToken();
89
89
  if (!token) {
90
- fail("not authenticated. run 'dreamlake login' first");
90
+ fail("not authenticated. run 'dl login' first");
91
91
  return 1;
92
92
  }
93
93
  const namespace = await resolveNamespace(opts.namespace, { token, remote });
94
94
  if (!namespace) {
95
- fail("namespace not specified and no authenticated user found. run 'dreamlake login'");
95
+ fail("namespace not specified and no authenticated user found. run 'dl login'");
96
96
  return 1;
97
97
  }
98
98
  const projects = await fetchProjects(remote, token, namespace);
@@ -65,7 +65,7 @@ export declare function submitDocumentPatch(c: DocumentContext, id: string, payl
65
65
  ifMatch?: string;
66
66
  }): Promise<MemoWriteReceipt>;
67
67
  export declare function printPatchReceipt(result: MemoWriteReceipt, json?: boolean): void;
68
- /** `dreamlake notes command-status NOTE COMMAND_ID`: the durable record behind one --command-id. */
68
+ /** `dl notes command-status NOTE COMMAND_ID`: the durable record behind one --command-id. */
69
69
  export declare function runMemosCommandStatus(ref: string, commandId: string, opts: ConnOpts & {
70
70
  json?: boolean;
71
71
  }): Promise<number>;
@@ -83,7 +83,7 @@ export function printPatchReceipt(result, json) {
83
83
  else
84
84
  process.stdout.write(`${printTokens(result)}mode: ${result.mode}\nbaseRevision: ${result.baseRevision}\n${result.commandId === null ? "" : `outcome: ${result.outcome}\ncommandId: ${result.commandId}\nreplayed: ${result.replayed}\n`}`);
85
85
  }
86
- /** `dreamlake notes command-status NOTE COMMAND_ID`: the durable record behind one --command-id. */
86
+ /** `dl notes command-status NOTE COMMAND_ID`: the durable record behind one --command-id. */
87
87
  export async function runMemosCommandStatus(ref, commandId, opts) {
88
88
  if (!COMMAND_ID_PATTERN.test(commandId)) {
89
89
  fail("command id must be 8–128 characters of A-Z a-z 0-9 . _ : -");
@@ -1,5 +1,5 @@
1
1
  /**
2
- * `dreamlake notes find | select | replace | insert | delete | toc`
2
+ * `dl notes find | select | replace | insert | delete | toc`
3
3
  *
4
4
  * The shape follows the CLI's existing convention rather than the SDK's: the
5
5
  * thing you are looking FOR is the first positional argument, and the thing
@@ -109,7 +109,7 @@ type InsertOpts = MutateOpts & {
109
109
  };
110
110
  /** `notes insert [NOTE] --before|--after ADDRESS | --cursor N | --line N | --ind N | --selector CSS`; the note may be positional (IDs are primary). */
111
111
  export declare function runMemosInsert(noteOrOpts: string | undefined | InsertOpts, maybeOpts?: InsertOpts): Promise<number>;
112
- /** `dreamlake notes select "#contact" --note NOTE` */
112
+ /** `dl notes select "#contact" --note NOTE` */
113
113
  export declare function runMemosSelect(css: string, opts: ConnOpts & {
114
114
  note?: string;
115
115
  json?: boolean;
@@ -1,5 +1,5 @@
1
1
  /**
2
- * `dreamlake notes find | select | replace | insert | delete | toc`
2
+ * `dl notes find | select | replace | insert | delete | toc`
3
3
  *
4
4
  * The shape follows the CLI's existing convention rather than the SDK's: the
5
5
  * thing you are looking FOR is the first positional argument, and the thing
@@ -629,7 +629,7 @@ async function runLegacyNotesDelete(query, opts) {
629
629
  ? replaceInElement(src, opts.selector, "", whereFrom(query, opts))
630
630
  : remove(src, whereFrom(query, opts)));
631
631
  }
632
- /** `dreamlake notes select "#contact" --note NOTE` */
632
+ /** `dl notes select "#contact" --note NOTE` */
633
633
  export async function runMemosSelect(css, opts) {
634
634
  const ref = requireNote(opts);
635
635
  if (!ref)
@@ -78,7 +78,7 @@ export declare function resolveFile(c: Conn, noteId: string, ref: string, opts?:
78
78
  includeTrashed?: boolean;
79
79
  }): Promise<FileRow | null>;
80
80
  /**
81
- * `dreamlake notes files preview <file> --note N [--share] [--open]`
81
+ * `dl notes files preview <file> --note N [--share] [--open]`
82
82
  *
83
83
  * Prints a link that renders the file. The default needs the reader signed in
84
84
  * and grants nothing by itself; `--share` returns one that works without
@@ -1,7 +1,7 @@
1
1
  import { memoFilesApi, memoFileOperationId, validateMemoFileKey } from '../../api/memo-files.js';
2
2
  import { memoTransport } from './api-transport.js';
3
3
  /**
4
- * `dreamlake notes files …` — list, upload, download, move, copy, trash.
4
+ * `dl notes files …` — list, upload, download, move, copy, trash.
5
5
  *
6
6
  * Bytes are never decoded on this path. Upload reads the local file as a
7
7
  * Buffer and sends it raw; download writes the response body straight out.
@@ -500,7 +500,7 @@ export async function resolveFile(c, noteId, ref, opts = {}) {
500
500
  }
501
501
  }
502
502
  /**
503
- * `dreamlake notes files preview <file> --note N [--share] [--open]`
503
+ * `dl notes files preview <file> --note N [--share] [--open]`
504
504
  *
505
505
  * Prints a link that renders the file. The default needs the reader signed in
506
506
  * and grants nothing by itself; `--share` returns one that works without
@@ -44,7 +44,7 @@ const EXIT_PATCH = 5;
44
44
  export async function ctx(opts = {}) {
45
45
  const c = resolveCtx(opts);
46
46
  if (!c.token) {
47
- fail("not authenticated — run 'dreamlake login' first");
47
+ fail("not authenticated — run 'dl login' first");
48
48
  return null;
49
49
  }
50
50
  const ns = await requireNamespace(c, opts.namespace);
@@ -83,7 +83,7 @@ export function report(err) {
83
83
  return EXIT_PATCH;
84
84
  }
85
85
  if (err.status === 401) {
86
- fail("not authenticated — run 'dreamlake login' first");
86
+ fail("not authenticated — run 'dl login' first");
87
87
  return 1;
88
88
  }
89
89
  if (err.status === 403) {
@@ -121,7 +121,7 @@ export async function resolveNote(c, ref) {
121
121
  if (!res.notes.length || (res.total === undefined ? res.notes.length < 200 : offset >= res.total))
122
122
  break;
123
123
  }
124
- fail(`no memo '${ref}' in namespace '${c.ns}' — 'dreamlake memos list --include-archived' shows what is there, ` +
124
+ fail(`no memo '${ref}' in namespace '${c.ns}' — 'dl memos list --include-archived' shows what is there, ` +
125
125
  `and an organization's memos need --namespace <slug>`);
126
126
  return null;
127
127
  }
@@ -685,7 +685,7 @@ export async function runMemosList(opts) {
685
685
  process.stdout.write(opts.shared
686
686
  ? "no memos shared with you\n"
687
687
  : `no memos in '${c.ns}'\n an organization's memos are in its own namespace — ` +
688
- `'dreamlake org list' shows yours, then --namespace <slug>\n`);
688
+ `'dl org list' shows yours, then --namespace <slug>\n`);
689
689
  return 0;
690
690
  }
691
691
  process.stdout.write(opts.shared
@@ -720,7 +720,7 @@ export async function runMemosSearch(query, opts) {
720
720
  // "not in these notes", and the reader should be able to tell that the
721
721
  // search was scoped somewhere they may not have meant.
722
722
  process.stdout.write(`no memo in '${c.ns}' has '${query}' in its title or body\n` +
723
- ` other namespaces are searched separately — 'dreamlake org list', then --namespace <slug>\n`);
723
+ ` other namespaces are searched separately — 'dl org list', then --namespace <slug>\n`);
724
724
  return 0;
725
725
  }
726
726
  process.stdout.write(renderTable(res.notes.map((n) => ({
@@ -908,7 +908,7 @@ export async function runMemosWrite(ref, opts) {
908
908
  if (!c)
909
909
  return 1;
910
910
  if (looksLikeDiff(text))
911
- process.stderr.write("⚠ this looks like a unified diff — 'dreamlake memos patch' applies one; 'write' stores it as the body\n");
911
+ process.stderr.write("⚠ this looks like a unified diff — 'dl memos patch' applies one; 'write' stores it as the body\n");
912
912
  try {
913
913
  const id = await resolveNote(c, ref);
914
914
  if (!id)
@@ -955,7 +955,7 @@ async function runLegacyNotesWrite(ref, opts) {
955
955
  //
956
956
  // On stderr, and not through helpers' `warn`, which prints to stdout —
957
957
  // that would land inside `--json` output and break anything parsing it.
958
- process.stderr.write("⚠ this looks like a unified diff — 'dreamlake memos patch' applies one; " +
958
+ process.stderr.write("⚠ this looks like a unified diff — 'dl memos patch' applies one; " +
959
959
  "'write' stores it as the body\n");
960
960
  }
961
961
  try {
@@ -17,7 +17,7 @@ export async function runMediaUpload(local, opts) {
17
17
  }
18
18
  const c = resolveCtx(opts);
19
19
  if (!c.token) {
20
- fail("not authenticated — run 'dreamlake login' first");
20
+ fail("not authenticated — run 'dl login' first");
21
21
  return 1;
22
22
  }
23
23
  try {
@@ -128,7 +128,7 @@ export async function memoProjectNode(remote, token, ns, noteId, project) {
128
128
  n.path.split(",")[1] === project && (n.namespaceSlug == null || n.namespaceSlug === ns));
129
129
  if (!hits.length)
130
130
  throw new Error(`memo ${noteId} is not filed in project '${project}' in @${ns}; ` +
131
- `see \`dreamlake memos projects ${noteId} --namespace ${ns}\``);
131
+ `see \`dl memos projects ${noteId} --namespace ${ns}\``);
132
132
  if (hits.length > 1)
133
133
  throw new Error(`memo ${noteId} has more than one node in project '${project}'; resolve it in the UI`);
134
134
  return hits[0];
@@ -251,7 +251,7 @@ export async function runMemosFolderMove(ref, opts) {
251
251
  }
252
252
  recordOperationFailure(code, attempted && (status === undefined || status >= 500) ? 'uncertain' : 'failed');
253
253
  if (attempted && (status === undefined || status >= 500))
254
- message += `; the outcome may be uncertain: check \`dreamlake list --episode <project>@<namespace>\` before resubmitting; no retry was performed`;
254
+ message += `; the outcome may be uncertain: check \`dl list --episode <project>@<namespace>\` before resubmitting; no retry was performed`;
255
255
  if (opts.json)
256
256
  emitJson({ error: code, message, ...(status === undefined ? {} : { status }) });
257
257
  else
@@ -1,5 +1,5 @@
1
1
  /**
2
- * `dreamlake notes rm <note>` — delete a whole note.
2
+ * `dl notes rm <note>` — delete a whole note.
3
3
  *
4
4
  * Named `rm` because `notes delete` removes text inside a note, following
5
5
  * `notes files rm` and `notes rm-section`.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * `dreamlake notes rm <note>` — delete a whole note.
2
+ * `dl notes rm <note>` — delete a whole note.
3
3
  *
4
4
  * Named `rm` because `notes delete` removes text inside a note, following
5
5
  * `notes files rm` and `notes rm-section`.
@@ -86,7 +86,7 @@ export async function runMemosRm(ref, opts) {
86
86
  }
87
87
  catch { /* keep the transport message */ }
88
88
  if (status === 401)
89
- message = "not authenticated — run 'dreamlake login' first";
89
+ message = "not authenticated — run 'dl login' first";
90
90
  else if (status === 403)
91
91
  message = "only the namespace owner or the memo's creator can delete this memo";
92
92
  else if (status === 404)
@@ -7,13 +7,13 @@ const normalizeRemote = (remote) => remote.replace(/\/+$/, '');
7
7
  export async function selectNamespace(value, options = {}) {
8
8
  const namespace = value.replace(/^@/, '');
9
9
  if (!slug.test(namespace))
10
- throw new Error('Use dreamlake su <namespace> with an exact namespace name');
10
+ throw new Error('Use dl su <namespace> with an exact namespace name');
11
11
  const remote = resolveRemote(undefined, options.dir), token = resolveToken(undefined, options.dir);
12
12
  if (!token)
13
13
  throw new Error('Log in to DreamLake before selecting a namespace');
14
14
  const materialized = () => readToken(options.dir) === token && normalizeRemote(readConfig(options.dir).remote_url ?? '') === remote;
15
15
  if (!materialized())
16
- throw new Error('Select a saved login with dreamlake auth env use before persisting a namespace; explicit connection overrides are not saved');
16
+ throw new Error('Select a saved login with dl auth env use before persisting a namespace; explicit connection overrides are not saved');
17
17
  const request = options.fetch ?? fetch;
18
18
  const get = async (path, json) => {
19
19
  let response;
@@ -196,14 +196,14 @@ export async function afterLogin(deps = {}) {
196
196
  try {
197
197
  const c = (deps.getContext ?? context)();
198
198
  if (readPrivate(locations(c).record)) {
199
- output("Nymph overview: dreamlake nymph\n");
199
+ output("Nymph overview: dl nymph\n");
200
200
  return;
201
201
  }
202
202
  // An existing daemon can have a different name: do not enroll a second one at login.
203
203
  try {
204
204
  const known = deps.instances ? deps.instances() : invoke(["instances", "--json"]);
205
205
  if (JSON.stringify(known).includes('"config_path"') || (Array.isArray(known) && known.length) || known?.instances?.length) {
206
- output("Existing Nymph detected. Review configuration and access with dreamlake nymph.\n");
206
+ output("Existing Nymph detected. Review configuration and access with dl nymph.\n");
207
207
  return;
208
208
  }
209
209
  }
@@ -211,10 +211,10 @@ export async function afterLogin(deps = {}) {
211
211
  if (!await (deps.ask ?? confirm)(ENABLE_PROMPT, false))
212
212
  return;
213
213
  await (deps.enable ?? (c => setup(c, {})))(c);
214
- output("Nymph setup requested. Upload and command execution permissions are managed separately.\nOverview: dreamlake nymph\n");
214
+ output("Nymph setup requested. Upload and command execution permissions are managed separately.\nOverview: dl nymph\n");
215
215
  }
216
216
  catch {
217
- output("Login succeeded. Nymph setup was not confirmed; run dreamlake nymph setup to inspect prerequisites.\n");
217
+ output("Login succeeded. Nymph setup was not confirmed; run dl nymph setup to inspect prerequisites.\n");
218
218
  }
219
219
  }
220
220
  export async function setPermission(c, tool, allow, yes = false) {
@@ -11,7 +11,7 @@ export async function runOwnership(action, argument, opts) {
11
11
  try {
12
12
  const c = resolveCtx(opts);
13
13
  if (!c.token)
14
- throw new Error("Not authenticated — run 'dreamlake login' first");
14
+ throw new Error("Not authenticated — run 'dl login' first");
15
15
  const ns = await requireNamespace(c, opts.namespace);
16
16
  if (!ns)
17
17
  return 1;
@@ -73,7 +73,7 @@ export async function runMetadataTransfer(requestedType, resourceId, opts) {
73
73
  throw new Error('--wait-timeout must be an integer from 0 to 60 seconds');
74
74
  const c = resolveCtx(opts);
75
75
  if (!c.token)
76
- throw new Error("Not authenticated — run 'dreamlake login' first");
76
+ throw new Error("Not authenticated — run 'dl login' first");
77
77
  const get = (path, timeoutMs) => requestJson(c.remote, path, { token: c.token, redirect: 'error', timeoutMs });
78
78
  const post = (path, json) => requestJson(c.remote, path, { token: c.token, method: 'POST', json, redirect: 'error' });
79
79
  const base = `/namespaces/${seg(source)}/ownership`;
@@ -134,7 +134,7 @@ export async function runMetadataTransfer(requestedType, resourceId, opts) {
134
134
  break;
135
135
  await new Promise(resolve => setTimeout(resolve, Math.min(1000, Math.max(0, deadline - performance.now()))));
136
136
  }
137
- const nextAction = `dreamlake ownership ${operation.state === 'pending' ? 'accept' : 'status'} ${operationId} --namespace ${quoted(operation.state === 'pending' ? destination : source)}`;
137
+ const nextAction = `dl ownership ${operation.state === 'pending' ? 'accept' : 'status'} ${operationId} --namespace ${quoted(operation.state === 'pending' ? destination : source)}`;
138
138
  emitProjectResult({ ...review, operation, nextAction, timedOut: !!opts.wait && busy.has(operation.state) }, () => `${adapter.label} transfer ${operationId}: ${operation.state}.\n${nextAction}`, opts.json);
139
139
  return failed.has(operation.state) ? 3 : 0;
140
140
  }
@@ -1,4 +1,4 @@
1
- // `dreamlake page ...` — drive the page agent through dreamlake-server.
1
+ // `dl page ...` — drive the page agent through dreamlake-server.
2
2
  //
3
3
  // Pages are generated review/labeling UIs. Each one runs in its own container
4
4
  // behind a vite dev server, so an edit applies over HMR: there is no build step
@@ -351,10 +351,10 @@ export function registerPageCommand(program) {
351
351
  .description("generate, edit, and inspect hosted pages")
352
352
  .addHelpText("after", `
353
353
  Examples:
354
- $ dreamlake page generate --description "a review page with a video player and a label form"
355
- $ dreamlake page status --workspace-id 24f311c966d2
356
- $ dreamlake page edit --workspace-id 24f311c966d2 --description "make the layout two columns"
357
- $ dreamlake page delete --workspace-id 24f311c966d2
354
+ $ dl page generate --description "a review page with a video player and a label form"
355
+ $ dl page status --workspace-id 24f311c966d2
356
+ $ dl page edit --workspace-id 24f311c966d2 --description "make the layout two columns"
357
+ $ dl page delete --workspace-id 24f311c966d2
358
358
 
359
359
  Generating runs for 60-120 s and editing for 30-100 s. Progress is printed to
360
360
  stderr while the agent works, and generate prints the page URL as soon as it is
@@ -1,5 +1,5 @@
1
1
  import { collectionList } from "../collection-list.js";
2
- // `dreamlake pipeline ...` — pipeline management.
2
+ // `dl pipeline ...` — pipeline management.
3
3
  //
4
4
  // Covers all 10 pipeline API endpoints:
5
5
  // pipeline list / create / show / update / delete
@@ -15,13 +15,13 @@ import { confirm } from "../prompt.js";
15
15
  async function ctx(nsFlag) {
16
16
  const token = resolveToken();
17
17
  if (!token) {
18
- fail("not authenticated — run 'dreamlake login' first");
18
+ fail("not authenticated — run 'dl login' first");
19
19
  return null;
20
20
  }
21
21
  const remote = resolveRemote();
22
22
  const ns = await resolveNamespace(nsFlag, { token, remote });
23
23
  if (!ns) {
24
- fail("could not resolve namespace — run 'dreamlake login' or pass --namespace");
24
+ fail("could not resolve namespace — run 'dl login' or pass --namespace");
25
25
  return null;
26
26
  }
27
27
  return { token, remote, ns };
@@ -380,7 +380,7 @@ export async function runNodeState(name, hash, nodeId, opts) {
380
380
  export async function runWorkspaceUpload(opts) {
381
381
  const token = resolveToken();
382
382
  if (!token) {
383
- fail("not authenticated — run 'dreamlake login' first");
383
+ fail("not authenticated — run 'dl login' first");
384
384
  return 1;
385
385
  }
386
386
  const remote = resolveRemote();
@@ -431,7 +431,7 @@ export async function runWorkspaceUpload(opts) {
431
431
  export async function runWorkspaceHost(opts) {
432
432
  const token = resolveToken();
433
433
  if (!token) {
434
- fail("not authenticated — run 'dreamlake login' first");
434
+ fail("not authenticated — run 'dl login' first");
435
435
  return 1;
436
436
  }
437
437
  const remote = resolveRemote();