@cmmd-center/forge 0.13.131 → 0.13.132

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 (32) hide show
  1. package/dist/bin.cjs +176 -4
  2. package/dist/bin.mjs +197 -28
  3. package/dist/client/assets/{CanvasPanel-BBU-hosR.js → CanvasPanel-BZ55yFCm.js} +2 -2
  4. package/dist/client/assets/{DiffPanel-CsjpjcNO.js → DiffPanel-Ca2Lz8RB.js} +2 -2
  5. package/dist/client/assets/{DiffPanel.logic-D0tJmmDH.js → DiffPanel.logic-H_2wKBOQ.js} +2 -2
  6. package/dist/client/assets/{DiffWorkerPoolProvider-BaYfOG54.js → DiffWorkerPoolProvider-DSDTeZXk.js} +2 -2
  7. package/dist/client/assets/{PullRequestCodePanel-FsC6jwvA.js → PullRequestCodePanel-7YAkNwLW.js} +2 -2
  8. package/dist/client/assets/{ThemeEditorPanel-DHyAZtjN.js → ThemeEditorPanel-Bgrpa0cR.js} +2 -2
  9. package/dist/client/assets/{Virtualizer-Bt_R5UQD.js → Virtualizer-BzBcEfxL.js} +2 -2
  10. package/dist/client/assets/{WorkerPoolContext-DSayjMnB.js → WorkerPoolContext-8onOdaSo.js} +44 -44
  11. package/dist/client/assets/cmmdAuthRedirect-B_Ad6N4c.js +3 -0
  12. package/dist/client/assets/{cmmdForgeRuntimeListResource-DFLs7Ho_.js → cmmdForgeRuntimeListResource-Bl0ObO-g.js} +4 -4
  13. package/dist/client/assets/{currentForgeWorkspaceStore-B5FQv1gc.js → currentForgeWorkspaceStore-BqHfGv0o.js} +2 -2
  14. package/dist/client/assets/{dialog-mwxYKYq-.js → dialog-DMVibvkf.js} +2 -2
  15. package/dist/client/assets/index-zPBt45p3.js +301 -0
  16. package/dist/client/assets/{popover-BMHhFoom.js → popover-DZpHoNco.js} +2 -2
  17. package/dist/client/assets/{scroll-area-9mmf9iy-.js → scroll-area-dh4WduWB.js} +2 -2
  18. package/dist/client/assets/{sidebarV2CustomSnoozeDialog-vLvqIwRU.js → sidebarV2CustomSnoozeDialog-DsUlSvAq.js} +2 -2
  19. package/dist/client/assets/src-DpAPOFgC.js +3 -0
  20. package/dist/client/assets/{switch-DpGoyzXB.js → switch-Bt0PG_99.js} +2 -2
  21. package/dist/client/assets/{themePalette-BII_gGLK.js → themePalette-rKk-Jh5K.js} +2 -2
  22. package/dist/client/assets/{toggle-CiTk7ztA.js → toggle-CM3FO84q.js} +2 -2
  23. package/dist/client/assets/{toggle-group-B0GQb1vL.js → toggle-group-sUSKwOOz.js} +2 -2
  24. package/dist/client/assets/{tooltip-DlvXFVEM.js → tooltip-DHkQTarv.js} +2 -2
  25. package/dist/client/assets/{utils-BWD4ATf-.js → utils-B9FLzOgF.js} +2 -2
  26. package/dist/client/index.html +18 -18
  27. package/dist/forge-build.json +1 -1
  28. package/dist/{open-2-reBrpv.mjs → open-yHTUkd2Y.mjs} +3 -3
  29. package/package.json +1 -1
  30. package/dist/client/assets/cmmdAuthRedirect-B2FNK6pk.js +0 -3
  31. package/dist/client/assets/index-BFu1LcEj.js +0 -301
  32. package/dist/client/assets/src-DICOHE3E.js +0 -3
package/dist/bin.mjs CHANGED
@@ -23,7 +23,7 @@ import { createCipheriv, createDecipheriv, createHash, createHmac, createPublicK
23
23
  import * as FS$1 from "node:fs";
24
24
  import fs, { accessSync, chmodSync, constants, createReadStream, existsSync, mkdirSync, mkdtempSync, promises, readFile, readFileSync, readdir, readdirSync, realpathSync, rmSync, statSync, unlinkSync, writeFileSync } from "node:fs";
25
25
  import * as NodeOS from "node:os";
26
- import $U, { homedir, networkInterfaces, tmpdir } from "node:os";
26
+ import os, { homedir, networkInterfaces, tmpdir } from "node:os";
27
27
  import * as Path$1 from "node:path";
28
28
  import path, { basename, delimiter, dirname, extname, isAbsolute, join, posix, relative, resolve, sep } from "node:path";
29
29
  import { pathToFileURL } from "node:url";
@@ -20558,6 +20558,42 @@ var FilesystemBrowseError = class extends TaggedErrorClass()("FilesystemBrowseEr
20558
20558
  }
20559
20559
  };
20560
20560
  //#endregion
