@ontos-ai/knowhere-claw 0.1.4 → 0.1.5
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/README.md +3 -0
- package/dist/_virtual/_rolldown/runtime.js +2 -1
- package/dist/config.js +115 -1
- package/dist/connect-builder.js +181 -0
- package/dist/graph-builder.js +204 -0
- package/dist/index.js +15 -3
- package/dist/kg-service.js +249 -0
- package/dist/node_modules/.pnpm/@mapbox_node-pre-gyp@1.0.11/node_modules/@mapbox/node-pre-gyp/lib/node-pre-gyp.js +212 -0
- package/dist/node_modules/.pnpm/@mapbox_node-pre-gyp@1.0.11/node_modules/@mapbox/node-pre-gyp/lib/pre-binding.js +35 -0
- package/dist/node_modules/.pnpm/@mapbox_node-pre-gyp@1.0.11/node_modules/@mapbox/node-pre-gyp/lib/util/abi_crosswalk.js +2609 -0
- package/dist/node_modules/.pnpm/@mapbox_node-pre-gyp@1.0.11/node_modules/@mapbox/node-pre-gyp/lib/util/napi.js +142 -0
- package/dist/node_modules/.pnpm/@mapbox_node-pre-gyp@1.0.11/node_modules/@mapbox/node-pre-gyp/lib/util/s3_setup.js +103 -0
- package/dist/node_modules/.pnpm/@mapbox_node-pre-gyp@1.0.11/node_modules/@mapbox/node-pre-gyp/lib/util/versioning.js +199 -0
- package/dist/node_modules/.pnpm/@mapbox_node-pre-gyp@1.0.11/node_modules/@mapbox/node-pre-gyp/package.js +67 -0
- package/dist/node_modules/.pnpm/abbrev@1.1.1/node_modules/abbrev/abbrev.js +59 -0
- package/dist/node_modules/.pnpm/ansi-regex@5.0.1/node_modules/ansi-regex/index.js +11 -0
- package/dist/node_modules/.pnpm/aproba@2.1.0/node_modules/aproba/index.js +119 -0
- package/dist/node_modules/.pnpm/are-we-there-yet@2.0.0/node_modules/are-we-there-yet/lib/index.js +13 -0
- package/dist/node_modules/.pnpm/are-we-there-yet@2.0.0/node_modules/are-we-there-yet/lib/tracker-base.js +16 -0
- package/dist/node_modules/.pnpm/are-we-there-yet@2.0.0/node_modules/are-we-there-yet/lib/tracker-group.js +98 -0
- package/dist/node_modules/.pnpm/are-we-there-yet@2.0.0/node_modules/are-we-there-yet/lib/tracker-stream.js +37 -0
- package/dist/node_modules/.pnpm/are-we-there-yet@2.0.0/node_modules/are-we-there-yet/lib/tracker.js +32 -0
- package/dist/node_modules/.pnpm/balanced-match@1.0.2/node_modules/balanced-match/index.js +53 -0
- package/dist/node_modules/.pnpm/brace-expansion@1.1.12/node_modules/brace-expansion/index.js +132 -0
- package/dist/node_modules/.pnpm/color-support@1.1.3/node_modules/color-support/browser.js +18 -0
- package/dist/node_modules/.pnpm/concat-map@0.0.1/node_modules/concat-map/index.js +19 -0
- package/dist/node_modules/.pnpm/console-control-strings@1.1.0/node_modules/console-control-strings/index.js +104 -0
- package/dist/node_modules/.pnpm/delegates@1.0.0/node_modules/delegates/index.js +104 -0
- package/dist/node_modules/.pnpm/detect-libc@2.1.2/node_modules/detect-libc/lib/detect-libc.js +221 -0
- package/dist/node_modules/.pnpm/detect-libc@2.1.2/node_modules/detect-libc/lib/elf.js +26 -0
- package/dist/node_modules/.pnpm/detect-libc@2.1.2/node_modules/detect-libc/lib/filesystem.js +48 -0
- package/dist/node_modules/.pnpm/detect-libc@2.1.2/node_modules/detect-libc/lib/process.js +24 -0
- package/dist/node_modules/.pnpm/emoji-regex@8.0.0/node_modules/emoji-regex/index.js +10 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/copy/copy-sync.js +120 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/copy/copy.js +100 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/copy/index.js +15 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/empty/index.js +43 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/file.js +53 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/index.js +27 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/link.js +56 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/symlink-paths.js +89 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/symlink-type.js +35 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/symlink.js +81 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/fs/index.js +113 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/index.js +29 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/json/index.js +22 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/json/jsonfile.js +15 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/json/output-json-sync.js +15 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/json/output-json.js +15 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/mkdirs/index.js +20 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/mkdirs/make-dir.js +33 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/mkdirs/utils.js +17 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/move/index.js +15 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/move/move-sync.js +56 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/move/move.js +49 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/output-file/index.js +30 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/path-exists/index.js +18 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/remove/index.js +27 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/util/async.js +15 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/util/stat.js +131 -0
- package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/util/utimes.js +34 -0
- package/dist/node_modules/.pnpm/fs.realpath@1.0.0/node_modules/fs.realpath/index.js +51 -0
- package/dist/node_modules/.pnpm/fs.realpath@1.0.0/node_modules/fs.realpath/old.js +171 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/base-theme.js +21 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/error.js +27 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/has-color.js +9 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/index.js +224 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/plumbing.js +48 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/process.js +8 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/progress-bar.js +46 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/render-template.js +155 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/set-immediate.js +14 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/set-interval.js +8 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/spin.js +10 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/template-item.js +58 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/theme-set.js +99 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/themes.js +67 -0
- package/dist/node_modules/.pnpm/gauge@3.0.2/node_modules/gauge/wide-truncate.js +22 -0
- package/dist/node_modules/.pnpm/glob@7.2.3/node_modules/glob/common.js +162 -0
- package/dist/node_modules/.pnpm/glob@7.2.3/node_modules/glob/glob.js +451 -0
- package/dist/node_modules/.pnpm/glob@7.2.3/node_modules/glob/sync.js +280 -0
- package/dist/node_modules/.pnpm/graceful-fs@4.2.11/node_modules/graceful-fs/clone.js +20 -0
- package/dist/node_modules/.pnpm/graceful-fs@4.2.11/node_modules/graceful-fs/graceful-fs.js +362 -0
- package/dist/node_modules/.pnpm/graceful-fs@4.2.11/node_modules/graceful-fs/legacy-streams.js +92 -0
- package/dist/node_modules/.pnpm/graceful-fs@4.2.11/node_modules/graceful-fs/polyfills.js +255 -0
- package/dist/node_modules/.pnpm/has-unicode@2.0.1/node_modules/has-unicode/index.js +14 -0
- package/dist/node_modules/.pnpm/inflight@1.0.6/node_modules/inflight/inflight.js +45 -0
- package/dist/node_modules/.pnpm/inherits@2.0.4/node_modules/inherits/inherits_browser.js +27 -0
- package/dist/node_modules/.pnpm/is-fullwidth-code-point@3.0.0/node_modules/is-fullwidth-code-point/index.js +14 -0
- package/dist/node_modules/.pnpm/jsonfile@6.2.0/node_modules/jsonfile/index.js +68 -0
- package/dist/node_modules/.pnpm/jsonfile@6.2.0/node_modules/jsonfile/utils.js +19 -0
- package/dist/node_modules/.pnpm/minimatch@3.1.5/node_modules/minimatch/minimatch.js +578 -0
- package/dist/node_modules/.pnpm/nodejieba@2.6.0/node_modules/nodejieba/index.js +46 -0
- package/dist/node_modules/.pnpm/nopt@5.0.0/node_modules/nopt/lib/nopt.js +330 -0
- package/dist/node_modules/.pnpm/npmlog@5.0.1/node_modules/npmlog/log.js +305 -0
- package/dist/node_modules/.pnpm/object-assign@4.1.1/node_modules/object-assign/index.js +54 -0
- package/dist/node_modules/.pnpm/once@1.4.0/node_modules/once/once.js +44 -0
- package/dist/node_modules/.pnpm/path-is-absolute@1.0.1/node_modules/path-is-absolute/index.js +19 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/errors-browser.js +88 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_duplex.js +75 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_passthrough.js +19 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_readable.js +666 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_transform.js +89 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_writable.js +423 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/async_iterator.js +172 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/buffer_list.js +243 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/destroy.js +77 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/end-of-stream.js +87 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/from-browser.js +10 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/pipeline.js +80 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/state.js +21 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/stream-browser.js +8 -0
- package/dist/node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/readable-browser.js +23 -0
- package/dist/node_modules/.pnpm/rimraf@3.0.2/node_modules/rimraf/rimraf.js +229 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/classes/comparator.js +79 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/classes/range.js +282 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/classes/semver.js +186 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/clean.js +14 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/cmp.js +41 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/coerce.js +34 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/compare-build.js +15 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/compare-loose.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/compare.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/diff.js +32 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/eq.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/gt.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/gte.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/inc.js +22 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/lt.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/lte.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/major.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/minor.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/neq.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/parse.js +19 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/patch.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/prerelease.js +14 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/rcompare.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/rsort.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/satisfies.js +18 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/sort.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/valid.js +14 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/index.js +99 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/internal/constants.js +28 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/internal/debug.js +8 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/internal/identifiers.js +23 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/internal/lrucache.js +36 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/internal/parse-options.js +15 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/internal/re.js +84 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/ranges/gtr.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/ranges/intersects.js +15 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/ranges/ltr.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/ranges/max-satisfying.js +31 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/ranges/min-satisfying.js +31 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/ranges/min-version.js +45 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/ranges/outside.js +64 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/ranges/simplify.js +35 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/ranges/subset.js +102 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/ranges/to-comparators.js +11 -0
- package/dist/node_modules/.pnpm/semver@7.7.4/node_modules/semver/ranges/valid.js +17 -0
- package/dist/node_modules/.pnpm/set-blocking@2.0.0/node_modules/set-blocking/index.js +12 -0
- package/dist/node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/index.js +130 -0
- package/dist/node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/signals.js +16 -0
- package/dist/node_modules/.pnpm/string-width@4.2.3/node_modules/string-width/index.js +30 -0
- package/dist/node_modules/.pnpm/strip-ansi@6.0.1/node_modules/strip-ansi/index.js +10 -0
- package/dist/node_modules/.pnpm/universalify@2.0.1/node_modules/universalify/index.js +26 -0
- package/dist/node_modules/.pnpm/util-deprecate@1.0.2/node_modules/util-deprecate/browser.js +59 -0
- package/dist/node_modules/.pnpm/wide-align@1.1.5/node_modules/wide-align/align.js +52 -0
- package/dist/node_modules/.pnpm/wrappy@1.0.2/node_modules/wrappy/wrappy.js +26 -0
- package/dist/tools.js +163 -3
- package/openclaw.plugin.json +1 -1
- package/package.json +15 -6
- package/skills/knowhere/SKILL.md +1 -1
- package/dist/__tests__/channel-route.test.d.ts +0 -1
- package/dist/__tests__/ingest-tool.test.d.ts +0 -1
- package/dist/__tests__/read-result-file-tool.test.d.ts +0 -1
- package/dist/__tests__/tracker-progress.test.d.ts +0 -1
- package/dist/channel-delivery.d.ts +0 -21
- package/dist/client.d.ts +0 -33
- package/dist/config.d.ts +0 -12
- package/dist/error-message.d.ts +0 -1
- package/dist/index.d.ts +0 -9
- package/dist/parser.d.ts +0 -16
- package/dist/session.d.ts +0 -11
- package/dist/store.d.ts +0 -79
- package/dist/text.d.ts +0 -10
- package/dist/tools.d.ts +0 -8
- package/dist/tracker-progress.d.ts +0 -10
- package/dist/types.d.ts +0 -248
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { __commonJSMin } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_universalify } from "../../../../../universalify@2.0.1/node_modules/universalify/index.js";
|
|
3
|
+
import { require_copy as require_copy$1 } from "./copy.js";
|
|
4
|
+
import { require_copy_sync } from "./copy-sync.js";
|
|
5
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/copy/index.js
|
|
6
|
+
var require_copy = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
7
|
+
const u = require_universalify().fromPromise;
|
|
8
|
+
module.exports = {
|
|
9
|
+
copy: u(require_copy$1()),
|
|
10
|
+
copySync: require_copy_sync()
|
|
11
|
+
};
|
|
12
|
+
}));
|
|
13
|
+
//#endregion
|
|
14
|
+
export default require_copy();
|
|
15
|
+
export { require_copy };
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { __commonJSMin, __require } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_universalify } from "../../../../../universalify@2.0.1/node_modules/universalify/index.js";
|
|
3
|
+
import { require_fs } from "../fs/index.js";
|
|
4
|
+
import { require_mkdirs } from "../mkdirs/index.js";
|
|
5
|
+
import { require_remove } from "../remove/index.js";
|
|
6
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/empty/index.js
|
|
7
|
+
var require_empty = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
8
|
+
const u = require_universalify().fromPromise;
|
|
9
|
+
const fs = require_fs();
|
|
10
|
+
const path = __require("path");
|
|
11
|
+
const mkdir = require_mkdirs();
|
|
12
|
+
const remove = require_remove();
|
|
13
|
+
const emptyDir = u(async function emptyDir(dir) {
|
|
14
|
+
let items;
|
|
15
|
+
try {
|
|
16
|
+
items = await fs.readdir(dir);
|
|
17
|
+
} catch {
|
|
18
|
+
return mkdir.mkdirs(dir);
|
|
19
|
+
}
|
|
20
|
+
return Promise.all(items.map((item) => remove.remove(path.join(dir, item))));
|
|
21
|
+
});
|
|
22
|
+
function emptyDirSync(dir) {
|
|
23
|
+
let items;
|
|
24
|
+
try {
|
|
25
|
+
items = fs.readdirSync(dir);
|
|
26
|
+
} catch {
|
|
27
|
+
return mkdir.mkdirsSync(dir);
|
|
28
|
+
}
|
|
29
|
+
items.forEach((item) => {
|
|
30
|
+
item = path.join(dir, item);
|
|
31
|
+
remove.removeSync(item);
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
module.exports = {
|
|
35
|
+
emptyDirSync,
|
|
36
|
+
emptydirSync: emptyDirSync,
|
|
37
|
+
emptyDir,
|
|
38
|
+
emptydir: emptyDir
|
|
39
|
+
};
|
|
40
|
+
}));
|
|
41
|
+
//#endregion
|
|
42
|
+
export default require_empty();
|
|
43
|
+
export { require_empty };
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { __commonJSMin, __require } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_universalify } from "../../../../../universalify@2.0.1/node_modules/universalify/index.js";
|
|
3
|
+
import { require_fs } from "../fs/index.js";
|
|
4
|
+
import { require_mkdirs } from "../mkdirs/index.js";
|
|
5
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/file.js
|
|
6
|
+
var require_file = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
7
|
+
const u = require_universalify().fromPromise;
|
|
8
|
+
const path = __require("path");
|
|
9
|
+
const fs = require_fs();
|
|
10
|
+
const mkdir = require_mkdirs();
|
|
11
|
+
async function createFile(file) {
|
|
12
|
+
let stats;
|
|
13
|
+
try {
|
|
14
|
+
stats = await fs.stat(file);
|
|
15
|
+
} catch {}
|
|
16
|
+
if (stats && stats.isFile()) return;
|
|
17
|
+
const dir = path.dirname(file);
|
|
18
|
+
let dirStats = null;
|
|
19
|
+
try {
|
|
20
|
+
dirStats = await fs.stat(dir);
|
|
21
|
+
} catch (err) {
|
|
22
|
+
if (err.code === "ENOENT") {
|
|
23
|
+
await mkdir.mkdirs(dir);
|
|
24
|
+
await fs.writeFile(file, "");
|
|
25
|
+
return;
|
|
26
|
+
} else throw err;
|
|
27
|
+
}
|
|
28
|
+
if (dirStats.isDirectory()) await fs.writeFile(file, "");
|
|
29
|
+
else await fs.readdir(dir);
|
|
30
|
+
}
|
|
31
|
+
function createFileSync(file) {
|
|
32
|
+
let stats;
|
|
33
|
+
try {
|
|
34
|
+
stats = fs.statSync(file);
|
|
35
|
+
} catch {}
|
|
36
|
+
if (stats && stats.isFile()) return;
|
|
37
|
+
const dir = path.dirname(file);
|
|
38
|
+
try {
|
|
39
|
+
if (!fs.statSync(dir).isDirectory()) fs.readdirSync(dir);
|
|
40
|
+
} catch (err) {
|
|
41
|
+
if (err && err.code === "ENOENT") mkdir.mkdirsSync(dir);
|
|
42
|
+
else throw err;
|
|
43
|
+
}
|
|
44
|
+
fs.writeFileSync(file, "");
|
|
45
|
+
}
|
|
46
|
+
module.exports = {
|
|
47
|
+
createFile: u(createFile),
|
|
48
|
+
createFileSync
|
|
49
|
+
};
|
|
50
|
+
}));
|
|
51
|
+
//#endregion
|
|
52
|
+
export default require_file();
|
|
53
|
+
export { require_file };
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { __commonJSMin } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_file } from "./file.js";
|
|
3
|
+
import { require_link } from "./link.js";
|
|
4
|
+
import { require_symlink } from "./symlink.js";
|
|
5
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/index.js
|
|
6
|
+
var require_ensure = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
7
|
+
const { createFile, createFileSync } = require_file();
|
|
8
|
+
const { createLink, createLinkSync } = require_link();
|
|
9
|
+
const { createSymlink, createSymlinkSync } = require_symlink();
|
|
10
|
+
module.exports = {
|
|
11
|
+
createFile,
|
|
12
|
+
createFileSync,
|
|
13
|
+
ensureFile: createFile,
|
|
14
|
+
ensureFileSync: createFileSync,
|
|
15
|
+
createLink,
|
|
16
|
+
createLinkSync,
|
|
17
|
+
ensureLink: createLink,
|
|
18
|
+
ensureLinkSync: createLinkSync,
|
|
19
|
+
createSymlink,
|
|
20
|
+
createSymlinkSync,
|
|
21
|
+
ensureSymlink: createSymlink,
|
|
22
|
+
ensureSymlinkSync: createSymlinkSync
|
|
23
|
+
};
|
|
24
|
+
}));
|
|
25
|
+
//#endregion
|
|
26
|
+
export default require_ensure();
|
|
27
|
+
export { require_ensure };
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { __commonJSMin, __require } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_universalify } from "../../../../../universalify@2.0.1/node_modules/universalify/index.js";
|
|
3
|
+
import { require_fs } from "../fs/index.js";
|
|
4
|
+
import { require_mkdirs } from "../mkdirs/index.js";
|
|
5
|
+
import { require_path_exists } from "../path-exists/index.js";
|
|
6
|
+
import { require_stat } from "../util/stat.js";
|
|
7
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/link.js
|
|
8
|
+
var require_link = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
9
|
+
const u = require_universalify().fromPromise;
|
|
10
|
+
const path = __require("path");
|
|
11
|
+
const fs = require_fs();
|
|
12
|
+
const mkdir = require_mkdirs();
|
|
13
|
+
const { pathExists } = require_path_exists();
|
|
14
|
+
const { areIdentical } = require_stat();
|
|
15
|
+
async function createLink(srcpath, dstpath) {
|
|
16
|
+
let dstStat;
|
|
17
|
+
try {
|
|
18
|
+
dstStat = await fs.lstat(dstpath);
|
|
19
|
+
} catch {}
|
|
20
|
+
let srcStat;
|
|
21
|
+
try {
|
|
22
|
+
srcStat = await fs.lstat(srcpath);
|
|
23
|
+
} catch (err) {
|
|
24
|
+
err.message = err.message.replace("lstat", "ensureLink");
|
|
25
|
+
throw err;
|
|
26
|
+
}
|
|
27
|
+
if (dstStat && areIdentical(srcStat, dstStat)) return;
|
|
28
|
+
const dir = path.dirname(dstpath);
|
|
29
|
+
if (!await pathExists(dir)) await mkdir.mkdirs(dir);
|
|
30
|
+
await fs.link(srcpath, dstpath);
|
|
31
|
+
}
|
|
32
|
+
function createLinkSync(srcpath, dstpath) {
|
|
33
|
+
let dstStat;
|
|
34
|
+
try {
|
|
35
|
+
dstStat = fs.lstatSync(dstpath);
|
|
36
|
+
} catch {}
|
|
37
|
+
try {
|
|
38
|
+
const srcStat = fs.lstatSync(srcpath);
|
|
39
|
+
if (dstStat && areIdentical(srcStat, dstStat)) return;
|
|
40
|
+
} catch (err) {
|
|
41
|
+
err.message = err.message.replace("lstat", "ensureLink");
|
|
42
|
+
throw err;
|
|
43
|
+
}
|
|
44
|
+
const dir = path.dirname(dstpath);
|
|
45
|
+
if (fs.existsSync(dir)) return fs.linkSync(srcpath, dstpath);
|
|
46
|
+
mkdir.mkdirsSync(dir);
|
|
47
|
+
return fs.linkSync(srcpath, dstpath);
|
|
48
|
+
}
|
|
49
|
+
module.exports = {
|
|
50
|
+
createLink: u(createLink),
|
|
51
|
+
createLinkSync
|
|
52
|
+
};
|
|
53
|
+
}));
|
|
54
|
+
//#endregion
|
|
55
|
+
export default require_link();
|
|
56
|
+
export { require_link };
|
package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/symlink-paths.js
ADDED
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { __commonJSMin, __require } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_universalify } from "../../../../../universalify@2.0.1/node_modules/universalify/index.js";
|
|
3
|
+
import { require_fs } from "../fs/index.js";
|
|
4
|
+
import { require_path_exists } from "../path-exists/index.js";
|
|
5
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/symlink-paths.js
|
|
6
|
+
var require_symlink_paths = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
7
|
+
const path = __require("path");
|
|
8
|
+
const fs = require_fs();
|
|
9
|
+
const { pathExists } = require_path_exists();
|
|
10
|
+
const u = require_universalify().fromPromise;
|
|
11
|
+
/**
|
|
12
|
+
* Function that returns two types of paths, one relative to symlink, and one
|
|
13
|
+
* relative to the current working directory. Checks if path is absolute or
|
|
14
|
+
* relative. If the path is relative, this function checks if the path is
|
|
15
|
+
* relative to symlink or relative to current working directory. This is an
|
|
16
|
+
* initiative to find a smarter `srcpath` to supply when building symlinks.
|
|
17
|
+
* This allows you to determine which path to use out of one of three possible
|
|
18
|
+
* types of source paths. The first is an absolute path. This is detected by
|
|
19
|
+
* `path.isAbsolute()`. When an absolute path is provided, it is checked to
|
|
20
|
+
* see if it exists. If it does it's used, if not an error is returned
|
|
21
|
+
* (callback)/ thrown (sync). The other two options for `srcpath` are a
|
|
22
|
+
* relative url. By default Node's `fs.symlink` works by creating a symlink
|
|
23
|
+
* using `dstpath` and expects the `srcpath` to be relative to the newly
|
|
24
|
+
* created symlink. If you provide a `srcpath` that does not exist on the file
|
|
25
|
+
* system it results in a broken symlink. To minimize this, the function
|
|
26
|
+
* checks to see if the 'relative to symlink' source file exists, and if it
|
|
27
|
+
* does it will use it. If it does not, it checks if there's a file that
|
|
28
|
+
* exists that is relative to the current working directory, if does its used.
|
|
29
|
+
* This preserves the expectations of the original fs.symlink spec and adds
|
|
30
|
+
* the ability to pass in `relative to current working direcotry` paths.
|
|
31
|
+
*/
|
|
32
|
+
async function symlinkPaths(srcpath, dstpath) {
|
|
33
|
+
if (path.isAbsolute(srcpath)) {
|
|
34
|
+
try {
|
|
35
|
+
await fs.lstat(srcpath);
|
|
36
|
+
} catch (err) {
|
|
37
|
+
err.message = err.message.replace("lstat", "ensureSymlink");
|
|
38
|
+
throw err;
|
|
39
|
+
}
|
|
40
|
+
return {
|
|
41
|
+
toCwd: srcpath,
|
|
42
|
+
toDst: srcpath
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
const dstdir = path.dirname(dstpath);
|
|
46
|
+
const relativeToDst = path.join(dstdir, srcpath);
|
|
47
|
+
if (await pathExists(relativeToDst)) return {
|
|
48
|
+
toCwd: relativeToDst,
|
|
49
|
+
toDst: srcpath
|
|
50
|
+
};
|
|
51
|
+
try {
|
|
52
|
+
await fs.lstat(srcpath);
|
|
53
|
+
} catch (err) {
|
|
54
|
+
err.message = err.message.replace("lstat", "ensureSymlink");
|
|
55
|
+
throw err;
|
|
56
|
+
}
|
|
57
|
+
return {
|
|
58
|
+
toCwd: srcpath,
|
|
59
|
+
toDst: path.relative(dstdir, srcpath)
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
function symlinkPathsSync(srcpath, dstpath) {
|
|
63
|
+
if (path.isAbsolute(srcpath)) {
|
|
64
|
+
if (!fs.existsSync(srcpath)) throw new Error("absolute srcpath does not exist");
|
|
65
|
+
return {
|
|
66
|
+
toCwd: srcpath,
|
|
67
|
+
toDst: srcpath
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
const dstdir = path.dirname(dstpath);
|
|
71
|
+
const relativeToDst = path.join(dstdir, srcpath);
|
|
72
|
+
if (fs.existsSync(relativeToDst)) return {
|
|
73
|
+
toCwd: relativeToDst,
|
|
74
|
+
toDst: srcpath
|
|
75
|
+
};
|
|
76
|
+
if (!fs.existsSync(srcpath)) throw new Error("relative srcpath does not exist");
|
|
77
|
+
return {
|
|
78
|
+
toCwd: srcpath,
|
|
79
|
+
toDst: path.relative(dstdir, srcpath)
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
module.exports = {
|
|
83
|
+
symlinkPaths: u(symlinkPaths),
|
|
84
|
+
symlinkPathsSync
|
|
85
|
+
};
|
|
86
|
+
}));
|
|
87
|
+
//#endregion
|
|
88
|
+
export default require_symlink_paths();
|
|
89
|
+
export { require_symlink_paths };
|
package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/symlink-type.js
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { __commonJSMin } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_universalify } from "../../../../../universalify@2.0.1/node_modules/universalify/index.js";
|
|
3
|
+
import { require_fs } from "../fs/index.js";
|
|
4
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/symlink-type.js
|
|
5
|
+
var require_symlink_type = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
6
|
+
const fs = require_fs();
|
|
7
|
+
const u = require_universalify().fromPromise;
|
|
8
|
+
async function symlinkType(srcpath, type) {
|
|
9
|
+
if (type) return type;
|
|
10
|
+
let stats;
|
|
11
|
+
try {
|
|
12
|
+
stats = await fs.lstat(srcpath);
|
|
13
|
+
} catch {
|
|
14
|
+
return "file";
|
|
15
|
+
}
|
|
16
|
+
return stats && stats.isDirectory() ? "dir" : "file";
|
|
17
|
+
}
|
|
18
|
+
function symlinkTypeSync(srcpath, type) {
|
|
19
|
+
if (type) return type;
|
|
20
|
+
let stats;
|
|
21
|
+
try {
|
|
22
|
+
stats = fs.lstatSync(srcpath);
|
|
23
|
+
} catch {
|
|
24
|
+
return "file";
|
|
25
|
+
}
|
|
26
|
+
return stats && stats.isDirectory() ? "dir" : "file";
|
|
27
|
+
}
|
|
28
|
+
module.exports = {
|
|
29
|
+
symlinkType: u(symlinkType),
|
|
30
|
+
symlinkTypeSync
|
|
31
|
+
};
|
|
32
|
+
}));
|
|
33
|
+
//#endregion
|
|
34
|
+
export default require_symlink_type();
|
|
35
|
+
export { require_symlink_type };
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { __commonJSMin, __require } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_universalify } from "../../../../../universalify@2.0.1/node_modules/universalify/index.js";
|
|
3
|
+
import { require_fs } from "../fs/index.js";
|
|
4
|
+
import { require_mkdirs } from "../mkdirs/index.js";
|
|
5
|
+
import { require_path_exists } from "../path-exists/index.js";
|
|
6
|
+
import { require_stat } from "../util/stat.js";
|
|
7
|
+
import { require_symlink_paths } from "./symlink-paths.js";
|
|
8
|
+
import { require_symlink_type } from "./symlink-type.js";
|
|
9
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/ensure/symlink.js
|
|
10
|
+
var require_symlink = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
11
|
+
const u = require_universalify().fromPromise;
|
|
12
|
+
const path = __require("path");
|
|
13
|
+
const fs = require_fs();
|
|
14
|
+
const { mkdirs, mkdirsSync } = require_mkdirs();
|
|
15
|
+
const { symlinkPaths, symlinkPathsSync } = require_symlink_paths();
|
|
16
|
+
const { symlinkType, symlinkTypeSync } = require_symlink_type();
|
|
17
|
+
const { pathExists } = require_path_exists();
|
|
18
|
+
const { areIdentical } = require_stat();
|
|
19
|
+
async function createSymlink(srcpath, dstpath, type) {
|
|
20
|
+
let stats;
|
|
21
|
+
try {
|
|
22
|
+
stats = await fs.lstat(dstpath);
|
|
23
|
+
} catch {}
|
|
24
|
+
if (stats && stats.isSymbolicLink()) {
|
|
25
|
+
let srcStat;
|
|
26
|
+
if (path.isAbsolute(srcpath)) srcStat = await fs.stat(srcpath);
|
|
27
|
+
else {
|
|
28
|
+
const dstdir = path.dirname(dstpath);
|
|
29
|
+
const relativeToDst = path.join(dstdir, srcpath);
|
|
30
|
+
try {
|
|
31
|
+
srcStat = await fs.stat(relativeToDst);
|
|
32
|
+
} catch {
|
|
33
|
+
srcStat = await fs.stat(srcpath);
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
const dstStat = await fs.stat(dstpath);
|
|
37
|
+
if (areIdentical(srcStat, dstStat)) return;
|
|
38
|
+
}
|
|
39
|
+
const relative = await symlinkPaths(srcpath, dstpath);
|
|
40
|
+
srcpath = relative.toDst;
|
|
41
|
+
const toType = await symlinkType(relative.toCwd, type);
|
|
42
|
+
const dir = path.dirname(dstpath);
|
|
43
|
+
if (!await pathExists(dir)) await mkdirs(dir);
|
|
44
|
+
return fs.symlink(srcpath, dstpath, toType);
|
|
45
|
+
}
|
|
46
|
+
function createSymlinkSync(srcpath, dstpath, type) {
|
|
47
|
+
let stats;
|
|
48
|
+
try {
|
|
49
|
+
stats = fs.lstatSync(dstpath);
|
|
50
|
+
} catch {}
|
|
51
|
+
if (stats && stats.isSymbolicLink()) {
|
|
52
|
+
let srcStat;
|
|
53
|
+
if (path.isAbsolute(srcpath)) srcStat = fs.statSync(srcpath);
|
|
54
|
+
else {
|
|
55
|
+
const dstdir = path.dirname(dstpath);
|
|
56
|
+
const relativeToDst = path.join(dstdir, srcpath);
|
|
57
|
+
try {
|
|
58
|
+
srcStat = fs.statSync(relativeToDst);
|
|
59
|
+
} catch {
|
|
60
|
+
srcStat = fs.statSync(srcpath);
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
const dstStat = fs.statSync(dstpath);
|
|
64
|
+
if (areIdentical(srcStat, dstStat)) return;
|
|
65
|
+
}
|
|
66
|
+
const relative = symlinkPathsSync(srcpath, dstpath);
|
|
67
|
+
srcpath = relative.toDst;
|
|
68
|
+
type = symlinkTypeSync(relative.toCwd, type);
|
|
69
|
+
const dir = path.dirname(dstpath);
|
|
70
|
+
if (fs.existsSync(dir)) return fs.symlinkSync(srcpath, dstpath, type);
|
|
71
|
+
mkdirsSync(dir);
|
|
72
|
+
return fs.symlinkSync(srcpath, dstpath, type);
|
|
73
|
+
}
|
|
74
|
+
module.exports = {
|
|
75
|
+
createSymlink: u(createSymlink),
|
|
76
|
+
createSymlinkSync
|
|
77
|
+
};
|
|
78
|
+
}));
|
|
79
|
+
//#endregion
|
|
80
|
+
export default require_symlink();
|
|
81
|
+
export { require_symlink };
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import { __commonJSMin } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_universalify } from "../../../../../universalify@2.0.1/node_modules/universalify/index.js";
|
|
3
|
+
import { require_graceful_fs } from "../../../../../graceful-fs@4.2.11/node_modules/graceful-fs/graceful-fs.js";
|
|
4
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/fs/index.js
|
|
5
|
+
var require_fs = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
6
|
+
const u = require_universalify().fromCallback;
|
|
7
|
+
const fs = require_graceful_fs();
|
|
8
|
+
const api = [
|
|
9
|
+
"access",
|
|
10
|
+
"appendFile",
|
|
11
|
+
"chmod",
|
|
12
|
+
"chown",
|
|
13
|
+
"close",
|
|
14
|
+
"copyFile",
|
|
15
|
+
"cp",
|
|
16
|
+
"fchmod",
|
|
17
|
+
"fchown",
|
|
18
|
+
"fdatasync",
|
|
19
|
+
"fstat",
|
|
20
|
+
"fsync",
|
|
21
|
+
"ftruncate",
|
|
22
|
+
"futimes",
|
|
23
|
+
"glob",
|
|
24
|
+
"lchmod",
|
|
25
|
+
"lchown",
|
|
26
|
+
"lutimes",
|
|
27
|
+
"link",
|
|
28
|
+
"lstat",
|
|
29
|
+
"mkdir",
|
|
30
|
+
"mkdtemp",
|
|
31
|
+
"open",
|
|
32
|
+
"opendir",
|
|
33
|
+
"readdir",
|
|
34
|
+
"readFile",
|
|
35
|
+
"readlink",
|
|
36
|
+
"realpath",
|
|
37
|
+
"rename",
|
|
38
|
+
"rm",
|
|
39
|
+
"rmdir",
|
|
40
|
+
"stat",
|
|
41
|
+
"statfs",
|
|
42
|
+
"symlink",
|
|
43
|
+
"truncate",
|
|
44
|
+
"unlink",
|
|
45
|
+
"utimes",
|
|
46
|
+
"writeFile"
|
|
47
|
+
].filter((key) => {
|
|
48
|
+
return typeof fs[key] === "function";
|
|
49
|
+
});
|
|
50
|
+
Object.assign(exports, fs);
|
|
51
|
+
api.forEach((method) => {
|
|
52
|
+
exports[method] = u(fs[method]);
|
|
53
|
+
});
|
|
54
|
+
exports.exists = function(filename, callback) {
|
|
55
|
+
if (typeof callback === "function") return fs.exists(filename, callback);
|
|
56
|
+
return new Promise((resolve) => {
|
|
57
|
+
return fs.exists(filename, resolve);
|
|
58
|
+
});
|
|
59
|
+
};
|
|
60
|
+
exports.read = function(fd, buffer, offset, length, position, callback) {
|
|
61
|
+
if (typeof callback === "function") return fs.read(fd, buffer, offset, length, position, callback);
|
|
62
|
+
return new Promise((resolve, reject) => {
|
|
63
|
+
fs.read(fd, buffer, offset, length, position, (err, bytesRead, buffer) => {
|
|
64
|
+
if (err) return reject(err);
|
|
65
|
+
resolve({
|
|
66
|
+
bytesRead,
|
|
67
|
+
buffer
|
|
68
|
+
});
|
|
69
|
+
});
|
|
70
|
+
});
|
|
71
|
+
};
|
|
72
|
+
exports.write = function(fd, buffer, ...args) {
|
|
73
|
+
if (typeof args[args.length - 1] === "function") return fs.write(fd, buffer, ...args);
|
|
74
|
+
return new Promise((resolve, reject) => {
|
|
75
|
+
fs.write(fd, buffer, ...args, (err, bytesWritten, buffer) => {
|
|
76
|
+
if (err) return reject(err);
|
|
77
|
+
resolve({
|
|
78
|
+
bytesWritten,
|
|
79
|
+
buffer
|
|
80
|
+
});
|
|
81
|
+
});
|
|
82
|
+
});
|
|
83
|
+
};
|
|
84
|
+
exports.readv = function(fd, buffers, ...args) {
|
|
85
|
+
if (typeof args[args.length - 1] === "function") return fs.readv(fd, buffers, ...args);
|
|
86
|
+
return new Promise((resolve, reject) => {
|
|
87
|
+
fs.readv(fd, buffers, ...args, (err, bytesRead, buffers) => {
|
|
88
|
+
if (err) return reject(err);
|
|
89
|
+
resolve({
|
|
90
|
+
bytesRead,
|
|
91
|
+
buffers
|
|
92
|
+
});
|
|
93
|
+
});
|
|
94
|
+
});
|
|
95
|
+
};
|
|
96
|
+
exports.writev = function(fd, buffers, ...args) {
|
|
97
|
+
if (typeof args[args.length - 1] === "function") return fs.writev(fd, buffers, ...args);
|
|
98
|
+
return new Promise((resolve, reject) => {
|
|
99
|
+
fs.writev(fd, buffers, ...args, (err, bytesWritten, buffers) => {
|
|
100
|
+
if (err) return reject(err);
|
|
101
|
+
resolve({
|
|
102
|
+
bytesWritten,
|
|
103
|
+
buffers
|
|
104
|
+
});
|
|
105
|
+
});
|
|
106
|
+
});
|
|
107
|
+
};
|
|
108
|
+
if (typeof fs.realpath.native === "function") exports.realpath.native = u(fs.realpath.native);
|
|
109
|
+
else process.emitWarning("fs.realpath.native is not a function. Is fs being monkey-patched?", "Warning", "fs-extra-WARN0003");
|
|
110
|
+
}));
|
|
111
|
+
//#endregion
|
|
112
|
+
export default require_fs();
|
|
113
|
+
export { require_fs };
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { __commonJSMin } from "../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_fs } from "./fs/index.js";
|
|
3
|
+
import { require_mkdirs } from "./mkdirs/index.js";
|
|
4
|
+
import { require_path_exists } from "./path-exists/index.js";
|
|
5
|
+
import { require_copy } from "./copy/index.js";
|
|
6
|
+
import { require_remove } from "./remove/index.js";
|
|
7
|
+
import { require_empty } from "./empty/index.js";
|
|
8
|
+
import { require_ensure } from "./ensure/index.js";
|
|
9
|
+
import { require_output_file } from "./output-file/index.js";
|
|
10
|
+
import { require_json } from "./json/index.js";
|
|
11
|
+
import { require_move } from "./move/index.js";
|
|
12
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/index.js
|
|
13
|
+
var require_lib = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
14
|
+
module.exports = {
|
|
15
|
+
...require_fs(),
|
|
16
|
+
...require_copy(),
|
|
17
|
+
...require_empty(),
|
|
18
|
+
...require_ensure(),
|
|
19
|
+
...require_json(),
|
|
20
|
+
...require_mkdirs(),
|
|
21
|
+
...require_move(),
|
|
22
|
+
...require_output_file(),
|
|
23
|
+
...require_path_exists(),
|
|
24
|
+
...require_remove()
|
|
25
|
+
};
|
|
26
|
+
}));
|
|
27
|
+
//#endregion
|
|
28
|
+
export default require_lib();
|
|
29
|
+
export { require_lib };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { __commonJSMin } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_universalify } from "../../../../../universalify@2.0.1/node_modules/universalify/index.js";
|
|
3
|
+
import { require_jsonfile } from "./jsonfile.js";
|
|
4
|
+
import { require_output_json } from "./output-json.js";
|
|
5
|
+
import { require_output_json_sync } from "./output-json-sync.js";
|
|
6
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/json/index.js
|
|
7
|
+
var require_json = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
8
|
+
const u = require_universalify().fromPromise;
|
|
9
|
+
const jsonFile = require_jsonfile();
|
|
10
|
+
jsonFile.outputJson = u(require_output_json());
|
|
11
|
+
jsonFile.outputJsonSync = require_output_json_sync();
|
|
12
|
+
jsonFile.outputJSON = jsonFile.outputJson;
|
|
13
|
+
jsonFile.outputJSONSync = jsonFile.outputJsonSync;
|
|
14
|
+
jsonFile.writeJSON = jsonFile.writeJson;
|
|
15
|
+
jsonFile.writeJSONSync = jsonFile.writeJsonSync;
|
|
16
|
+
jsonFile.readJSON = jsonFile.readJson;
|
|
17
|
+
jsonFile.readJSONSync = jsonFile.readJsonSync;
|
|
18
|
+
module.exports = jsonFile;
|
|
19
|
+
}));
|
|
20
|
+
//#endregion
|
|
21
|
+
export default require_json();
|
|
22
|
+
export { require_json };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { __commonJSMin } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_jsonfile as require_jsonfile$1 } from "../../../../../jsonfile@6.2.0/node_modules/jsonfile/index.js";
|
|
3
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/json/jsonfile.js
|
|
4
|
+
var require_jsonfile = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
5
|
+
const jsonFile = require_jsonfile$1();
|
|
6
|
+
module.exports = {
|
|
7
|
+
readJson: jsonFile.readFile,
|
|
8
|
+
readJsonSync: jsonFile.readFileSync,
|
|
9
|
+
writeJson: jsonFile.writeFile,
|
|
10
|
+
writeJsonSync: jsonFile.writeFileSync
|
|
11
|
+
};
|
|
12
|
+
}));
|
|
13
|
+
//#endregion
|
|
14
|
+
export default require_jsonfile();
|
|
15
|
+
export { require_jsonfile };
|
package/dist/node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/json/output-json-sync.js
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { __commonJSMin } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_utils } from "../../../../../jsonfile@6.2.0/node_modules/jsonfile/utils.js";
|
|
3
|
+
import { require_output_file } from "../output-file/index.js";
|
|
4
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/json/output-json-sync.js
|
|
5
|
+
var require_output_json_sync = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
6
|
+
const { stringify } = require_utils();
|
|
7
|
+
const { outputFileSync } = require_output_file();
|
|
8
|
+
function outputJsonSync(file, data, options) {
|
|
9
|
+
outputFileSync(file, stringify(data, options), options);
|
|
10
|
+
}
|
|
11
|
+
module.exports = outputJsonSync;
|
|
12
|
+
}));
|
|
13
|
+
//#endregion
|
|
14
|
+
export default require_output_json_sync();
|
|
15
|
+
export { require_output_json_sync };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { __commonJSMin } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_utils } from "../../../../../jsonfile@6.2.0/node_modules/jsonfile/utils.js";
|
|
3
|
+
import { require_output_file } from "../output-file/index.js";
|
|
4
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/json/output-json.js
|
|
5
|
+
var require_output_json = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
6
|
+
const { stringify } = require_utils();
|
|
7
|
+
const { outputFile } = require_output_file();
|
|
8
|
+
async function outputJson(file, data, options = {}) {
|
|
9
|
+
await outputFile(file, stringify(data, options), options);
|
|
10
|
+
}
|
|
11
|
+
module.exports = outputJson;
|
|
12
|
+
}));
|
|
13
|
+
//#endregion
|
|
14
|
+
export default require_output_json();
|
|
15
|
+
export { require_output_json };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { __commonJSMin } from "../../../../../../../_virtual/_rolldown/runtime.js";
|
|
2
|
+
import { require_universalify } from "../../../../../universalify@2.0.1/node_modules/universalify/index.js";
|
|
3
|
+
import { require_make_dir } from "./make-dir.js";
|
|
4
|
+
//#region node_modules/.pnpm/fs-extra@11.3.4/node_modules/fs-extra/lib/mkdirs/index.js
|
|
5
|
+
var require_mkdirs = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
6
|
+
const u = require_universalify().fromPromise;
|
|
7
|
+
const { makeDir: _makeDir, makeDirSync } = require_make_dir();
|
|
8
|
+
const makeDir = u(_makeDir);
|
|
9
|
+
module.exports = {
|
|
10
|
+
mkdirs: makeDir,
|
|
11
|
+
mkdirsSync: makeDirSync,
|
|
12
|
+
mkdirp: makeDir,
|
|
13
|
+
mkdirpSync: makeDirSync,
|
|
14
|
+
ensureDir: makeDir,
|
|
15
|
+
ensureDirSync: makeDirSync
|
|
16
|
+
};
|
|
17
|
+
}));
|
|
18
|
+
//#endregion
|
|
19
|
+
export default require_mkdirs();
|
|
20
|
+
export { require_mkdirs };
|