@openclaw/fs-safe 0.12.0 → 0.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +61 -0
- package/README.md +12 -7
- package/dist/absolute-path.d.ts.map +1 -1
- package/dist/absolute-path.js +32 -11
- package/dist/advanced.d.ts +2 -0
- package/dist/advanced.d.ts.map +1 -1
- package/dist/advanced.js +2 -0
- package/dist/archive-input.d.ts.map +1 -1
- package/dist/archive-input.js +6 -2
- package/dist/archive-merge.d.ts.map +1 -1
- package/dist/archive-merge.js +15 -2
- package/dist/archive-native.d.ts.map +1 -1
- package/dist/archive-native.js +7 -19
- package/dist/archive-plan.js +1 -1
- package/dist/archive-read.d.ts.map +1 -1
- package/dist/archive-read.js +18 -13
- package/dist/archive-staging.d.ts.map +1 -1
- package/dist/archive-staging.js +43 -10
- package/dist/archive-tar-inspect.d.ts.map +1 -1
- package/dist/archive-tar-inspect.js +4 -1
- package/dist/archive-zip-admission.d.ts +1 -1
- package/dist/archive-zip-admission.d.ts.map +1 -1
- package/dist/archive-zip-admission.js +2 -2
- package/dist/archive-zip-directory.d.ts +3 -0
- package/dist/archive-zip-directory.d.ts.map +1 -1
- package/dist/archive-zip-directory.js +13 -2
- package/dist/archive-zip-loader.d.ts +3 -2
- package/dist/archive-zip-loader.d.ts.map +1 -1
- package/dist/archive-zip-loader.js +30 -4
- package/dist/archive-zip-manifest.d.ts +5 -0
- package/dist/archive-zip-manifest.d.ts.map +1 -0
- package/dist/archive-zip-manifest.js +22 -0
- package/dist/archive-zip-names.d.ts +6 -1
- package/dist/archive-zip-names.d.ts.map +1 -1
- package/dist/archive-zip-names.js +35 -14
- package/dist/archive-zip-preflight.d.ts.map +1 -1
- package/dist/archive-zip-preflight.js +3 -2
- package/dist/archive.d.ts.map +1 -1
- package/dist/archive.js +9 -4
- package/dist/darwin-acl.d.ts +4 -0
- package/dist/darwin-acl.d.ts.map +1 -0
- package/dist/darwin-acl.js +24 -0
- package/dist/deny-mutations.d.ts.map +1 -1
- package/dist/deny-mutations.js +8 -2
- package/dist/directory-durability.d.ts.map +1 -1
- package/dist/directory-durability.js +67 -23
- package/dist/directory-entry-path.d.ts +3 -0
- package/dist/directory-entry-path.d.ts.map +1 -0
- package/dist/directory-entry-path.js +21 -0
- package/dist/directory-guard.d.ts +17 -1
- package/dist/directory-guard.d.ts.map +1 -1
- package/dist/directory-guard.js +134 -48
- package/dist/directory-mode-node.d.ts +12 -0
- package/dist/directory-mode-node.d.ts.map +1 -1
- package/dist/directory-mode-node.js +102 -4
- package/dist/effective-uid.d.ts +2 -0
- package/dist/effective-uid.d.ts.map +1 -0
- package/dist/effective-uid.js +25 -0
- package/dist/file-handle-transfer.d.ts.map +1 -1
- package/dist/file-handle-transfer.js +98 -27
- package/dist/file-hash.d.ts.map +1 -1
- package/dist/file-hash.js +3 -0
- package/dist/file-lock-sync.d.ts.map +1 -1
- package/dist/file-lock-sync.js +36 -6
- package/dist/file-lock.d.ts.map +1 -1
- package/dist/file-lock.js +29 -9
- package/dist/file-observation.d.ts +1 -1
- package/dist/file-observation.d.ts.map +1 -1
- package/dist/file-store-boundary.d.ts +6 -2
- package/dist/file-store-boundary.d.ts.map +1 -1
- package/dist/file-store-boundary.js +20 -65
- package/dist/file-store-copy-source.d.ts +5 -0
- package/dist/file-store-copy-source.d.ts.map +1 -0
- package/dist/file-store-copy-source.js +31 -0
- package/dist/file-store-path.d.ts.map +1 -1
- package/dist/file-store-path.js +4 -1
- package/dist/file-store-sync-directory.d.ts +16 -0
- package/dist/file-store-sync-directory.d.ts.map +1 -0
- package/dist/file-store-sync-directory.js +349 -0
- package/dist/file-store.d.ts.map +1 -1
- package/dist/file-store.js +11 -28
- package/dist/filename.d.ts.map +1 -1
- package/dist/filename.js +65 -20
- package/dist/fs.d.ts.map +1 -1
- package/dist/fs.js +3 -2
- package/dist/guarded-mkdir.d.ts +8 -0
- package/dist/guarded-mkdir.d.ts.map +1 -1
- package/dist/guarded-mkdir.js +176 -27
- package/dist/guest.d.ts.map +1 -1
- package/dist/guest.js +4 -1
- package/dist/home-dir.d.ts.map +1 -1
- package/dist/home-dir.js +73 -10
- package/dist/install-path.d.ts.map +1 -1
- package/dist/install-path.js +54 -19
- package/dist/json-durable-queue-ownership.d.ts +6 -0
- package/dist/json-durable-queue-ownership.d.ts.map +1 -1
- package/dist/json-durable-queue-ownership.js +89 -42
- package/dist/json-durable-queue-paths.d.ts +11 -0
- package/dist/json-durable-queue-paths.d.ts.map +1 -0
- package/dist/json-durable-queue-paths.js +42 -0
- package/dist/json-durable-queue-read.d.ts.map +1 -1
- package/dist/json-durable-queue-read.js +2 -0
- package/dist/json-durable-queue.d.ts.map +1 -1
- package/dist/json-durable-queue.js +50 -58
- package/dist/json-store.d.ts.map +1 -1
- package/dist/json-store.js +5 -1
- package/dist/json.d.ts.map +1 -1
- package/dist/json.js +54 -22
- package/dist/local-file-access.d.ts.map +1 -1
- package/dist/local-file-access.js +4 -0
- package/dist/local-file-descriptor.d.ts +17 -0
- package/dist/local-file-descriptor.d.ts.map +1 -0
- package/dist/local-file-descriptor.js +84 -0
- package/dist/local-roots.d.ts.map +1 -1
- package/dist/local-roots.js +35 -7
- package/dist/move-path-cleanup.d.ts +2 -0
- package/dist/move-path-cleanup.d.ts.map +1 -1
- package/dist/move-path-cleanup.js +44 -18
- package/dist/move-path.d.ts.map +1 -1
- package/dist/move-path.js +31 -6
- package/dist/native-binding.d.ts +14 -0
- package/dist/native-binding.d.ts.map +1 -1
- package/dist/native-directory-observation.d.ts +17 -0
- package/dist/native-directory-observation.d.ts.map +1 -0
- package/dist/native-directory-observation.js +37 -0
- package/dist/native-parent-admission.d.ts +31 -0
- package/dist/native-parent-admission.d.ts.map +1 -0
- package/dist/native-parent-admission.js +124 -0
- package/dist/native-pinned-write-windows.d.ts +0 -1
- package/dist/native-pinned-write-windows.d.ts.map +1 -1
- package/dist/native-pinned-write-windows.js +0 -3
- package/dist/native-pinned-write.d.ts.map +1 -1
- package/dist/native-pinned-write.js +309 -40
- package/dist/output.d.ts.map +1 -1
- package/dist/output.js +15 -5
- package/dist/overwrite-file-handle.d.ts.map +1 -1
- package/dist/overwrite-file-handle.js +5 -1
- package/dist/owner-dacl.d.ts.map +1 -1
- package/dist/owner-dacl.js +2 -0
- package/dist/path-policy.d.ts.map +1 -1
- package/dist/path-policy.js +7 -2
- package/dist/path-prefix.d.ts +7 -0
- package/dist/path-prefix.d.ts.map +1 -0
- package/dist/path-prefix.js +82 -0
- package/dist/path-scope-lexical.d.ts.map +1 -1
- package/dist/path-scope-lexical.js +18 -8
- package/dist/path-segment-route.d.ts +7 -0
- package/dist/path-segment-route.d.ts.map +1 -0
- package/dist/path-segment-route.js +24 -0
- package/dist/path-suffix-aliases.d.ts +10 -0
- package/dist/path-suffix-aliases.d.ts.map +1 -0
- package/dist/path-suffix-aliases.js +386 -0
- package/dist/path.d.ts.map +1 -1
- package/dist/path.js +16 -5
- package/dist/permissions-windows.d.ts.map +1 -1
- package/dist/permissions-windows.js +14 -3
- package/dist/permissions.d.ts.map +1 -1
- package/dist/permissions.js +37 -8
- package/dist/pinned-mutation-admission.d.ts +25 -0
- package/dist/pinned-mutation-admission.d.ts.map +1 -0
- package/dist/pinned-mutation-admission.js +425 -0
- package/dist/pinned-mutation-observation.d.ts +34 -0
- package/dist/pinned-mutation-observation.d.ts.map +1 -0
- package/dist/pinned-mutation-observation.js +142 -0
- package/dist/pinned-mutation-shared-route.d.ts +24 -0
- package/dist/pinned-mutation-shared-route.d.ts.map +1 -0
- package/dist/pinned-mutation-shared-route.js +70 -0
- package/dist/pinned-open.d.ts +6 -0
- package/dist/pinned-open.d.ts.map +1 -1
- package/dist/pinned-open.js +28 -10
- package/dist/pinned-write-types.d.ts +75 -0
- package/dist/pinned-write-types.d.ts.map +1 -0
- package/dist/pinned-write-types.js +1 -0
- package/dist/pinned-write.d.ts +7 -33
- package/dist/pinned-write.d.ts.map +1 -1
- package/dist/pinned-write.js +151 -17
- package/dist/private-directory.d.ts.map +1 -1
- package/dist/private-directory.js +2 -0
- package/dist/private-producer-handoff.d.ts +16 -0
- package/dist/private-producer-handoff.d.ts.map +1 -0
- package/dist/private-producer-handoff.js +272 -0
- package/dist/private-temp-workspace.d.ts +2 -39
- package/dist/private-temp-workspace.d.ts.map +1 -1
- package/dist/private-temp-workspace.js +183 -77
- package/dist/publish-file.d.ts.map +1 -1
- package/dist/publish-file.js +33 -29
- package/dist/regular-file.d.ts.map +1 -1
- package/dist/regular-file.js +56 -45
- package/dist/replace-directory.d.ts.map +1 -1
- package/dist/replace-directory.js +12 -5
- package/dist/replace-file-temp-owner.d.ts +1 -0
- package/dist/replace-file-temp-owner.d.ts.map +1 -1
- package/dist/replace-file-temp-owner.js +12 -1
- package/dist/replace-file.d.ts.map +1 -1
- package/dist/replace-file.js +24 -24
- package/dist/root-boundary.d.ts +4 -0
- package/dist/root-boundary.d.ts.map +1 -1
- package/dist/root-boundary.js +6 -1
- package/dist/root-context.d.ts +12 -1
- package/dist/root-context.d.ts.map +1 -1
- package/dist/root-context.js +57 -11
- package/dist/root-directory-creation.d.ts +13 -0
- package/dist/root-directory-creation.d.ts.map +1 -0
- package/dist/root-directory-creation.js +212 -0
- package/dist/root-directory-list.d.ts +16 -4
- package/dist/root-directory-list.d.ts.map +1 -1
- package/dist/root-directory-list.js +180 -39
- package/dist/root-directory.d.ts +23 -0
- package/dist/root-directory.d.ts.map +1 -0
- package/dist/root-directory.js +141 -0
- package/dist/root-errors.d.ts.map +1 -1
- package/dist/root-errors.js +12 -1
- package/dist/root-file-final-admission.d.ts +21 -0
- package/dist/root-file-final-admission.d.ts.map +1 -0
- package/dist/root-file-final-admission.js +83 -0
- package/dist/root-file.d.ts.map +1 -1
- package/dist/root-file.js +103 -24
- package/dist/root-impl.d.ts +1 -0
- package/dist/root-impl.d.ts.map +1 -1
- package/dist/root-impl.js +289 -317
- package/dist/root-move-noreplace.d.ts +14 -0
- package/dist/root-move-noreplace.d.ts.map +1 -0
- package/dist/root-move-noreplace.js +202 -0
- package/dist/root-observed-path.d.ts +9 -0
- package/dist/root-observed-path.d.ts.map +1 -0
- package/dist/root-observed-path.js +95 -0
- package/dist/root-path-errors.d.ts +12 -0
- package/dist/root-path-errors.d.ts.map +1 -0
- package/dist/root-path-errors.js +13 -0
- package/dist/root-path-existing.d.ts.map +1 -1
- package/dist/root-path-existing.js +53 -20
- package/dist/root-path-observation.d.ts +63 -0
- package/dist/root-path-observation.d.ts.map +1 -0
- package/dist/root-path-observation.js +180 -0
- package/dist/root-path-stat.d.ts +5 -0
- package/dist/root-path-stat.d.ts.map +1 -0
- package/dist/root-path-stat.js +101 -0
- package/dist/root-path-symlink.d.ts.map +1 -1
- package/dist/root-path-symlink.js +23 -4
- package/dist/root-path.d.ts +11 -0
- package/dist/root-path.d.ts.map +1 -1
- package/dist/root-path.js +215 -53
- package/dist/root-paths-lexical.d.ts +9 -0
- package/dist/root-paths-lexical.d.ts.map +1 -0
- package/dist/root-paths-lexical.js +22 -0
- package/dist/root-paths.d.ts +3 -25
- package/dist/root-paths.d.ts.map +1 -1
- package/dist/root-paths.js +77 -154
- package/dist/root-read-admission.d.ts +26 -0
- package/dist/root-read-admission.d.ts.map +1 -0
- package/dist/root-read-admission.js +94 -0
- package/dist/root-remove-identity.d.ts +15 -0
- package/dist/root-remove-identity.d.ts.map +1 -0
- package/dist/root-remove-identity.js +89 -0
- package/dist/root-remove-receipt.d.ts +17 -0
- package/dist/root-remove-receipt.d.ts.map +1 -0
- package/dist/root-remove-receipt.js +37 -0
- package/dist/root-remove.d.ts +2 -1
- package/dist/root-remove.d.ts.map +1 -1
- package/dist/root-remove.js +172 -10
- package/dist/root-write-admission.d.ts +68 -0
- package/dist/root-write-admission.d.ts.map +1 -0
- package/dist/root-write-admission.js +322 -0
- package/dist/root-write-compatibility.d.ts +13 -0
- package/dist/root-write-compatibility.d.ts.map +1 -0
- package/dist/root-write-compatibility.js +74 -0
- package/dist/root-write-complete-parent.d.ts +42 -0
- package/dist/root-write-complete-parent.d.ts.map +1 -0
- package/dist/root-write-complete-parent.js +195 -0
- package/dist/root-write-publication.d.ts +24 -0
- package/dist/root-write-publication.d.ts.map +1 -0
- package/dist/root-write-publication.js +85 -0
- package/dist/root-write-verification.d.ts.map +1 -1
- package/dist/root-write-verification.js +6 -4
- package/dist/secret-file.d.ts.map +1 -1
- package/dist/secret-file.js +62 -24
- package/dist/secret-read-async.d.ts.map +1 -1
- package/dist/secret-read-async.js +18 -13
- package/dist/secret-read-policy.d.ts.map +1 -1
- package/dist/secret-read-policy.js +5 -1
- package/dist/secure-file.d.ts.map +1 -1
- package/dist/secure-file.js +92 -7
- package/dist/secure-temp-dir.d.ts +6 -3
- package/dist/secure-temp-dir.d.ts.map +1 -1
- package/dist/secure-temp-dir.js +121 -101
- package/dist/secure-temp-repair.d.ts +35 -0
- package/dist/secure-temp-repair.d.ts.map +1 -0
- package/dist/secure-temp-repair.js +106 -0
- package/dist/sibling-staged-file.d.ts +3 -2
- package/dist/sibling-staged-file.d.ts.map +1 -1
- package/dist/sibling-staged-file.js +179 -55
- package/dist/sibling-temp.d.ts.map +1 -1
- package/dist/sibling-temp.js +27 -13
- package/dist/sidecar-lock-acquire.d.ts.map +1 -1
- package/dist/sidecar-lock-acquire.js +44 -14
- package/dist/sidecar-lock-root.d.ts.map +1 -1
- package/dist/sidecar-lock-root.js +4 -2
- package/dist/staged-directory.d.ts +14 -5
- package/dist/staged-directory.d.ts.map +1 -1
- package/dist/staged-directory.js +54 -3
- package/dist/standalone-publication-path.d.ts +2 -0
- package/dist/standalone-publication-path.d.ts.map +1 -0
- package/dist/standalone-publication-path.js +6 -0
- package/dist/stat-observation.d.ts +11 -0
- package/dist/stat-observation.d.ts.map +1 -0
- package/dist/stat-observation.js +64 -0
- package/dist/strict-file-identity.d.ts.map +1 -1
- package/dist/strict-file-identity.js +39 -2
- package/dist/symlink-parents.d.ts.map +1 -1
- package/dist/symlink-parents.js +7 -2
- package/dist/temp-target.d.ts +2 -0
- package/dist/temp-target.d.ts.map +1 -1
- package/dist/temp-target.js +130 -3
- package/dist/temp-workspace-admission.d.ts +22 -0
- package/dist/temp-workspace-admission.d.ts.map +1 -0
- package/dist/temp-workspace-admission.js +374 -0
- package/dist/temp-workspace-child-admission.d.ts +13 -0
- package/dist/temp-workspace-child-admission.d.ts.map +1 -0
- package/dist/temp-workspace-child-admission.js +95 -0
- package/dist/temp-workspace-descriptor.d.ts +48 -0
- package/dist/temp-workspace-descriptor.d.ts.map +1 -0
- package/dist/temp-workspace-descriptor.js +363 -0
- package/dist/temp-workspace-identity.d.ts +15 -0
- package/dist/temp-workspace-identity.d.ts.map +1 -0
- package/dist/temp-workspace-identity.js +41 -0
- package/dist/temp-workspace-owner.d.ts +7 -6
- package/dist/temp-workspace-owner.d.ts.map +1 -1
- package/dist/temp-workspace-owner.js +121 -61
- package/dist/temp-workspace-permissions.d.ts +4 -0
- package/dist/temp-workspace-permissions.d.ts.map +1 -0
- package/dist/temp-workspace-permissions.js +32 -0
- package/dist/temp-workspace-types.d.ts +40 -0
- package/dist/temp-workspace-types.d.ts.map +1 -0
- package/dist/temp-workspace-types.js +1 -0
- package/dist/temp.d.ts +1 -1
- package/dist/temp.d.ts.map +1 -1
- package/dist/temp.js +1 -1
- package/dist/test-hooks.d.ts +7 -0
- package/dist/test-hooks.d.ts.map +1 -1
- package/dist/text-atomic.d.ts.map +1 -1
- package/dist/text-atomic.js +3 -1
- package/dist/trash.d.ts.map +1 -1
- package/dist/trash.js +54 -8
- package/dist/walk.d.ts.map +1 -1
- package/dist/walk.js +9 -6
- package/dist/windows-owner.d.ts.map +1 -1
- package/dist/windows-owner.js +5 -0
- package/dist/windows-path-alias.d.ts +39 -0
- package/dist/windows-path-alias.d.ts.map +1 -0
- package/dist/windows-path-alias.js +153 -0
- package/docs/advanced.md +25 -0
- package/docs/archive.md +23 -2
- package/docs/atomic.md +27 -3
- package/docs/copy.md +3 -0
- package/docs/durability.md +14 -0
- package/docs/errors.md +14 -6
- package/docs/file-store.md +24 -3
- package/docs/filename.md +14 -7
- package/docs/install-path.md +2 -2
- package/docs/install.md +8 -7
- package/docs/json-store.md +5 -1
- package/docs/json.md +11 -0
- package/docs/mutation-policy-proof.md +65 -0
- package/docs/native-helper.md +26 -9
- package/docs/native.md +32 -8
- package/docs/output.md +33 -11
- package/docs/path-prefix.md +64 -0
- package/docs/path-suffix-aliases.md +159 -0
- package/docs/path.md +11 -0
- package/docs/private-file-store.md +14 -0
- package/docs/public-api.md +9 -0
- package/docs/quickstart.md +1 -1
- package/docs/reading.md +8 -1
- package/docs/root.md +18 -3
- package/docs/secret-file.md +3 -0
- package/docs/secure-file.md +6 -2
- package/docs/security-model.md +75 -8
- package/docs/sidecar-lock.md +28 -1
- package/docs/store.md +5 -1
- package/docs/temp.md +260 -36
- package/docs/test-hooks.md +14 -0
- package/docs/writing.md +38 -8
- package/package.json +10 -10
package/dist/root-context.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import fs from "node:fs";
|
|
1
|
+
import fs, {} from "node:fs";
|
|
2
2
|
import os from "node:os";
|
|
3
3
|
import path from "node:path";
|
|
4
|
-
import {
|
|
4
|
+
import { extendDirectoryObservationGuard, inspectDirectoryIdentitySync, inspectDirectoryObservationSync, } from "./directory-guard.js";
|
|
5
5
|
import { FsSafeError } from "./errors.js";
|
|
6
6
|
import { sameFileIdentity } from "./file-identity.js";
|
|
7
7
|
import { assertNoNulPathInput, assertNoUnsafeDeviceReadPath, hasNodeErrorCode, isNotFoundPathError, isPathInside, } from "./path.js";
|
|
@@ -11,9 +11,14 @@ import { outsideWorkspaceError, rootPathChangedError } from "./root-errors.js";
|
|
|
11
11
|
import { isDriveRelativePath } from "./safe-path-segment.js";
|
|
12
12
|
import { realpathSync } from "./realpath.js";
|
|
13
13
|
import { inspectFileIdentity } from "./strict-file-identity.js";
|
|
14
|
+
import { assertNoWindowsPathAlias, pathForWindowsFilesystem, resolvePathFromBasePreservingWindowsRoot, resolvePathPreservingWindowsRoot, } from "./windows-path-alias.js";
|
|
15
|
+
function hasExactRootIdentity(identity) {
|
|
16
|
+
return typeof identity.dev === "bigint" && typeof identity.ino === "bigint";
|
|
17
|
+
}
|
|
14
18
|
export const ensureTrailingSep = (value) => value.endsWith(path.sep) ? value : value + path.sep;
|
|
15
19
|
export function assertValidRootRelativePath(relativePath) {
|
|
16
20
|
assertNoNulPathInput(relativePath, "relative path contains a NUL byte");
|
|
21
|
+
assertNoWindowsPathAlias(relativePath, "filesystem", "relative path uses a Windows filesystem namespace alias");
|
|
17
22
|
}
|
|
18
23
|
export function assertValidRootDestinationPath(relativePath) {
|
|
19
24
|
assertValidRootRelativePath(relativePath);
|
|
@@ -27,29 +32,42 @@ const WINDOWS_PARENT_COMPONENT = /(?:^|[\\/])\.\.(?:[\\/]|$)/;
|
|
|
27
32
|
export async function expandRelativePathWithHome(relativePath) {
|
|
28
33
|
const homeOnly = relativePath === "~";
|
|
29
34
|
const homePrefix = relativePath.startsWith("~/") || (path.sep === "\\" && relativePath.startsWith("~\\"));
|
|
30
|
-
if (!homeOnly && !homePrefix)
|
|
35
|
+
if (!homeOnly && !homePrefix) {
|
|
36
|
+
assertNoWindowsPathAlias(relativePath, "filesystem", "relative path uses a Windows filesystem namespace alias");
|
|
31
37
|
return relativePath;
|
|
38
|
+
}
|
|
32
39
|
const rawHome = process.env.HOME || process.env.USERPROFILE || os.homedir();
|
|
40
|
+
assertNoWindowsPathAlias(rawHome, "filesystem", "home path uses a Windows filesystem namespace alias");
|
|
33
41
|
if (cachedHomePath?.raw !== rawHome) {
|
|
34
42
|
let realHome = rawHome;
|
|
35
43
|
try {
|
|
36
|
-
realHome = realpathSync.native(rawHome);
|
|
44
|
+
realHome = realpathSync.native(pathForWindowsFilesystem(rawHome));
|
|
37
45
|
}
|
|
38
46
|
catch {
|
|
39
47
|
// If the home dir cannot be canonicalized, keep lexical expansion behavior.
|
|
40
48
|
}
|
|
41
49
|
cachedHomePath = { raw: rawHome, real: realHome };
|
|
42
50
|
}
|
|
43
|
-
|
|
51
|
+
if (homeOnly) {
|
|
52
|
+
assertNoWindowsPathAlias(cachedHomePath.real, "filesystem", "home path uses a Windows filesystem namespace alias");
|
|
53
|
+
return cachedHomePath.real;
|
|
54
|
+
}
|
|
55
|
+
const expanded = `${ensureTrailingSep(cachedHomePath.real)}${relativePath.slice(2)}`;
|
|
56
|
+
assertNoWindowsPathAlias(expanded, "filesystem", "expanded path uses a Windows filesystem namespace alias");
|
|
57
|
+
return expanded;
|
|
44
58
|
}
|
|
45
59
|
export async function resolveRootContext(rootDir) {
|
|
46
60
|
assertNoNulPathInput(rootDir, "root dir contains a NUL byte");
|
|
47
|
-
|
|
61
|
+
assertNoWindowsPathAlias(rootDir, "filesystem", "root dir uses a Windows filesystem namespace alias");
|
|
62
|
+
const lexicalRoot = resolvePathPreservingWindowsRoot(rootDir);
|
|
63
|
+
assertNoWindowsPathAlias(lexicalRoot, "filesystem", "root dir uses a Windows filesystem namespace alias");
|
|
48
64
|
let rootReal;
|
|
65
|
+
let rootStat;
|
|
49
66
|
let rootIdentity;
|
|
50
67
|
try {
|
|
51
|
-
rootReal = realpathSync.native(rootDir);
|
|
52
|
-
|
|
68
|
+
rootReal = realpathSync.native(pathForWindowsFilesystem(rootDir));
|
|
69
|
+
assertNoWindowsPathAlias(rootReal, "filesystem", "canonical root path uses a Windows filesystem namespace alias");
|
|
70
|
+
rootStat = await inspectFileIdentity(() => {
|
|
53
71
|
const stat = fs.statSync(rootReal, { bigint: true });
|
|
54
72
|
if (!stat.isDirectory())
|
|
55
73
|
throw new FsSafeError("invalid-path", "root dir is not a directory");
|
|
@@ -68,6 +86,7 @@ export async function resolveRootContext(rootDir) {
|
|
|
68
86
|
}
|
|
69
87
|
return {
|
|
70
88
|
rootDir: lexicalRoot,
|
|
89
|
+
rootGuard: { dir: rootReal, realPath: rootReal, stat: rootStat },
|
|
71
90
|
rootIdentity,
|
|
72
91
|
rootReal,
|
|
73
92
|
rootWithSep: ensureTrailingSep(rootReal),
|
|
@@ -102,11 +121,12 @@ export function rootRelativeReadPath(root, filePath) {
|
|
|
102
121
|
}
|
|
103
122
|
return raw;
|
|
104
123
|
}
|
|
105
|
-
export
|
|
124
|
+
export function assertRootIdentityCurrentSync(root, observe) {
|
|
106
125
|
let current;
|
|
107
126
|
try {
|
|
108
127
|
if (typeof root.rootIdentity.dev === "bigint" && typeof root.rootIdentity.ino === "bigint") {
|
|
109
|
-
|
|
128
|
+
const stat = inspectDirectoryIdentitySync(root.rootReal, { dev: root.rootIdentity.dev, ino: root.rootIdentity.ino });
|
|
129
|
+
observe?.(stat);
|
|
110
130
|
return;
|
|
111
131
|
}
|
|
112
132
|
current = fs.lstatSync(root.rootReal);
|
|
@@ -120,11 +140,36 @@ export async function assertRootIdentityCurrent(root) {
|
|
|
120
140
|
throw rootPathChangedError();
|
|
121
141
|
}
|
|
122
142
|
}
|
|
143
|
+
export async function assertRootIdentityCurrent(root, observe) {
|
|
144
|
+
assertRootIdentityCurrentSync(root, observe);
|
|
145
|
+
}
|
|
146
|
+
/**
|
|
147
|
+
* Observe the current Root with an exact, operation-local receipt.
|
|
148
|
+
*
|
|
149
|
+
* This is deliberately separate from {@link assertRootIdentityCurrent}: callers
|
|
150
|
+
* must not retain the returned guard beyond the operation that requested it.
|
|
151
|
+
*/
|
|
152
|
+
export async function createRootObservationGuard(root) {
|
|
153
|
+
const rootIdentity = root.rootIdentity;
|
|
154
|
+
if (!hasExactRootIdentity(rootIdentity)) {
|
|
155
|
+
await assertRootIdentityCurrent(root);
|
|
156
|
+
return undefined;
|
|
157
|
+
}
|
|
158
|
+
try {
|
|
159
|
+
const observed = await inspectDirectoryObservationSync(root.rootReal, rootIdentity);
|
|
160
|
+
return extendDirectoryObservationGuard(observed, root.rootReal, root.rootReal);
|
|
161
|
+
}
|
|
162
|
+
catch (error) {
|
|
163
|
+
throw rootPathChangedError(error instanceof Error ? error : undefined);
|
|
164
|
+
}
|
|
165
|
+
}
|
|
123
166
|
export async function resolvePathInRoot(root, relativePath, options) {
|
|
124
167
|
assertValidRootRelativePath(relativePath);
|
|
125
168
|
await assertRootIdentityCurrent(root);
|
|
126
169
|
const expanded = await expandRelativePathWithHome(relativePath);
|
|
127
|
-
|
|
170
|
+
assertNoWindowsPathAlias(expanded, "filesystem", "expanded path uses a Windows filesystem namespace alias");
|
|
171
|
+
let resolved = resolvePathFromBasePreservingWindowsRoot(root.rootWithSep, expanded);
|
|
172
|
+
assertNoWindowsPathAlias(resolved, "filesystem", "resolved path uses a Windows filesystem namespace alias");
|
|
128
173
|
if (!options?.resolveCanonical && !isPathInside(root.rootWithSep, resolved)) {
|
|
129
174
|
throw outsideWorkspaceError();
|
|
130
175
|
}
|
|
@@ -134,6 +179,7 @@ export async function resolvePathInRoot(root, relativePath, options) {
|
|
|
134
179
|
const rawAbsolutePath = path.isAbsolute(expanded)
|
|
135
180
|
? expanded
|
|
136
181
|
: `${root.rootWithSep}${expanded}`;
|
|
182
|
+
assertNoWindowsPathAlias(rawAbsolutePath, "filesystem", "resolved path uses a Windows filesystem namespace alias");
|
|
137
183
|
try {
|
|
138
184
|
const resolution = {
|
|
139
185
|
absolutePath: rawAbsolutePath,
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { PinnedWriteMutationAdmission } from "./pinned-write.js";
|
|
2
|
+
import type { RootContext } from "./root-context.js";
|
|
3
|
+
/**
|
|
4
|
+
* Complete the common Root.mkdir case with one exact existing parent. This is
|
|
5
|
+
* optional evidence: every uncertain probe returns to the ordered root walk.
|
|
6
|
+
*/
|
|
7
|
+
export declare function tryMkdirAtExactParent(root: RootContext, targetPath: string, mutationAdmission: PinnedWriteMutationAdmission): Promise<boolean>;
|
|
8
|
+
export declare function prepareRootWriteTarget(root: RootContext, targetPath: string, assertBeforeMutation?: () => void, mutationAdmission?: PinnedWriteMutationAdmission): Promise<string>;
|
|
9
|
+
export declare function mkdirPathFallback(root: RootContext, resolved: {
|
|
10
|
+
rootReal: string;
|
|
11
|
+
resolved: string;
|
|
12
|
+
}, assertBeforeMutation?: () => void, rejectSymlinks?: boolean, mutationAdmission?: PinnedWriteMutationAdmission): Promise<void>;
|
|
13
|
+
//# sourceMappingURL=root-directory-creation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"root-directory-creation.d.ts","sourceRoot":"","sources":["../src/root-directory-creation.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,mBAAmB,CAAC;AAEtE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAoDrD;;;GAGG;AACH,wBAAsB,qBAAqB,CACzC,IAAI,EAAE,WAAW,EACjB,UAAU,EAAE,MAAM,EAClB,iBAAiB,EAAE,4BAA4B,GAC9C,OAAO,CAAC,OAAO,CAAC,CAoGlB;AAED,wBAAsB,sBAAsB,CAC1C,IAAI,EAAE,WAAW,EACjB,UAAU,EAAE,MAAM,EAClB,oBAAoB,CAAC,EAAE,MAAM,IAAI,EACjC,iBAAiB,CAAC,EAAE,4BAA4B,GAC/C,OAAO,CAAC,MAAM,CAAC,CA2BjB;AAED,wBAAsB,iBAAiB,CACrC,IAAI,EAAE,WAAW,EACjB,QAAQ,EAAE;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,EAChD,oBAAoB,CAAC,EAAE,MAAM,IAAI,EACjC,cAAc,UAAQ,EACtB,iBAAiB,CAAC,EAAE,4BAA4B,GAC/C,OAAO,CAAC,IAAI,CAAC,CAuBf"}
|
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
import fsSync, {} from "node:fs";
|
|
2
|
+
import fs from "node:fs/promises";
|
|
3
|
+
import path from "node:path";
|
|
4
|
+
import { assertAsyncDirectoryGuard, assertDirectoryIdentitySync, assertSyncDirectoryGuard, createAsyncDirectoryGuard, inspectDirectoryIdentitySync, } from "./directory-guard.js";
|
|
5
|
+
import { FsSafeError } from "./errors.js";
|
|
6
|
+
import { mkdirPathComponentsWithGuards } from "./guarded-mkdir.js";
|
|
7
|
+
import { hasNodeErrorCode } from "./path.js";
|
|
8
|
+
import { checkedMutationDirectory, } from "./pinned-mutation-observation.js";
|
|
9
|
+
import { admitPathInsideRoot } from "./root-boundary.js";
|
|
10
|
+
import { assertFinalSymlinkRejected } from "./root-symlink-policy.js";
|
|
11
|
+
import { getFsSafeTestHooks } from "./test-hooks.js";
|
|
12
|
+
function mutationWalkOptions(mutationAdmission, operationTarget, assertBeforeMutation) {
|
|
13
|
+
const session = assertBeforeMutation === undefined
|
|
14
|
+
? mutationAdmission.beginSharedParentWalk?.()
|
|
15
|
+
: undefined;
|
|
16
|
+
return {
|
|
17
|
+
dispose: () => session?.dispose(),
|
|
18
|
+
options: {
|
|
19
|
+
rejectSymlinks: mutationAdmission.rejectParentSymlinks,
|
|
20
|
+
revalidateParentAfterBeforeComponent: true,
|
|
21
|
+
retainedTargetPath: session?.retainedTargetPath,
|
|
22
|
+
synchronousAuthorizationIncludesFence: session !== undefined,
|
|
23
|
+
afterCreateComponent: session?.advanceCreatedDirectory,
|
|
24
|
+
beforeCreateComponent: (componentPath, prospectiveDirectory, retainedTargetPath, parent) => {
|
|
25
|
+
const targetPath = retainedTargetPath ?? operationTarget(prospectiveDirectory);
|
|
26
|
+
const request = Object.freeze({
|
|
27
|
+
targetPath,
|
|
28
|
+
mutationPath: componentPath,
|
|
29
|
+
phase: "parent-create",
|
|
30
|
+
});
|
|
31
|
+
return session?.tryAuthorizeAtParent(request, parent) ??
|
|
32
|
+
(session?.authorize(request) ?? mutationAdmission.authorize(request));
|
|
33
|
+
},
|
|
34
|
+
beforeUseComponent: async (_componentPath, prospectiveDirectory, retainedTargetPath) => {
|
|
35
|
+
const targetPath = retainedTargetPath ?? operationTarget(prospectiveDirectory);
|
|
36
|
+
const request = Object.freeze({
|
|
37
|
+
targetPath,
|
|
38
|
+
mutationPath: targetPath,
|
|
39
|
+
phase: "parent",
|
|
40
|
+
});
|
|
41
|
+
await (session?.authorize(request) ?? mutationAdmission.authorize(request));
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* Complete the common Root.mkdir case with one exact existing parent. This is
|
|
48
|
+
* optional evidence: every uncertain probe returns to the ordered root walk.
|
|
49
|
+
*/
|
|
50
|
+
export async function tryMkdirAtExactParent(root, targetPath, mutationAdmission) {
|
|
51
|
+
if (getFsSafeTestHooks()?.beforeRootFallbackMutation)
|
|
52
|
+
return false;
|
|
53
|
+
if (typeof root.rootIdentity.dev !== "bigint" ||
|
|
54
|
+
typeof root.rootIdentity.ino !== "bigint" ||
|
|
55
|
+
root.rootIdentity.dev === 0n || root.rootIdentity.ino === 0n)
|
|
56
|
+
return false;
|
|
57
|
+
const rootIdentity = Object.freeze({
|
|
58
|
+
dev: root.rootIdentity.dev,
|
|
59
|
+
ino: root.rootIdentity.ino,
|
|
60
|
+
});
|
|
61
|
+
const session = mutationAdmission.beginSharedParentWalk?.();
|
|
62
|
+
if (!session)
|
|
63
|
+
return false;
|
|
64
|
+
try {
|
|
65
|
+
if (path.resolve(session.retainedTargetPath) !== path.resolve(targetPath))
|
|
66
|
+
return false;
|
|
67
|
+
const parentPath = path.dirname(targetPath);
|
|
68
|
+
let parentGuard;
|
|
69
|
+
try {
|
|
70
|
+
parentGuard = await createAsyncDirectoryGuard(parentPath, { bigint: true });
|
|
71
|
+
}
|
|
72
|
+
catch {
|
|
73
|
+
return false;
|
|
74
|
+
}
|
|
75
|
+
try {
|
|
76
|
+
fsSync.lstatSync(targetPath, { bigint: true });
|
|
77
|
+
return false;
|
|
78
|
+
}
|
|
79
|
+
catch (error) {
|
|
80
|
+
if (!hasNodeErrorCode(error, "ENOENT"))
|
|
81
|
+
return false;
|
|
82
|
+
}
|
|
83
|
+
const admittedParent = admitPathInsideRoot({
|
|
84
|
+
rootPath: root.rootReal,
|
|
85
|
+
candidatePath: parentPath,
|
|
86
|
+
rootIdentity,
|
|
87
|
+
});
|
|
88
|
+
if (admittedParent?.admission !== "exact" || admittedParent.path !== parentPath ||
|
|
89
|
+
parentGuard.realPath !== parentPath)
|
|
90
|
+
return false;
|
|
91
|
+
await session.authorize(Object.freeze({
|
|
92
|
+
targetPath,
|
|
93
|
+
mutationPath: targetPath,
|
|
94
|
+
phase: "parent",
|
|
95
|
+
}));
|
|
96
|
+
await assertAsyncDirectoryGuard(parentGuard);
|
|
97
|
+
try {
|
|
98
|
+
fsSync.lstatSync(targetPath, { bigint: true });
|
|
99
|
+
return false;
|
|
100
|
+
}
|
|
101
|
+
catch (error) {
|
|
102
|
+
if (!hasNodeErrorCode(error, "ENOENT"))
|
|
103
|
+
return false;
|
|
104
|
+
}
|
|
105
|
+
assertSyncDirectoryGuard(parentGuard);
|
|
106
|
+
const createAdmission = session.tryAuthorizeAtParent(Object.freeze({
|
|
107
|
+
targetPath,
|
|
108
|
+
mutationPath: targetPath,
|
|
109
|
+
phase: "parent-create",
|
|
110
|
+
}), checkedMutationDirectory(parentPath, parentGuard.realPath, parentGuard.stat));
|
|
111
|
+
if (!createAdmission)
|
|
112
|
+
return false;
|
|
113
|
+
try {
|
|
114
|
+
await fs.mkdir(targetPath);
|
|
115
|
+
}
|
|
116
|
+
catch (error) {
|
|
117
|
+
if (hasNodeErrorCode(error, "EEXIST"))
|
|
118
|
+
return false;
|
|
119
|
+
throw error;
|
|
120
|
+
}
|
|
121
|
+
const observeCreated = async () => {
|
|
122
|
+
const childGuard = await createAsyncDirectoryGuard(targetPath, { bigint: true });
|
|
123
|
+
const parentAfter = inspectDirectoryIdentitySync(parentPath, parentGuard.stat);
|
|
124
|
+
assertDirectoryIdentitySync(root.rootReal, rootIdentity);
|
|
125
|
+
const admittedChild = admitPathInsideRoot({
|
|
126
|
+
rootPath: root.rootReal,
|
|
127
|
+
candidatePath: childGuard.realPath,
|
|
128
|
+
rootIdentity,
|
|
129
|
+
});
|
|
130
|
+
if (childGuard.realPath !== targetPath || childGuard.dir !== targetPath ||
|
|
131
|
+
admittedChild?.admission !== "exact" || admittedChild.path !== targetPath) {
|
|
132
|
+
throw new FsSafeError("path-mismatch", "created directory changed during operation");
|
|
133
|
+
}
|
|
134
|
+
return { childGuard, parentAfter };
|
|
135
|
+
};
|
|
136
|
+
try {
|
|
137
|
+
const created = await observeCreated();
|
|
138
|
+
if (session.advanceCreatedDirectory(Object.freeze({
|
|
139
|
+
admission: createAdmission,
|
|
140
|
+
parent: checkedMutationDirectory(parentPath, parentGuard.realPath, created.parentAfter),
|
|
141
|
+
child: checkedMutationDirectory(targetPath, created.childGuard.realPath, created.childGuard.stat),
|
|
142
|
+
})))
|
|
143
|
+
return true;
|
|
144
|
+
}
|
|
145
|
+
catch {
|
|
146
|
+
// Post-create observations are optional receipt evidence. The directory
|
|
147
|
+
// was already created, so renew ordered admission without a second mkdir.
|
|
148
|
+
}
|
|
149
|
+
await session.authorize(Object.freeze({
|
|
150
|
+
targetPath,
|
|
151
|
+
mutationPath: targetPath,
|
|
152
|
+
phase: "parent",
|
|
153
|
+
}));
|
|
154
|
+
await assertAsyncDirectoryGuard(parentGuard);
|
|
155
|
+
assertDirectoryIdentitySync(root.rootReal, rootIdentity);
|
|
156
|
+
assertFinalSymlinkRejected(targetPath, true);
|
|
157
|
+
const refreshed = await observeCreated();
|
|
158
|
+
await assertAsyncDirectoryGuard(parentGuard);
|
|
159
|
+
await assertAsyncDirectoryGuard(refreshed.childGuard);
|
|
160
|
+
assertDirectoryIdentitySync(root.rootReal, rootIdentity);
|
|
161
|
+
return true;
|
|
162
|
+
}
|
|
163
|
+
finally {
|
|
164
|
+
session.dispose();
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
export async function prepareRootWriteTarget(root, targetPath, assertBeforeMutation, mutationAdmission) {
|
|
168
|
+
const basename = path.basename(targetPath);
|
|
169
|
+
const baseParams = {
|
|
170
|
+
rootReal: root.rootReal,
|
|
171
|
+
rootIdentity: root.rootIdentity,
|
|
172
|
+
targetPath: path.dirname(targetPath),
|
|
173
|
+
assertBeforeMutation,
|
|
174
|
+
};
|
|
175
|
+
const mutationWalk = mutationAdmission
|
|
176
|
+
? mutationWalkOptions(mutationAdmission, (prospectiveParent) => path.join(prospectiveParent, basename), assertBeforeMutation)
|
|
177
|
+
: undefined;
|
|
178
|
+
let parentPath;
|
|
179
|
+
try {
|
|
180
|
+
parentPath = await mkdirPathComponentsWithGuards(mutationWalk ? {
|
|
181
|
+
...baseParams,
|
|
182
|
+
...mutationWalk.options,
|
|
183
|
+
} : baseParams);
|
|
184
|
+
}
|
|
185
|
+
finally {
|
|
186
|
+
mutationWalk?.dispose();
|
|
187
|
+
}
|
|
188
|
+
// Continue through the guarded walk's real parent instead of re-entering
|
|
189
|
+
// the original path through a symlinked component.
|
|
190
|
+
return path.join(parentPath, basename);
|
|
191
|
+
}
|
|
192
|
+
export async function mkdirPathFallback(root, resolved, assertBeforeMutation, rejectSymlinks = false, mutationAdmission) {
|
|
193
|
+
const baseParams = {
|
|
194
|
+
rootReal: resolved.rootReal, targetPath: resolved.resolved, assertBeforeMutation,
|
|
195
|
+
rootIdentity: root.rootIdentity,
|
|
196
|
+
rejectSymlinks,
|
|
197
|
+
beforeComponent: async (componentPath) => await getFsSafeTestHooks()?.beforeRootFallbackMutation?.("mkdir", componentPath),
|
|
198
|
+
};
|
|
199
|
+
const mutationWalk = mutationAdmission
|
|
200
|
+
? mutationWalkOptions(mutationAdmission, (prospectiveDirectory) => prospectiveDirectory, assertBeforeMutation)
|
|
201
|
+
: undefined;
|
|
202
|
+
try {
|
|
203
|
+
await mkdirPathComponentsWithGuards(mutationWalk ? {
|
|
204
|
+
...baseParams,
|
|
205
|
+
...mutationWalk.options,
|
|
206
|
+
rejectSymlinks: rejectSymlinks || mutationAdmission.rejectParentSymlinks,
|
|
207
|
+
} : baseParams);
|
|
208
|
+
}
|
|
209
|
+
finally {
|
|
210
|
+
mutationWalk?.dispose();
|
|
211
|
+
}
|
|
212
|
+
}
|
|
@@ -1,9 +1,21 @@
|
|
|
1
|
-
import type { Stats } from "node:fs";
|
|
1
|
+
import type { BigIntStats, Stats } from "node:fs";
|
|
2
|
+
import { type AsyncDirectoryGuard } from "./directory-guard.js";
|
|
2
3
|
import { type RootContext } from "./root-context.js";
|
|
4
|
+
import type { RootPathDirectoryObservationGuard, RootPathObservationReceipt, RootPathParentObservationReceipt } from "./root-path.js";
|
|
3
5
|
import type { DirEntry, PathStat } from "./types.js";
|
|
4
|
-
export declare function pathStatFromStats(stat: Stats): PathStat;
|
|
5
|
-
export
|
|
6
|
-
export declare function
|
|
6
|
+
export declare function pathStatFromStats(stat: Stats | BigIntStats): PathStat;
|
|
7
|
+
export type RootDirectoryObservationGuard = AsyncDirectoryGuard<BigIntStats>;
|
|
8
|
+
export declare function createRootDirectoryObservationGuard(root: RootContext, directory: string): Promise<RootDirectoryObservationGuard>;
|
|
9
|
+
export declare function assertRootDirectoryObservationGuard(root: RootContext, guard: RootDirectoryObservationGuard | RootPathDirectoryObservationGuard): Promise<void>;
|
|
10
|
+
/**
|
|
11
|
+
* Close an operation-local traversal receipt with fresh exact observations.
|
|
12
|
+
* Descendant canonical paths are admitted while the receipt is created. The
|
|
13
|
+
* final directory check repeats canonical admission; the Root-only case does
|
|
14
|
+
* both its identity and canonical check here.
|
|
15
|
+
*/
|
|
16
|
+
export declare function assertRootPathObservationReceiptCurrent(root: RootContext, receipt: RootPathObservationReceipt | RootPathParentObservationReceipt, finalTarget?: Stats | BigIntStats): void;
|
|
17
|
+
export declare function listDirectoryPath(root: RootContext, directory: string, withFileTypes: true, receipt?: RootPathObservationReceipt): Promise<DirEntry[]>;
|
|
18
|
+
export declare function listDirectoryPath(root: RootContext, directory: string, withFileTypes: boolean, receipt?: RootPathObservationReceipt): Promise<string[] | DirEntry[]>;
|
|
7
19
|
export type RootDirectoryListing = {
|
|
8
20
|
next(): Promise<{
|
|
9
21
|
kind: "entry";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"root-directory-list.d.ts","sourceRoot":"","sources":["../src/root-directory-list.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAO,KAAK,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"root-directory-list.d.ts","sourceRoot":"","sources":["../src/root-directory-list.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAO,KAAK,EAAE,MAAM,SAAS,CAAC;AAKvD,OAAO,EAKL,KAAK,mBAAmB,EAEzB,MAAM,sBAAsB,CAAC;AAQ9B,OAAO,EAA6B,KAAK,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAEhF,OAAO,KAAK,EACV,iCAAiC,EACjC,0BAA0B,EAC1B,gCAAgC,EACjC,MAAM,gBAAgB,CAAC;AAKxB,OAAO,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAIrD,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,KAAK,GAAG,WAAW,GAAG,QAAQ,CAmBrE;AAED,MAAM,MAAM,6BAA6B,GAAG,mBAAmB,CAAC,WAAW,CAAC,CAAC;AAE7E,wBAAsB,mCAAmC,CACvD,IAAI,EAAE,WAAW,EACjB,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,6BAA6B,CAAC,CAaxC;AASD,wBAAsB,mCAAmC,CACvD,IAAI,EAAE,WAAW,EACjB,KAAK,EAAE,6BAA6B,GAAG,iCAAiC,GACvE,OAAO,CAAC,IAAI,CAAC,CAuBf;AAiCD;;;;;GAKG;AACH,wBAAgB,uCAAuC,CACrD,IAAI,EAAE,WAAW,EACjB,OAAO,EAAE,0BAA0B,GAAG,gCAAgC,EACtE,WAAW,CAAC,EAAE,KAAK,GAAG,WAAW,GAChC,IAAI,CAgCN;AAkBD,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,WAAW,EACjB,SAAS,EAAE,MAAM,EACjB,aAAa,EAAE,IAAI,EACnB,OAAO,CAAC,EAAE,0BAA0B,GACnC,OAAO,CAAC,QAAQ,EAAE,CAAC,CAAC;AACvB,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,WAAW,EACjB,SAAS,EAAE,MAAM,EACjB,aAAa,EAAE,OAAO,EACtB,OAAO,CAAC,EAAE,0BAA0B,GACnC,OAAO,CAAC,MAAM,EAAE,GAAG,QAAQ,EAAE,CAAC,CAAC;AAoElC,MAAM,MAAM,oBAAoB,GAAG;IACjC,IAAI,IAAI,OAAO,CAAC;QAAE,IAAI,EAAE,OAAO,CAAC;QAAC,KAAK,EAAE,QAAQ,CAAA;KAAE,GAAG;QAAE,IAAI,EAAE,OAAO,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,GAAG,SAAS,CAAC,CAAC;IAClG,CAAC,MAAM,CAAC,YAAY,CAAC,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;CACxC,CAAC;AAEF,MAAM,MAAM,2BAA2B,GAAG;IACxC,KAAK,EAAE,QAAQ,GAAG,YAAY,CAAC;IAC/B,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,UAAU,IAAI,OAAO,CAAC;CACvB,CAAC;AAEF,wBAAsB,wBAAwB,CAC5C,IAAI,EAAE,WAAW,EACjB,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,2BAA2B,GACnC,OAAO,CAAC,oBAAoB,CAAC,CAuI/B"}
|