20561
+ //#region ../../packages/contracts/src/workspaceDirectory.ts
20562
+ const WORKSPACE_DIRECTORY_PATH_MAX_LENGTH = 512;
20563
+ /**
20564
+ * One immediate child of a listed workspace directory.
20565
+ *
20566
+ * `hasChildren` is what lets the Files tree draw an expander only on
20567
+ * directories that open onto something, without listing the whole workspace
20568
+ * up front: a directory entry is one stat-sized readdir, not a recursive walk.
20569
+ */
20570
+ const WorkspaceDirectoryEntry = Struct({
20571
+ name: TrimmedNonEmptyString,
20572
+ kind: Literals(["file", "directory"]),
20573
+ hasChildren: Boolean$1
20574
+ });
20575
+ const WorkspaceListDirectoryInput = Struct({
20576
+ cwd: TrimmedNonEmptyString,
20577
+ relativePath: TrimmedString.check(isMaxLength(WORKSPACE_DIRECTORY_PATH_MAX_LENGTH))
20578
+ });
20579
+ const WorkspaceListDirectoryResult = Struct({ entries: ArraySchema(WorkspaceDirectoryEntry) });
20580
+ const WorkspaceListDirectoryFailure = Literals([
20581
+ "workspace_root_invalid",
20582
+ "path_outside_workspace",
20583
+ "read_directory_failed"
20584
+ ]);
20585
+ var WorkspaceListDirectoryError = class extends TaggedErrorClass()("WorkspaceListDirectoryError", {
20586
+ cwd: String$1,
20587
+ relativePath: String$1,
20588
+ failure: WorkspaceListDirectoryFailure,
20589
+ detail: String$1,
20590
+ cause: optional$4(Defect)
20591
+ }) {
20592
+ get message() {
20593
+ return this.detail;
20594
+ }
20595
+ };
20596
+ //#endregion
20561
20597
  //#region ../../packages/contracts/src/terminal.ts
20562
20598
  const DEFAULT_TERMINAL_ID = "default";
20563
20599
  const TrimmedNonEmptyStringSchema$3 = TrimmedNonEmptyString;
@@ -26009,6 +26045,7 @@ const WS_METHODS = {
26009
26045
  projectsWriteFile: "projects.writeFile",
26010
26046
  projectCheckoutDeletionPreview: "projectCheckoutDeletion.preview",
26011
26047
  projectCheckoutDeletionExecute: "projectCheckoutDeletion.execute",
26048
+ workspaceListDirectory: "workspace.listDirectory",
26012
26049
  workspaceReadFile: "workspace.readFile",
26013
26050
  workspaceBeginWriteFile: "workspace.beginWriteFile",
26014
26051
  workspaceWriteFileChunk: "workspace.writeFileChunk",
@@ -26320,6 +26357,17 @@ const WsWorkspaceCancelWriteFileRpc = make$29(WS_METHODS.workspaceCancelWriteFil
26320
26357
  success: BulkTransferCancelResult,
26321
26358
  error: BulkTransferError
26322
26359
  });
26360
+ /**
26361
+ * One workspace directory's immediate children, for the right panel's Files
26362
+ * tree. Read-scoped and confined to the workspace root on the server; the tree
26363
+ * expands one directory at a time through this method rather than listing the
26364
+ * whole workspace up front.
26365
+ */
26366
+ const WsWorkspaceListDirectoryRpc = make$29(WS_METHODS.workspaceListDirectory, {
26367
+ payload: WorkspaceListDirectoryInput,
26368
+ success: WorkspaceListDirectoryResult,
26369
+ error: WorkspaceListDirectoryError
26370
+ });
26323
26371
  const WsShellOpenInEditorRpc = make$29(WS_METHODS.shellOpenInEditor, {
26324
26372
  payload: OpenInEditorInput,
26325
26373
  error: OpenError$1
@@ -26743,7 +26791,7 @@ const WsRpcGroup = make$28(WsServerGetConfigRpc, WsServerRefreshProvidersRpc, Ws
26743
26791
  payload: UsageSummaryInput,
26744
26792
  success: UsageSummary,
26745
26793
  error: UsageReadError
26746
- }), WsPullRequestsListRpc, WsPullRequestsListStatsRpc, WsPullRequestsDetailRpc, WsPullRequestsActivityRpc, WsPullRequestsThreadCommentsRpc, WsPullRequestsDiffFileContentsRpc, WsPullRequestsRunActionRpc, WsPullRequestsUpdateRpc, WsPullRequestsCommentRpc, WsPullRequestsUpdateCommentRpc, WsPullRequestsSubmitReviewRpc, WsPullRequestsReplyToThreadRpc, WsPullRequestsSetThreadResolutionRpc, WsPullRequestsSetReactionRpc, WsPullRequestsInvalidateRpc, WsPullRequestsReviewerCandidatesRpc, WsPullRequestsRequestReviewersRpc, WsProjectsSearchContentsRpc, WsProjectsSearchEntriesRpc, WsProjectsWriteFileRpc, WsProjectCheckoutDeletionPreviewRpc, WsProjectCheckoutDeletionExecuteRpc, WsWorkspaceReadFileRpc, WsWorkspaceBeginWriteFileRpc, WsWorkspaceWriteFileChunkRpc, WsWorkspaceCommitWriteFileRpc, WsWorkspaceCancelWriteFileRpc, WsShellOpenInEditorRpc, WsSubscribeGitStatusRpc, WsGitPullRpc, WsGitRefreshStatusRpc, WsGitRunStackedActionRpc, WsGitResolvePullRequestRpc, WsGitPreparePullRequestThreadRpc, WsGitListBranchesRpc, WsVcsListRefsRpc, WsVcsRefreshStatusRpc, WsSubscribeVcsStatusRpc, WsVcsPullRpc, WsVcsCreateWorktreeRpc, WsVcsRemoveWorktreeRpc, WsVcsCreateRefRpc, WsVcsSwitchRefRpc, WsVcsInitRpc, WsGitCreateWorktreeRpc, WsGitRemoveWorktreeRpc, WsGitCreateBranchRpc, WsGitCheckoutRpc, WsGitInitRpc, WsFilesystemBrowseRpc, WsProjectsReadFileRpc, WsReviewGetDiffPreviewRpc, WsCloudListRuntimesRpc, WsTerminalOpenRpc, WsTerminalAttachRpc, WsTerminalWriteRpc, WsTerminalResizeRpc, WsTerminalSignalRpc, WsTerminalClearRpc, WsTerminalRestartRpc, WsTerminalCloseRpc, WsBrowserOpenSessionRpc, WsBrowserListSessionsRpc, WsBrowserCloseSessionRpc, WsBrowserGetSessionRpc, WsBrowserCommandRpc, WsBrowserClearBrowsingDataRpc, WsBrowserAttachDisplayRpc, WsBrowserAddDisplayIceCandidateRpc, WsComputerInputRpc, WsDevTunnelRegisterRpc, WsDevTunnelUnregisterRpc, WsDevTunnelListRpc, WsThreadDevRuntimeGetRpc, WsThreadDevRuntimeAllocatePortRpc, WsThreadDevRuntimeReleaseRpc, WsWorkspaceEnvironmentPreflightRpc, WsWorkspaceEnsureScratchRpc, WsSubscribeTerminalEventsRpc, WsSubscribeTerminalMetadataRpc, WsProjectsListEntriesRpc, WsServerDiscoverSourceControlRpc, WsServerReportClientActivityRpc, WsSubscribeBrowserEventsRpc, WsSubscribeServerConfigRpc, WsSubscribeServerLifecycleRpc, WsSubscribeAuthAccessRpc, WsSubscribeWorkspaceReadinessRpc, WsOrchestrationDispatchCommandRpc, WsOrchestrationGetTurnDiffRpc, WsOrchestrationGetFullThreadDiffRpc, WsOrchestrationStreamTurnDiffRpc, WsOrchestrationStreamFullThreadDiffRpc, WsOrchestrationReplayEventsRpc, WsOrchestrationGetArchivedShellSnapshotRpc, WsOrchestrationSubscribeShellRpc, WsOrchestrationSubscribeThreadRpc, make$29(WS_METHODS.assetsCreateUrl, {
26794
+ }), WsPullRequestsListRpc, WsPullRequestsListStatsRpc, WsPullRequestsDetailRpc, WsPullRequestsActivityRpc, WsPullRequestsThreadCommentsRpc, WsPullRequestsDiffFileContentsRpc, WsPullRequestsRunActionRpc, WsPullRequestsUpdateRpc, WsPullRequestsCommentRpc, WsPullRequestsUpdateCommentRpc, WsPullRequestsSubmitReviewRpc, WsPullRequestsReplyToThreadRpc, WsPullRequestsSetThreadResolutionRpc, WsPullRequestsSetReactionRpc, WsPullRequestsInvalidateRpc, WsPullRequestsReviewerCandidatesRpc, WsPullRequestsRequestReviewersRpc, WsProjectsSearchContentsRpc, WsProjectsSearchEntriesRpc, WsProjectsWriteFileRpc, WsProjectCheckoutDeletionPreviewRpc, WsProjectCheckoutDeletionExecuteRpc, WsWorkspaceReadFileRpc, WsWorkspaceListDirectoryRpc, WsWorkspaceBeginWriteFileRpc, WsWorkspaceWriteFileChunkRpc, WsWorkspaceCommitWriteFileRpc, WsWorkspaceCancelWriteFileRpc, WsShellOpenInEditorRpc, WsSubscribeGitStatusRpc, WsGitPullRpc, WsGitRefreshStatusRpc, WsGitRunStackedActionRpc, WsGitResolvePullRequestRpc, WsGitPreparePullRequestThreadRpc, WsGitListBranchesRpc, WsVcsListRefsRpc, WsVcsRefreshStatusRpc, WsSubscribeVcsStatusRpc, WsVcsPullRpc, WsVcsCreateWorktreeRpc, WsVcsRemoveWorktreeRpc, WsVcsCreateRefRpc, WsVcsSwitchRefRpc, WsVcsInitRpc, WsGitCreateWorktreeRpc, WsGitRemoveWorktreeRpc, WsGitCreateBranchRpc, WsGitCheckoutRpc, WsGitInitRpc, WsFilesystemBrowseRpc, WsProjectsReadFileRpc, WsReviewGetDiffPreviewRpc, WsCloudListRuntimesRpc, WsTerminalOpenRpc, WsTerminalAttachRpc, WsTerminalWriteRpc, WsTerminalResizeRpc, WsTerminalSignalRpc, WsTerminalClearRpc, WsTerminalRestartRpc, WsTerminalCloseRpc, WsBrowserOpenSessionRpc, WsBrowserListSessionsRpc, WsBrowserCloseSessionRpc, WsBrowserGetSessionRpc, WsBrowserCommandRpc, WsBrowserClearBrowsingDataRpc, WsBrowserAttachDisplayRpc, WsBrowserAddDisplayIceCandidateRpc, WsComputerInputRpc, WsDevTunnelRegisterRpc, WsDevTunnelUnregisterRpc, WsDevTunnelListRpc, WsThreadDevRuntimeGetRpc, WsThreadDevRuntimeAllocatePortRpc, WsThreadDevRuntimeReleaseRpc, WsWorkspaceEnvironmentPreflightRpc, WsWorkspaceEnsureScratchRpc, WsSubscribeTerminalEventsRpc, WsSubscribeTerminalMetadataRpc, WsProjectsListEntriesRpc, WsServerDiscoverSourceControlRpc, WsServerReportClientActivityRpc, WsSubscribeBrowserEventsRpc, WsSubscribeServerConfigRpc, WsSubscribeServerLifecycleRpc, WsSubscribeAuthAccessRpc, WsSubscribeWorkspaceReadinessRpc, WsOrchestrationDispatchCommandRpc, WsOrchestrationGetTurnDiffRpc, WsOrchestrationGetFullThreadDiffRpc, WsOrchestrationStreamTurnDiffRpc, WsOrchestrationStreamFullThreadDiffRpc, WsOrchestrationReplayEventsRpc, WsOrchestrationGetArchivedShellSnapshotRpc, WsOrchestrationSubscribeShellRpc, WsOrchestrationSubscribeThreadRpc, make$29(WS_METHODS.assetsCreateUrl, {
26747
26795
  payload: AssetsRpcSchemas.createUrl.input,
26748
26796
  success: AssetsRpcSchemas.createUrl.output,
26749
26797
  error: AssetAccessError
@@ -31485,6 +31533,11 @@ const RELAY_METHOD_POLICY_BASES = [
31485
31533
  requiredScope: "workspace.read",
31486
31534
  deliveryClass: "read"
31487
31535
  },
31536
+ {
31537
+ method: WS_METHODS.workspaceListDirectory,
31538
+ requiredScope: "workspace.read",
31539
+ deliveryClass: "read"
31540
+ },
31488
31541
  {
31489
31542
  method: WS_METHODS.workspaceReadFile,
31490
31543
  requiredScope: "workspace.read",
@@ -50674,7 +50727,7 @@ function _supportsColor(haveStream, { streamIsTTY, sniffFlags = true } = {}) {
50674
50727
  const min = forceColor || 0;
50675
50728
  if (env.TERM === "dumb") return min;
50676
50729
  if (process$1.platform === "win32") {
50677
- const osRelease = $U.release().split(".");
50730
+ const osRelease = os.release().split(".");
50678
50731
  if (Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) return Number(osRelease[2]) >= 14931 ? 3 : 2;
50679
50732
  return 1;
50680
50733
  }
@@ -53117,7 +53170,7 @@ var require_ProcessDetector = /* @__PURE__ */ __commonJSMin(((exports) => {
53117
53170
  exports.processDetector = void 0;
53118
53171
  const api_1 = (init_esm$1(), __toCommonJS(esm_exports$1));
53119
53172
  const semconv_1 = require_semconv$1();
53120
- const os$3 = __require("os");
53173
+ const os$4 = __require("os");
53121
53174
  /**
53122
53175
  * ProcessDetector will be used to detect the resources related current process running
53123
53176
  * and being instrumented from the NodeJS Process module.
@@ -53139,7 +53192,7 @@ var require_ProcessDetector = /* @__PURE__ */ __commonJSMin(((exports) => {
53139
53192
  };
53140
53193
  if (process.argv.length > 1) attributes[semconv_1.ATTR_PROCESS_COMMAND] = process.argv[1];
53141
53194
  try {
53142
- const userInfo = os$3.userInfo();
53195
+ const userInfo = os$4.userInfo();
53143
53196
  attributes[semconv_1.ATTR_PROCESS_OWNER] = userInfo.username;
53144
53197
  } catch (e) {
53145
53198
  api_1.diag.debug(`error obtaining process owner: ${e}`);
@@ -66062,7 +66115,7 @@ function normalizeNumberish(value) {
66062
66115
  }
66063
66116
  //#endregion
66064
66117
  //#region package.json
66065
- var version$1 = "0.13.131";
66118
+ var version$1 = "0.13.132";
66066
66119
  //#endregion
66067
66120
  //#region src/sentry.ts
66068
66121
  const SERVER_APP_NAME = "forge-server";
@@ -76305,7 +76358,7 @@ var require_node_gyp_build = /* @__PURE__ */ __commonJSMin(((exports, module) =>
76305
76358
  var fs$6 = __require("fs");
76306
76359
  var path$5 = __require("path");
76307
76360
  var url$1 = __require("url");
76308
- var os$2 = __require("os");
76361
+ var os$3 = __require("os");
76309
76362
  var runtimeRequire = typeof __webpack_require__ === "function" ? __non_webpack_require__ : __require;
76310
76363
  var vars = process.config && process.config.variables || {};
76311
76364
  var prebuildsOnly = !!process.env.PREBUILDS_ONLY;
@@ -76313,8 +76366,8 @@ var require_node_gyp_build = /* @__PURE__ */ __commonJSMin(((exports, module) =>
76313
76366
  var abi = versions.modules;
76314
76367
  if (versions.deno || process.isBun) abi = "unsupported";
76315
76368
  var runtime = isElectron() ? "electron" : isNwjs() ? "node-webkit" : "node";
76316
- var arch = process.env.npm_config_arch || os$2.arch();
76317
- var platform = process.env.npm_config_platform || os$2.platform();
76369
+ var arch = process.env.npm_config_arch || os$3.arch();
76370
+ var platform = process.env.npm_config_platform || os$3.platform();
76318
76371
  var libc = process.env.LIBC || (isMusl(platform) ? "musl" : "glibc");
76319
76372
  var armv = process.env.ARM_VERSION || (arch === "arm64" ? "8" : vars.arm_version) || "";
76320
76373
  var uv = (versions.uv || "").split(".")[0];
@@ -94158,7 +94211,7 @@ const launchDetached = (launch) => gen(function* () {
94158
94211
  });
94159
94212
  const OpenLive = effect(Open, gen(function* () {
94160
94213
  const open = yield* tryPromise({
94161
- try: () => import("./open-2-reBrpv.mjs"),
94214
+ try: () => import("./open-yHTUkd2Y.mjs"),
94162
94215
  catch: (cause) => new OpenError$1({
94163
94216
  message: "failed to load browser opener",
94164
94217
  cause
@@ -102310,6 +102363,22 @@ var WorkspaceFileSystem = class extends Service$1()("forge/workspace/Services/Wo
102310
102363
  //#region src/workspace/Services/WorkspaceBulkTransfer.ts
102311
102364
  var WorkspaceBulkTransfer = class extends Service$1()("forge/workspace/Services/WorkspaceBulkTransfer") {};
102312
102365
  //#endregion
102366
+ //#region src/workspace/Services/WorkspaceDirectoryListing.ts
102367
+ /**
102368
+ * WorkspaceDirectoryListing - Effect service contract for one directory's
102369
+ * immediate children.
102370
+ *
102371
+ * Owns workspace-root-confined directory listings for the Files tree: the
102372
+ * caller names a workspace root (the thread's checkout) and a root-relative
102373
+ * directory, and gets that directory's children back, one readdir deep.
102374
+ *
102375
+ * @module WorkspaceDirectoryListing
102376
+ */
102377
+ /**
102378
+ * WorkspaceDirectoryListing - Service tag for workspace directory listings.
102379
+ */
102380
+ var WorkspaceDirectoryListing = class extends Service$1()("forge/workspace/Services/WorkspaceDirectoryListing") {};
102381
+ //#endregion
102313
102382
  //#region src/workspace/Services/WorkspaceReadinessState.ts
102314
102383
  var WorkspaceReadinessState = class extends Service$1()("forge/workspace/Services/WorkspaceReadinessState") {};
102315
102384
  //#endregion
@@ -107719,6 +107788,7 @@ const makeWsRpcLayer = (currentSessionId, currentUserId) => WsRpcGroup.toLayer(g
107719
107788
  const discoverSourceControl = yield* makeCachedSourceControlDiscovery;
107720
107789
  const workspaceFileSystem = yield* WorkspaceFileSystem;
107721
107790
  const workspaceBulkTransfer = yield* WorkspaceBulkTransfer;
107791
+ const workspaceDirectoryListing = yield* WorkspaceDirectoryListing;
107722
107792
  const projectCheckoutDeletion = yield* serviceOption(ProjectCheckoutDeletion);
107723
107793
  const workspaceReadinessState = yield* WorkspaceReadinessState;
107724
107794
  const projectSetupScriptRunner = yield* ProjectSetupScriptRunner;
@@ -108067,6 +108137,7 @@ const makeWsRpcLayer = (currentSessionId, currentUserId) => WsRpcGroup.toLayer(g
108067
108137
  blockers: ["deletion_authority_unavailable"]
108068
108138
  }), { "rpc.aggregate": "workspace" }),
108069
108139
  [WS_METHODS.workspaceReadFile]: (input) => observeRpcStream(WS_METHODS.workspaceReadFile, workspaceBulkTransfer.readFile(input), { "rpc.aggregate": "workspace" }),
108140
+ [WS_METHODS.workspaceListDirectory]: (input) => observeRpcEffect(WS_METHODS.workspaceListDirectory, workspaceDirectoryListing.list(input), { "rpc.aggregate": "workspace" }),
108070
108141
  [WS_METHODS.workspaceBeginWriteFile]: (input) => observeRpcEffect(WS_METHODS.workspaceBeginWriteFile, workspaceBulkTransfer.beginWrite(input), { "rpc.aggregate": "workspace" }),
108071
108142
  [WS_METHODS.workspaceWriteFileChunk]: (input) => observeRpcEffect(WS_METHODS.workspaceWriteFileChunk, workspaceBulkTransfer.writeChunk(input), { "rpc.aggregate": "workspace" }),
108072
108143
  [WS_METHODS.workspaceCommitWriteFile]: (input) => observeRpcEffect(WS_METHODS.workspaceCommitWriteFile, workspaceBulkTransfer.commitWrite(input), { "rpc.aggregate": "workspace" }),
@@ -192459,7 +192530,7 @@ var Vce = {
192459
192530
  function Ve() {
192460
192531
  return Vce;
192461
192532
  }
192462
- var Us = $U.homedir(), lk = $U.tmpdir(), { env: Vc } = process$1, Yce = (e) => {
192533
+ var Us = os.homedir(), lk = os.tmpdir(), { env: Vc } = process$1, Yce = (e) => {
192463
192534
  let t = path.join(Us, "Library");
192464
192535
  return {
192465
192536
  data: path.join(t, "Application Support", e),
@@ -202659,12 +202730,12 @@ function qZ(e, t) {
202659
202730
  }
202660
202731
  return n;
202661
202732
  }
202662
- var os$1 = "https://code.claude.com/docs/en", kKe = [
202733
+ var os$2 = "https://code.claude.com/docs/en", kKe = [
202663
202734
  {
202664
202735
  matches: (e) => e.path === "permissions.defaultMode" && e.code === "invalid_value",
202665
202736
  tip: {
202666
202737
  suggestion: "Valid modes: \"acceptEdits\" (ask before file changes), \"plan\" (analysis only), \"bypassPermissions\" (auto-accept all), or \"default\" (standard behavior)",
202667
- docLink: `${os$1}/iam#permission-modes`
202738
+ docLink: `${os$2}/iam#permission-modes`
202668
202739
  }
202669
202740
  },
202670
202741
  {
@@ -202679,7 +202750,7 @@ var os$1 = "https://code.claude.com/docs/en", kKe = [
202679
202750
  matches: (e) => e.path.startsWith("env.") && e.code === "invalid_type",
202680
202751
  tip: {
202681
202752
  suggestion: "Environment variables must be strings. Wrap numbers and booleans in quotes. Example: \"DEBUG\": \"true\", \"PORT\": \"3000\"",
202682
- docLink: `${os$1}/settings#environment-variables`
202753
+ docLink: `${os$2}/settings#environment-variables`
202683
202754
  }
202684
202755
  },
202685
202756
  {
@@ -202690,14 +202761,14 @@ var os$1 = "https://code.claude.com/docs/en", kKe = [
202690
202761
  matches: (e) => e.path.startsWith("hooks.") && e.code === "invalid_key",
202691
202762
  tip: {
202692
202763
  suggestion: "Not a recognized hook event. Common events: PreToolUse, PostToolUse, UserPromptSubmit, SessionStart, SessionEnd, Stop. Check spelling and capitalization.",
202693
- docLink: `${os$1}/hooks`
202764
+ docLink: `${os$2}/hooks`
202694
202765
  }
202695
202766
  },
202696
202767
  {
202697
202768
  matches: (e) => /\.hooks\.\d+\.command$/.test(e.path) && e.code === "invalid_type" && e.received === "undefined",
202698
202769
  tip: {
202699
202770
  suggestion: "Command hooks require `command`. For exec form (no shell), set `command` to the executable and `args` to its arguments: {\"type\": \"command\", \"command\": \"echo\", \"args\": [\"hi\"]}. For shell form, set `command` to the full shell string: {\"type\": \"command\", \"command\": \"echo hi\"}.",
202700
- docLink: `${os$1}/hooks#exec-form-and-shell-form`
202771
+ docLink: `${os$2}/hooks#exec-form-and-shell-form`
202701
202772
  }
202702
202773
  },
202703
202774
  {
@@ -202712,7 +202783,7 @@ var os$1 = "https://code.claude.com/docs/en", kKe = [
202712
202783
  matches: (e) => e.code === "unrecognized_keys",
202713
202784
  tip: {
202714
202785
  suggestion: "Check for typos or refer to the documentation for valid fields",
202715
- docLink: `${os$1}/settings`
202786
+ docLink: `${os$2}/settings`
202716
202787
  }
202717
202788
  },
202718
202789
  {
@@ -202727,13 +202798,13 @@ var os$1 = "https://code.claude.com/docs/en", kKe = [
202727
202798
  matches: (e) => e.path === "permissions.additionalDirectories" && e.code === "invalid_type",
202728
202799
  tip: {
202729
202800
  suggestion: "Must be an array of directory paths. Example: [\"~/projects\", \"/tmp/workspace\"]. You can also use --add-dir flag or /add-dir command",
202730
- docLink: `${os$1}/iam#working-directories`
202801
+ docLink: `${os$2}/iam#working-directories`
202731
202802
  }
202732
202803
  }
202733
202804
  ], AKe = {
202734
- permissions: `${os$1}/iam#configuring-permissions`,
202735
- env: `${os$1}/settings#environment-variables`,
202736
- hooks: `${os$1}/hooks`
202805
+ permissions: `${os$2}/iam#configuring-permissions`,
202806
+ env: `${os$2}/settings#environment-variables`,
202807
+ hooks: `${os$2}/hooks`
202737
202808
  };
202738
202809
  function GZ(e) {
202739
202810
  let t = kKe.find((r) => r.matches(e));
@@ -271277,7 +271348,7 @@ var import_multicast_dns = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMi
271277
271348
  var dgram = __require("dgram");
271278
271349
  var thunky = require_thunky();
271279
271350
  var events = __require("events");
271280
- var os = __require("os");
271351
+ var os$1 = __require("os");
271281
271352
  var noop = function() {};
271282
271353
  module.exports = function(opts) {
271283
271354
  if (!opts) opts = {};
@@ -271408,14 +271479,14 @@ var import_multicast_dns = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMi
271408
271479
  return that;
271409
271480
  };
271410
271481
  function defaultInterface() {
271411
- var networks = os.networkInterfaces();
271482
+ var networks = os$1.networkInterfaces();
271412
271483
  var names = Object.keys(networks);
271413
271484
  for (var i = 0; i < names.length; i++) {
271414
271485
  var net = networks[names[i]];
271415
271486
  for (var j = 0; j < net.length; j++) {
271416
271487
  var iface = net[j];
271417
271488
  if (isIPv4(iface.family) && !iface.internal) {
271418
- if (os.platform() === "darwin" && names[i] === "en0") return iface.address;
271489
+ if (os$1.platform() === "darwin" && names[i] === "en0") return iface.address;
271419
271490
  return "0.0.0.0";
271420
271491
  }
271421
271492
  }
@@ -271423,7 +271494,7 @@ var import_multicast_dns = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMi
271423
271494
  return "127.0.0.1";
271424
271495
  }
271425
271496
  function allInterfaces() {
271426
- var networks = os.networkInterfaces();
271497
+ var networks = os$1.networkInterfaces();
271427
271498
  var names = Object.keys(networks);
271428
271499
  var res = [];
271429
271500
  for (var i = 0; i < names.length; i++) {
@@ -298465,6 +298536,104 @@ const makeWorkspaceBulkTransfer = (options = {}) => gen(function* () {
298465
298536
  });
298466
298537
  const WorkspaceBulkTransferLive = effect(WorkspaceBulkTransfer, makeWorkspaceBulkTransfer());
298467
298538
  //#endregion
298539
+ //#region src/workspace/Layers/WorkspaceDirectoryListing.ts
298540
+ function isPathWithin(path, root, candidate) {
298541
+ const relative = path.relative(root, candidate);
298542
+ return relative.length === 0 || !relative.startsWith("..") && !path.isAbsolute(relative);
298543
+ }
298544
+ /**
298545
+ * Directories sort before files so the tree reads like every other file tree;
298546
+ * names compare case-insensitively, then by raw name so stable order survives
298547
+ * a platform that folds case differently.
298548
+ */
298549
+ function compareEntries(left, right) {
298550
+ if (left.kind !== right.kind) return left.kind === "directory" ? -1 : 1;
298551
+ const byName = left.name.localeCompare(right.name, void 0, { sensitivity: "accent" });
298552
+ return byName !== 0 ? byName : left.name < right.name ? -1 : left.name > right.name ? 1 : 0;
298553
+ }
298554
+ const WorkspaceDirectoryListingLive = effect(WorkspaceDirectoryListing, gen(function* () {
298555
+ const fileSystem = yield* FileSystem;
298556
+ const path = yield* Path$2;
298557
+ const workspacePaths = yield* WorkspacePaths;
298558
+ return { list: fn$1("WorkspaceDirectoryListing.list")(function* (input) {
298559
+ const workspaceRoot = yield* workspacePaths.normalizeWorkspaceRoot(input.cwd).pipe(mapError(() => new WorkspaceListDirectoryError({
298560
+ cwd: input.cwd,
298561
+ relativePath: input.relativePath,
298562
+ failure: "workspace_root_invalid",
298563
+ detail: `Workspace root is not a usable directory: ${input.cwd}`
298564
+ })));
298565
+ const trimmed = input.relativePath.trim();
298566
+ if (path.isAbsolute(trimmed)) return yield* new WorkspaceListDirectoryError({
298567
+ cwd: input.cwd,
298568
+ relativePath: input.relativePath,
298569
+ failure: "path_outside_workspace",
298570
+ detail: "Directory listings must use workspace-relative paths."
298571
+ });
298572
+ const resolved = trimmed.length === 0 ? {
298573
+ absolutePath: workspaceRoot,
298574
+ relativePath: ""
298575
+ } : yield* workspacePaths.resolveRelativePathWithinRoot({
298576
+ workspaceRoot,
298577
+ relativePath: trimmed
298578
+ }).pipe(mapError(() => new WorkspaceListDirectoryError({
298579
+ cwd: input.cwd,
298580
+ relativePath: input.relativePath,
298581
+ failure: "path_outside_workspace",
298582
+ detail: `Directory is outside the workspace: ${input.relativePath}`
298583
+ })));
298584
+ const canonicalRoot = yield* fileSystem.realPath(workspaceRoot).pipe(orDie);
298585
+ const targetRealPath = yield* fileSystem.realPath(resolved.absolutePath).pipe(catch_(() => succeed(null)));
298586
+ if (targetRealPath === null) return yield* new WorkspaceListDirectoryError({
298587
+ cwd: input.cwd,
298588
+ relativePath: input.relativePath,
298589
+ failure: "read_directory_failed",
298590
+ detail: `Directory does not exist: ${input.relativePath || "."}`
298591
+ });
298592
+ if (!isPathWithin(path, canonicalRoot, targetRealPath)) return yield* new WorkspaceListDirectoryError({
298593
+ cwd: input.cwd,
298594
+ relativePath: input.relativePath,
298595
+ failure: "path_outside_workspace",
298596
+ detail: `Directory does not resolve inside the workspace: ${input.relativePath}`
298597
+ });
298598
+ const targetStat = yield* fileSystem.stat(targetRealPath).pipe(option);
298599
+ if (targetStat._tag === "None" || targetStat.value.type !== "Directory") return yield* new WorkspaceListDirectoryError({
298600
+ cwd: input.cwd,
298601
+ relativePath: input.relativePath,
298602
+ failure: "read_directory_failed",
298603
+ detail: `Not a directory: ${input.relativePath}`
298604
+ });
298605
+ return { entries: (yield* forEach(yield* fileSystem.readDirectory(targetRealPath).pipe(mapError((cause) => new WorkspaceListDirectoryError({
298606
+ cwd: input.cwd,
298607
+ relativePath: input.relativePath,
298608
+ failure: "read_directory_failed",
298609
+ detail: `Could not read directory: ${input.relativePath}`,
298610
+ cause
298611
+ }))), (name) => gen(function* () {
298612
+ const entryPath = path.join(targetRealPath, name);
298613
+ if ((yield* fileSystem.readLink(entryPath).pipe(option))._tag === "Some") return {
298614
+ name,
298615
+ kind: "file",
298616
+ hasChildren: false
298617
+ };
298618
+ const stat = yield* fileSystem.stat(entryPath).pipe(option);
298619
+ if (stat._tag === "None") return void 0;
298620
+ if (stat.value.type === "Directory") {
298621
+ const children = yield* fileSystem.readDirectory(entryPath).pipe(option);
298622
+ return {
298623
+ name,
298624
+ kind: "directory",
298625
+ hasChildren: children._tag === "Some" && children.value.length > 0
298626
+ };
298627
+ }
298628
+ return {
298629
+ name,
298630
+ kind: "file",
298631
+ hasChildren: false
298632
+ };
298633
+ }), { concurrency: 16 })).filter((entry) => entry !== void 0).toSorted(compareEntries) };
298634
+ }) };
298635
+ }));
298636
+ //#endregion
298468
298637
  //#region src/workspace/Layers/WorkspacePaths.ts
298469
298638
  function toPosixRelativePath(input) {
298470
298639
  return input.replaceAll("\\", "/");
@@ -300058,7 +300227,7 @@ function resolveBuildCommitFromEnv(env) {
300058
300227
  * environment descriptor down instead of reporting an honest "unknown".
300059
300228
  */
300060
300229
  function readBakedBuildCommit() {
300061
- return "84e1e008ce3e3d30e5e80361598aa54ed7bda92d";
300230
+ return "b5d9623e21d1d5b372b4133d72c12136356d744e";
300062
300231
  }
300063
300232
  async function resolveServerBuildCommit(input) {
300064
300233
  if (isFullCommitSha(input.baked)) return input.baked;
@@ -324589,7 +324758,7 @@ const ProjectLeadSchedulerRuntimeLayerLive = makeProjectLeadSchedulerRuntimeLive
324589
324758
  const GitManagerLayerLive = GitManagerLive.pipe(provideMerge(ProjectSetupScriptRunnerLive), provideMerge(GitCoreLive), provideMerge(GitHubCliLive), provideMerge(RoutingTextGenerationLive.pipe(provide$1(TextGenerationUsageLive.pipe(provide$1(RuntimeReplicationOutboxLive), provide$1(TextGenerationSessionRepositoryLive))))));
324590
324759
  const GitLayerLive = empty$4.pipe(provideMerge(GitManagerLayerLive), provideMerge(GitStatusBroadcasterLive.pipe(provide$1(GitManagerLayerLive))), provideMerge(GitCoreLive));
324591
324760
  const TerminalLayerLive = TerminalManagerLive.pipe(provide$1(PtyAdapterLive));
324592
- const WorkspaceLayerLive = mergeAll(WorkspacePathsLive, ProjectCheckoutDeletionLive.pipe(provide$1(GitCoreLive), provide$1(ProjectionProjectRepositoryLive)), WorkspaceEntriesLive.pipe(provide$1(WorkspacePathsLive)), WorkspaceFileSystemLive.pipe(provide$1(WorkspacePathsLive), provide$1(WorkspaceEntriesLive.pipe(provide$1(WorkspacePathsLive)))), WorkspaceBulkTransferLive.pipe(provide$1(WorkspacePathsLive), provide$1(WorkspaceEntriesLive.pipe(provide$1(WorkspacePathsLive)))));
324761
+ const WorkspaceLayerLive = mergeAll(WorkspacePathsLive, ProjectCheckoutDeletionLive.pipe(provide$1(GitCoreLive), provide$1(ProjectionProjectRepositoryLive)), WorkspaceEntriesLive.pipe(provide$1(WorkspacePathsLive)), WorkspaceFileSystemLive.pipe(provide$1(WorkspacePathsLive), provide$1(WorkspaceEntriesLive.pipe(provide$1(WorkspacePathsLive)))), WorkspaceBulkTransferLive.pipe(provide$1(WorkspacePathsLive), provide$1(WorkspaceEntriesLive.pipe(provide$1(WorkspacePathsLive)))), WorkspaceDirectoryListingLive.pipe(provide$1(WorkspacePathsLive)));
324593
324762
  const AuthLayerLive = ServerAuthLive.pipe(provideMerge(PersistenceLayerLive), provide$1(ServerSecretStoreLayerLive));
324594
324763
  const MiscRuntimeLayerLive = mergeAll(AnalyticsServiceLayerLive, OpenLive, ServerLifecycleEventsLive, layer$4);
324595
324764
  const RuntimeDependenciesWithoutPullRequestsLive = ReactorLayerLive.pipe(provideMerge(CheckpointingLayerLive), provideMerge(GitLayerLive), provideMerge(OrchestrationLayerLive), provideMerge(ProviderLayerLive), provideMerge(TerminalLayerLive), provideMerge(AgentBrowserManagerLive), provideMerge(mergeAll(ThreadDevRuntimeLive, DevTunnelLive.pipe(provide$1(ThreadDevRuntimeLive)))), provideMerge(PersistenceLayerLive), provideMerge(KeybindingsLive), provideMerge(ProviderRegistryLive), provideMerge(mergeAll(ServerSettingsLive, UsageServiceLive.pipe(provide$1(ServerSettingsLive), provide$1(UsageSessionLookupLive), provide$1(UsageRecordedSourceLive.pipe(provide$1(OrchestrationLayerLive), provide$1(RuntimeReplicationOutboxLive), provide$1(ProviderSessionRuntimeRepositoryLive), provide$1(TextGenerationSessionRepositoryLive)))))), provideMerge(WorkspaceLayerLive), provideMerge(WorkspaceReadinessStateLive), provideMerge(ProjectFaviconResolverLive), provideMerge(RepositoryIdentityResolverLive), provideMerge(ServerEnvironmentLive), provideMerge(AuthLayerLive), provideMerge(ServerSecretStoreLayerLive), provideMerge(mergeAll(CloudRedisCoordinationLive, CloudStateSyncLive.pipe(provide$1(PersistenceLayerLive)))), provideMerge(MiscRuntimeLayerLive));
@@ -325527,7 +325696,7 @@ const connectLoginCommand = make$33("login", {
325527
325696
  })).json();
325528
325697
  },
325529
325698
  openBrowser: async (url) => {
325530
- const open = (await import("./open-2-reBrpv.mjs")).default;
325699
+ const open = (await import("./open-yHTUkd2Y.mjs")).default;
325531
325700
  await open(url);
325532
325701
  return true;
325533
325702
  },