pnpm 8.6.2 → 8.6.4
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/dist/node_modules/.modules.yaml +81 -24
- package/dist/node_modules/.pnpm/lock.yaml +235 -91
- package/dist/node_modules/@isaacs/cliui/LICENSE.txt +14 -0
- package/dist/node_modules/@isaacs/cliui/build/index.cjs +317 -0
- package/dist/node_modules/@isaacs/cliui/build/index.d.cts +43 -0
- package/dist/node_modules/@isaacs/cliui/build/lib/index.js +302 -0
- package/dist/node_modules/@isaacs/cliui/index.mjs +14 -0
- package/dist/node_modules/@isaacs/cliui/node_modules/string-width/index.js +54 -0
- package/dist/node_modules/@isaacs/cliui/node_modules/string-width/license +9 -0
- package/dist/node_modules/@isaacs/cliui/node_modules/string-width/package.json +59 -0
- package/dist/node_modules/@isaacs/cliui/package.json +86 -0
- package/dist/node_modules/@npmcli/fs/lib/cp/index.js +1 -1
- package/dist/node_modules/@npmcli/fs/lib/cp/polyfill.js +2 -2
- package/dist/node_modules/@npmcli/fs/lib/index.js +11 -10
- package/dist/node_modules/@npmcli/fs/lib/move-file.js +78 -0
- package/dist/node_modules/@npmcli/fs/lib/readdir-scoped.js +20 -0
- package/dist/node_modules/@npmcli/fs/lib/with-temp-dir.js +4 -6
- package/dist/node_modules/@npmcli/fs/package.json +11 -9
- package/dist/node_modules/@pkgjs/parseargs/LICENSE +201 -0
- package/dist/node_modules/@pkgjs/parseargs/index.js +396 -0
- package/dist/node_modules/@pkgjs/parseargs/internal/errors.js +47 -0
- package/dist/node_modules/@pkgjs/parseargs/internal/primordials.js +393 -0
- package/dist/node_modules/@pkgjs/parseargs/internal/util.js +14 -0
- package/dist/node_modules/@pkgjs/parseargs/internal/validators.js +89 -0
- package/dist/node_modules/@pkgjs/parseargs/package.json +36 -0
- package/dist/node_modules/@pkgjs/parseargs/utils.js +198 -0
- package/dist/node_modules/ansi-regex/index.js +3 -5
- package/dist/node_modules/ansi-regex/license +1 -1
- package/dist/node_modules/ansi-regex/package.json +9 -6
- package/dist/node_modules/ansi-styles/index.js +223 -0
- package/dist/node_modules/ansi-styles/license +9 -0
- package/dist/node_modules/ansi-styles/package.json +54 -0
- package/dist/node_modules/cacache/lib/content/read.js +1 -76
- package/dist/node_modules/cacache/lib/content/rm.js +2 -4
- package/dist/node_modules/cacache/lib/content/write.js +40 -24
- package/dist/node_modules/cacache/lib/entry-index.js +25 -99
- package/dist/node_modules/cacache/lib/get.js +1 -56
- package/dist/node_modules/cacache/lib/index.js +0 -3
- package/dist/node_modules/cacache/lib/rm.js +5 -5
- package/dist/node_modules/cacache/lib/util/glob.js +7 -0
- package/dist/node_modules/cacache/lib/util/tmp.js +3 -10
- package/dist/node_modules/cacache/lib/verify.js +28 -28
- package/dist/node_modules/cacache/node_modules/glob/LICENSE +1 -1
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/package.json +4 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/bin.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/bin.js +270 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/bin.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/glob.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/glob.js +234 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/glob.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/has-magic.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/has-magic.js +27 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/has-magic.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/ignore.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/ignore.js +103 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/ignore.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/index.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/index.js +68 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/index.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/pattern.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/pattern.js +219 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/pattern.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/processor.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/processor.js +309 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/processor.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/walker.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/walker.js +358 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/cjs/src/walker.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/glob.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/glob.js +230 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/glob.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/has-magic.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/has-magic.js +23 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/has-magic.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/ignore.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/ignore.js +99 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/ignore.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/index.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/index.js +56 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/index.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/package.json +4 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/pattern.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/pattern.js +215 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/pattern.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/processor.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/processor.js +302 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/processor.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/walker.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/walker.js +352 -0
- package/dist/node_modules/cacache/node_modules/glob/dist/mjs/walker.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/glob/package.json +78 -35
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/assert-valid-pattern.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/assert-valid-pattern.js +14 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/assert-valid-pattern.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/ast.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/ast.js +589 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/ast.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/brace-expressions.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/brace-expressions.js +152 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/brace-expressions.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/escape.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/escape.js +22 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/escape.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/index.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/index.js +1011 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/index.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/package.json +3 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/unescape.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/unescape.js +24 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/cjs/unescape.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/assert-valid-pattern.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/assert-valid-pattern.js +10 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/assert-valid-pattern.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/ast.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/ast.js +585 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/ast.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/brace-expressions.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/brace-expressions.js +148 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/brace-expressions.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/escape.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/escape.js +18 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/escape.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/index.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/index.js +995 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/index.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/package.json +3 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/unescape.d.ts.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/unescape.js +20 -0
- package/dist/node_modules/cacache/node_modules/minimatch/dist/mjs/unescape.js.map +1 -0
- package/dist/node_modules/cacache/node_modules/minimatch/package.json +66 -15
- package/dist/node_modules/cacache/package.json +19 -21
- package/dist/node_modules/color-convert/LICENSE +21 -0
- package/dist/node_modules/color-convert/conversions.js +839 -0
- package/dist/node_modules/color-convert/index.js +81 -0
- package/dist/node_modules/color-convert/package.json +48 -0
- package/dist/node_modules/color-convert/route.js +97 -0
- package/dist/node_modules/color-name/LICENSE +8 -0
- package/dist/node_modules/color-name/index.js +152 -0
- package/dist/node_modules/color-name/package.json +28 -0
- package/dist/node_modules/cross-spawn/LICENSE +21 -0
- package/dist/node_modules/cross-spawn/index.js +39 -0
- package/dist/node_modules/cross-spawn/lib/enoent.js +59 -0
- package/dist/node_modules/cross-spawn/lib/parse.js +91 -0
- package/dist/node_modules/cross-spawn/lib/util/escape.js +45 -0
- package/dist/node_modules/cross-spawn/lib/util/readShebang.js +23 -0
- package/dist/node_modules/cross-spawn/lib/util/resolveCommand.js +52 -0
- package/dist/node_modules/cross-spawn/package.json +73 -0
- package/dist/node_modules/eastasianwidth/eastasianwidth.js +311 -0
- package/dist/node_modules/eastasianwidth/package.json +18 -0
- package/dist/node_modules/emoji-regex/RGI_Emoji.js +6 -0
- package/dist/node_modules/emoji-regex/es2015/RGI_Emoji.js +6 -0
- package/dist/node_modules/emoji-regex/es2015/index.js +1 -1
- package/dist/node_modules/emoji-regex/es2015/text.js +1 -1
- package/dist/node_modules/emoji-regex/index.js +1 -1
- package/dist/node_modules/emoji-regex/package.json +13 -11
- package/dist/node_modules/emoji-regex/text.js +1 -1
- package/dist/node_modules/exponential-backoff/LICENSE +202 -0
- package/dist/node_modules/exponential-backoff/dist/backoff.js +118 -0
- package/dist/node_modules/exponential-backoff/dist/backoff.js.map +1 -0
- package/dist/node_modules/exponential-backoff/dist/delay/always/always.delay.js +25 -0
- package/dist/node_modules/exponential-backoff/dist/delay/always/always.delay.js.map +1 -0
- package/dist/node_modules/exponential-backoff/dist/delay/delay.base.js +45 -0
- package/dist/node_modules/exponential-backoff/dist/delay/delay.base.js.map +1 -0
- package/dist/node_modules/exponential-backoff/dist/delay/delay.factory.js +17 -0
- package/dist/node_modules/exponential-backoff/dist/delay/delay.factory.js.map +1 -0
- package/dist/node_modules/exponential-backoff/dist/delay/delay.interface.js +3 -0
- package/dist/node_modules/exponential-backoff/dist/delay/delay.interface.js.map +1 -0
- package/dist/node_modules/exponential-backoff/dist/delay/skip-first/skip-first.delay.js +82 -0
- package/dist/node_modules/exponential-backoff/dist/delay/skip-first/skip-first.delay.js.map +1 -0
- package/dist/node_modules/exponential-backoff/dist/jitter/full/full.jitter.js +8 -0
- package/dist/node_modules/exponential-backoff/dist/jitter/full/full.jitter.js.map +1 -0
- package/dist/node_modules/exponential-backoff/dist/jitter/jitter.factory.js +15 -0
- package/dist/node_modules/exponential-backoff/dist/jitter/jitter.factory.js.map +1 -0
- package/dist/node_modules/exponential-backoff/dist/jitter/no/no.jitter.js +7 -0
- package/dist/node_modules/exponential-backoff/dist/jitter/no/no.jitter.js.map +1 -0
- package/dist/node_modules/exponential-backoff/dist/options.js +31 -0
- package/dist/node_modules/exponential-backoff/dist/options.js.map +1 -0
- package/dist/node_modules/exponential-backoff/package.json +61 -0
- package/dist/node_modules/{promise-inflight → foreground-child}/LICENSE +5 -4
- package/dist/node_modules/foreground-child/dist/cjs/all-signals.d.ts.map +1 -0
- package/dist/node_modules/foreground-child/dist/cjs/all-signals.js +58 -0
- package/dist/node_modules/foreground-child/dist/cjs/all-signals.js.map +1 -0
- package/dist/node_modules/foreground-child/dist/cjs/index.d.ts.map +1 -0
- package/dist/node_modules/foreground-child/dist/cjs/index.js +154 -0
- package/dist/node_modules/foreground-child/dist/cjs/index.js.map +1 -0
- package/dist/node_modules/foreground-child/dist/cjs/package.json +3 -0
- package/dist/node_modules/foreground-child/dist/cjs/watchdog.d.ts.map +1 -0
- package/dist/node_modules/foreground-child/dist/cjs/watchdog.js +43 -0
- package/dist/node_modules/foreground-child/dist/cjs/watchdog.js.map +1 -0
- package/dist/node_modules/foreground-child/dist/mjs/all-signals.d.ts.map +1 -0
- package/dist/node_modules/foreground-child/dist/mjs/all-signals.js +52 -0
- package/dist/node_modules/foreground-child/dist/mjs/all-signals.js.map +1 -0
- package/dist/node_modules/foreground-child/dist/mjs/index.d.ts.map +1 -0
- package/dist/node_modules/foreground-child/dist/mjs/index.js +146 -0
- package/dist/node_modules/foreground-child/dist/mjs/index.js.map +1 -0
- package/dist/node_modules/foreground-child/dist/mjs/package.json +3 -0
- package/dist/node_modules/foreground-child/dist/mjs/watchdog.d.ts.map +1 -0
- package/dist/node_modules/foreground-child/dist/mjs/watchdog.js +39 -0
- package/dist/node_modules/foreground-child/dist/mjs/watchdog.js.map +1 -0
- package/dist/node_modules/foreground-child/package.json +83 -0
- package/dist/node_modules/fs-minipass/lib/index.js +443 -0
- package/dist/node_modules/fs-minipass/package.json +28 -13
- package/dist/node_modules/gauge/node_modules/ansi-regex/index.js +10 -0
- package/dist/node_modules/gauge/node_modules/ansi-regex/license +9 -0
- package/dist/node_modules/gauge/node_modules/ansi-regex/package.json +55 -0
- package/dist/node_modules/gauge/node_modules/signal-exit/LICENSE.txt +16 -0
- package/dist/node_modules/gauge/node_modules/signal-exit/package.json +38 -0
- package/dist/node_modules/gauge/node_modules/strip-ansi/index.js +4 -0
- package/dist/node_modules/gauge/node_modules/strip-ansi/license +9 -0
- package/dist/node_modules/gauge/node_modules/strip-ansi/package.json +54 -0
- package/dist/node_modules/jackspeak/dist/cjs/index.d.ts.map +1 -0
- package/dist/node_modules/jackspeak/dist/cjs/index.js +723 -0
- package/dist/node_modules/jackspeak/dist/cjs/index.js.map +1 -0
- package/dist/node_modules/jackspeak/dist/cjs/package.json +3 -0
- package/dist/node_modules/jackspeak/dist/cjs/parse-args-cjs.d.ts.map +1 -0
- package/dist/node_modules/jackspeak/dist/cjs/parse-args-cjs.js.map +1 -0
- package/dist/node_modules/jackspeak/dist/cjs/parse-args.js +42 -0
- package/dist/node_modules/jackspeak/dist/mjs/index.d.ts.map +1 -0
- package/dist/node_modules/jackspeak/dist/mjs/index.js +713 -0
- package/dist/node_modules/jackspeak/dist/mjs/index.js.map +1 -0
- package/dist/node_modules/jackspeak/dist/mjs/package.json +3 -0
- package/dist/node_modules/jackspeak/dist/mjs/parse-args-esm.d.ts.map +1 -0
- package/dist/node_modules/jackspeak/dist/mjs/parse-args-esm.js.map +1 -0
- package/dist/node_modules/jackspeak/dist/mjs/parse-args.js +19 -0
- package/dist/node_modules/jackspeak/package.json +98 -0
- package/dist/node_modules/make-fetch-happen/lib/cache/entry.js +26 -1
- package/dist/node_modules/make-fetch-happen/lib/options.js +2 -0
- package/dist/node_modules/make-fetch-happen/lib/remote.js +1 -1
- package/dist/node_modules/make-fetch-happen/package.json +16 -17
- package/dist/node_modules/minipass/LICENSE +1 -1
- package/dist/node_modules/minipass/index.js +299 -246
- package/dist/node_modules/minipass/package.json +27 -7
- package/dist/node_modules/{tar → minipass-collect}/node_modules/minipass/LICENSE +1 -1
- package/dist/node_modules/minipass-collect/node_modules/minipass/index.js +649 -0
- package/dist/node_modules/{tar → minipass-collect}/node_modules/minipass/package.json +7 -27
- package/dist/node_modules/minipass-fetch/lib/blob.js +1 -1
- package/dist/node_modules/minipass-fetch/lib/body.js +1 -1
- package/dist/node_modules/minipass-fetch/lib/index.js +15 -3
- package/dist/node_modules/minipass-fetch/lib/request.js +2 -1
- package/dist/node_modules/minipass-fetch/package.json +13 -11
- package/dist/node_modules/minipass-flush/node_modules/minipass/LICENSE +15 -0
- package/dist/node_modules/minipass-flush/node_modules/minipass/index.js +649 -0
- package/dist/node_modules/minipass-flush/node_modules/minipass/package.json +56 -0
- package/dist/node_modules/minipass-pipeline/node_modules/minipass/LICENSE +15 -0
- package/dist/node_modules/minipass-pipeline/node_modules/minipass/index.js +649 -0
- package/dist/node_modules/minipass-pipeline/node_modules/minipass/package.json +56 -0
- package/dist/node_modules/minipass-sized/node_modules/minipass/LICENSE +15 -0
- package/dist/node_modules/minipass-sized/node_modules/minipass/index.js +649 -0
- package/dist/node_modules/minipass-sized/node_modules/minipass/package.json +56 -0
- package/dist/node_modules/minizlib/node_modules/minipass/LICENSE +15 -0
- package/dist/node_modules/minizlib/node_modules/minipass/index.js +649 -0
- package/dist/node_modules/minizlib/node_modules/minipass/package.json +56 -0
- package/dist/node_modules/node-gyp/.github/workflows/tests.yml +9 -6
- package/dist/node_modules/node-gyp/gyp/pylib/gyp/generator/eclipse.py +1 -1
- package/dist/node_modules/node-gyp/gyp/pylib/gyp/xcodeproj_file.py +1 -1
- package/dist/node_modules/node-gyp/lib/find-visualstudio.js +13 -2
- package/dist/node_modules/node-gyp/lib/install.js +174 -92
- package/dist/node_modules/node-gyp/package.json +7 -6
- package/dist/node_modules/node-gyp/update-gyp.py +1 -1
- package/dist/node_modules/path-key/index.js +16 -0
- package/dist/node_modules/path-key/license +9 -0
- package/dist/node_modules/path-key/package.json +39 -0
- package/dist/node_modules/path-scurry/dist/cjs/index.d.ts.map +1 -0
- package/dist/node_modules/path-scurry/dist/cjs/index.js +1995 -0
- package/dist/node_modules/path-scurry/dist/cjs/index.js.map +1 -0
- package/dist/node_modules/path-scurry/dist/cjs/package.json +3 -0
- package/dist/node_modules/path-scurry/dist/mjs/index.d.ts.map +1 -0
- package/dist/node_modules/path-scurry/dist/mjs/index.js +1960 -0
- package/dist/node_modules/path-scurry/dist/mjs/index.js.map +1 -0
- package/dist/node_modules/path-scurry/dist/mjs/package.json +3 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/LICENSE +15 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/cjs/index.d.ts.map +1 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/cjs/index.js +1395 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/cjs/index.js.map +1 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/cjs/index.min.js +2 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/cjs/index.min.js.map +7 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/cjs/package.json +3 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/mjs/index.d.ts.map +1 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/mjs/index.js +1391 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/mjs/index.js.map +1 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/mjs/index.min.js +2 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/mjs/index.min.js.map +7 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/dist/mjs/package.json +3 -0
- package/dist/node_modules/path-scurry/node_modules/lru-cache/package.json +108 -0
- package/dist/node_modules/path-scurry/package.json +87 -0
- package/dist/node_modules/semver/classes/comparator.js +2 -1
- package/dist/node_modules/semver/classes/range.js +40 -27
- package/dist/node_modules/semver/classes/semver.js +5 -3
- package/dist/node_modules/semver/functions/coerce.js +1 -1
- package/dist/node_modules/semver/functions/diff.js +31 -20
- package/dist/node_modules/semver/internal/constants.js +5 -0
- package/dist/node_modules/semver/internal/re.js +30 -4
- package/dist/node_modules/semver/package.json +4 -4
- package/dist/node_modules/shebang-command/index.js +19 -0
- package/dist/node_modules/shebang-command/license +9 -0
- package/dist/node_modules/shebang-command/package.json +34 -0
- package/dist/node_modules/shebang-regex/index.js +2 -0
- package/dist/node_modules/shebang-regex/license +9 -0
- package/dist/node_modules/shebang-regex/package.json +35 -0
- package/dist/node_modules/signal-exit/LICENSE.txt +1 -1
- package/dist/node_modules/signal-exit/dist/cjs/browser.d.ts.map +1 -0
- package/dist/node_modules/signal-exit/dist/cjs/browser.js +10 -0
- package/dist/node_modules/signal-exit/dist/cjs/browser.js.map +1 -0
- package/dist/node_modules/signal-exit/dist/cjs/index.d.ts.map +1 -0
- package/dist/node_modules/signal-exit/dist/cjs/index.js +272 -0
- package/dist/node_modules/signal-exit/dist/cjs/index.js.map +1 -0
- package/dist/node_modules/signal-exit/dist/cjs/package.json +3 -0
- package/dist/node_modules/signal-exit/dist/cjs/signals.d.ts.map +1 -0
- package/dist/node_modules/signal-exit/dist/cjs/signals.js +42 -0
- package/dist/node_modules/signal-exit/dist/cjs/signals.js.map +1 -0
- package/dist/node_modules/signal-exit/dist/mjs/browser.d.ts.map +1 -0
- package/dist/node_modules/signal-exit/dist/mjs/browser.js +4 -0
- package/dist/node_modules/signal-exit/dist/mjs/browser.js.map +1 -0
- package/dist/node_modules/signal-exit/dist/mjs/index.d.ts.map +1 -0
- package/dist/node_modules/signal-exit/dist/mjs/index.js +268 -0
- package/dist/node_modules/signal-exit/dist/mjs/index.js.map +1 -0
- package/dist/node_modules/signal-exit/dist/mjs/package.json +3 -0
- package/dist/node_modules/signal-exit/dist/mjs/signals.d.ts.map +1 -0
- package/dist/node_modules/signal-exit/dist/mjs/signals.js +39 -0
- package/dist/node_modules/signal-exit/dist/mjs/signals.js.map +1 -0
- package/dist/node_modules/signal-exit/package.json +87 -19
- package/dist/node_modules/ssri/lib/index.js +157 -101
- package/dist/node_modules/ssri/package.json +12 -10
- package/dist/node_modules/string-width/node_modules/ansi-regex/index.js +10 -0
- package/dist/node_modules/string-width/node_modules/ansi-regex/license +9 -0
- package/dist/node_modules/string-width/node_modules/ansi-regex/package.json +55 -0
- package/dist/node_modules/string-width/node_modules/emoji-regex/LICENSE-MIT.txt +20 -0
- package/dist/node_modules/string-width/node_modules/emoji-regex/es2015/index.js +6 -0
- package/dist/node_modules/string-width/node_modules/emoji-regex/es2015/text.js +6 -0
- package/dist/node_modules/string-width/node_modules/emoji-regex/index.js +6 -0
- package/dist/node_modules/string-width/node_modules/emoji-regex/package.json +50 -0
- package/dist/node_modules/string-width/node_modules/emoji-regex/text.js +6 -0
- package/dist/node_modules/string-width/node_modules/strip-ansi/index.js +4 -0
- package/dist/node_modules/string-width/node_modules/strip-ansi/license +9 -0
- package/dist/node_modules/string-width/node_modules/strip-ansi/package.json +54 -0
- package/dist/node_modules/string-width-cjs/index.js +47 -0
- package/dist/node_modules/string-width-cjs/license +9 -0
- package/dist/node_modules/string-width-cjs/node_modules/ansi-regex/index.js +10 -0
- package/dist/node_modules/string-width-cjs/node_modules/ansi-regex/license +9 -0
- package/dist/node_modules/string-width-cjs/node_modules/ansi-regex/package.json +55 -0
- package/dist/node_modules/string-width-cjs/node_modules/emoji-regex/LICENSE-MIT.txt +20 -0
- package/dist/node_modules/string-width-cjs/node_modules/emoji-regex/es2015/index.js +6 -0
- package/dist/node_modules/string-width-cjs/node_modules/emoji-regex/es2015/text.js +6 -0
- package/dist/node_modules/string-width-cjs/node_modules/emoji-regex/index.js +6 -0
- package/dist/node_modules/string-width-cjs/node_modules/emoji-regex/package.json +50 -0
- package/dist/node_modules/string-width-cjs/node_modules/emoji-regex/text.js +6 -0
- package/dist/node_modules/string-width-cjs/node_modules/strip-ansi/index.js +4 -0
- package/dist/node_modules/string-width-cjs/node_modules/strip-ansi/license +9 -0
- package/dist/node_modules/string-width-cjs/node_modules/strip-ansi/package.json +54 -0
- package/dist/node_modules/string-width-cjs/package.json +56 -0
- package/dist/node_modules/strip-ansi/index.js +13 -3
- package/dist/node_modules/strip-ansi/license +1 -1
- package/dist/node_modules/strip-ansi/package.json +10 -7
- package/dist/node_modules/strip-ansi-cjs/index.js +4 -0
- package/dist/node_modules/strip-ansi-cjs/license +9 -0
- package/dist/node_modules/strip-ansi-cjs/node_modules/ansi-regex/index.js +10 -0
- package/dist/node_modules/strip-ansi-cjs/node_modules/ansi-regex/license +9 -0
- package/dist/node_modules/strip-ansi-cjs/node_modules/ansi-regex/package.json +55 -0
- package/dist/node_modules/strip-ansi-cjs/package.json +54 -0
- package/dist/node_modules/{infer-owner → tar/node_modules/fs-minipass}/LICENSE +1 -1
- package/dist/node_modules/tar/node_modules/fs-minipass/node_modules/minipass/LICENSE +15 -0
- package/dist/node_modules/tar/node_modules/fs-minipass/node_modules/minipass/index.js +649 -0
- package/dist/node_modules/tar/node_modules/fs-minipass/node_modules/minipass/package.json +56 -0
- package/dist/node_modules/tar/node_modules/fs-minipass/package.json +39 -0
- package/dist/node_modules/unique-filename/package.json +12 -9
- package/dist/node_modules/unique-slug/package.json +10 -7
- package/dist/node_modules/wrap-ansi/index.js +214 -0
- package/dist/node_modules/wrap-ansi/license +9 -0
- package/dist/node_modules/wrap-ansi/node_modules/string-width/index.js +54 -0
- package/dist/node_modules/wrap-ansi/node_modules/string-width/license +9 -0
- package/dist/node_modules/wrap-ansi/node_modules/string-width/package.json +59 -0
- package/dist/node_modules/wrap-ansi/package.json +69 -0
- package/dist/node_modules/wrap-ansi-cjs/index.js +216 -0
- package/dist/node_modules/wrap-ansi-cjs/license +9 -0
- package/dist/node_modules/wrap-ansi-cjs/node_modules/ansi-regex/index.js +10 -0
- package/dist/node_modules/wrap-ansi-cjs/node_modules/ansi-regex/license +9 -0
- package/dist/node_modules/wrap-ansi-cjs/node_modules/ansi-regex/package.json +55 -0
- package/dist/node_modules/wrap-ansi-cjs/node_modules/ansi-styles/index.js +163 -0
- package/dist/node_modules/wrap-ansi-cjs/node_modules/ansi-styles/license +9 -0
- package/dist/node_modules/wrap-ansi-cjs/node_modules/ansi-styles/package.json +56 -0
- package/dist/node_modules/wrap-ansi-cjs/node_modules/strip-ansi/index.js +4 -0
- package/dist/node_modules/wrap-ansi-cjs/node_modules/strip-ansi/license +9 -0
- package/dist/node_modules/wrap-ansi-cjs/node_modules/strip-ansi/package.json +54 -0
- package/dist/node_modules/wrap-ansi-cjs/package.json +62 -0
- package/dist/pnpm.cjs +30877 -17543
- package/package.json +3 -3
- package/dist/node_modules/@gar/promisify/index.js +0 -36
- package/dist/node_modules/@gar/promisify/package.json +0 -32
- package/dist/node_modules/@npmcli/fs/lib/common/owner-sync.js +0 -96
- package/dist/node_modules/@npmcli/fs/lib/common/owner.js +0 -96
- package/dist/node_modules/@npmcli/fs/lib/copy-file.js +0 -16
- package/dist/node_modules/@npmcli/fs/lib/fs.js +0 -14
- package/dist/node_modules/@npmcli/fs/lib/mkdir.js +0 -19
- package/dist/node_modules/@npmcli/fs/lib/mkdtemp.js +0 -23
- package/dist/node_modules/@npmcli/fs/lib/rm/index.js +0 -22
- package/dist/node_modules/@npmcli/fs/lib/rm/polyfill.js +0 -239
- package/dist/node_modules/@npmcli/fs/lib/with-owner-sync.js +0 -21
- package/dist/node_modules/@npmcli/fs/lib/with-owner.js +0 -21
- package/dist/node_modules/@npmcli/fs/lib/write-file.js +0 -14
- package/dist/node_modules/@npmcli/move-file/lib/index.js +0 -185
- package/dist/node_modules/@npmcli/move-file/package.json +0 -47
- package/dist/node_modules/cacache/lib/util/fix-owner.js +0 -145
- package/dist/node_modules/cacache/lib/util/move-file.js +0 -56
- package/dist/node_modules/cacache/node_modules/glob/common.js +0 -244
- package/dist/node_modules/cacache/node_modules/glob/glob.js +0 -790
- package/dist/node_modules/cacache/node_modules/glob/sync.js +0 -486
- package/dist/node_modules/cacache/node_modules/minimatch/lib/path.js +0 -4
- package/dist/node_modules/cacache/node_modules/minimatch/minimatch.js +0 -944
- package/dist/node_modules/infer-owner/index.js +0 -71
- package/dist/node_modules/infer-owner/package.json +0 -26
- package/dist/node_modules/promise-inflight/inflight.js +0 -36
- package/dist/node_modules/promise-inflight/package.json +0 -24
- package/dist/node_modules/tar/node_modules/minipass/index.js +0 -702
- /package/dist/node_modules/@npmcli/fs/lib/{errors.js → cp/errors.js} +0 -0
- /package/dist/node_modules/{signal-exit → gauge/node_modules/signal-exit}/index.js +0 -0
- /package/dist/node_modules/{signal-exit → gauge/node_modules/signal-exit}/signals.js +0 -0
- /package/dist/node_modules/{tar/node_modules/minipass → minipass}/index.mjs +0 -0
- /package/dist/node_modules/{fs-minipass → tar/node_modules/fs-minipass}/index.js +0 -0
|
@@ -1,185 +0,0 @@
|
|
|
1
|
-
const { dirname, join, resolve, relative, isAbsolute } = require('path')
|
|
2
|
-
const rimraf_ = require('rimraf')
|
|
3
|
-
const { promisify } = require('util')
|
|
4
|
-
const {
|
|
5
|
-
access: access_,
|
|
6
|
-
accessSync,
|
|
7
|
-
copyFile: copyFile_,
|
|
8
|
-
copyFileSync,
|
|
9
|
-
readdir: readdir_,
|
|
10
|
-
readdirSync,
|
|
11
|
-
rename: rename_,
|
|
12
|
-
renameSync,
|
|
13
|
-
stat: stat_,
|
|
14
|
-
statSync,
|
|
15
|
-
lstat: lstat_,
|
|
16
|
-
lstatSync,
|
|
17
|
-
symlink: symlink_,
|
|
18
|
-
symlinkSync,
|
|
19
|
-
readlink: readlink_,
|
|
20
|
-
readlinkSync,
|
|
21
|
-
} = require('fs')
|
|
22
|
-
|
|
23
|
-
const access = promisify(access_)
|
|
24
|
-
const copyFile = promisify(copyFile_)
|
|
25
|
-
const readdir = promisify(readdir_)
|
|
26
|
-
const rename = promisify(rename_)
|
|
27
|
-
const stat = promisify(stat_)
|
|
28
|
-
const lstat = promisify(lstat_)
|
|
29
|
-
const symlink = promisify(symlink_)
|
|
30
|
-
const readlink = promisify(readlink_)
|
|
31
|
-
const rimraf = promisify(rimraf_)
|
|
32
|
-
const rimrafSync = rimraf_.sync
|
|
33
|
-
|
|
34
|
-
const mkdirp = require('mkdirp')
|
|
35
|
-
|
|
36
|
-
const pathExists = async path => {
|
|
37
|
-
try {
|
|
38
|
-
await access(path)
|
|
39
|
-
return true
|
|
40
|
-
} catch (er) {
|
|
41
|
-
return er.code !== 'ENOENT'
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
const pathExistsSync = path => {
|
|
46
|
-
try {
|
|
47
|
-
accessSync(path)
|
|
48
|
-
return true
|
|
49
|
-
} catch (er) {
|
|
50
|
-
return er.code !== 'ENOENT'
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
const moveFile = async (source, destination, options = {}, root = true, symlinks = []) => {
|
|
55
|
-
if (!source || !destination) {
|
|
56
|
-
throw new TypeError('`source` and `destination` file required')
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
options = {
|
|
60
|
-
overwrite: true,
|
|
61
|
-
...options,
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
if (!options.overwrite && await pathExists(destination)) {
|
|
65
|
-
throw new Error(`The destination file exists: ${destination}`)
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
await mkdirp(dirname(destination))
|
|
69
|
-
|
|
70
|
-
try {
|
|
71
|
-
await rename(source, destination)
|
|
72
|
-
} catch (error) {
|
|
73
|
-
if (error.code === 'EXDEV' || error.code === 'EPERM') {
|
|
74
|
-
const sourceStat = await lstat(source)
|
|
75
|
-
if (sourceStat.isDirectory()) {
|
|
76
|
-
const files = await readdir(source)
|
|
77
|
-
await Promise.all(files.map((file) =>
|
|
78
|
-
moveFile(join(source, file), join(destination, file), options, false, symlinks)
|
|
79
|
-
))
|
|
80
|
-
} else if (sourceStat.isSymbolicLink()) {
|
|
81
|
-
symlinks.push({ source, destination })
|
|
82
|
-
} else {
|
|
83
|
-
await copyFile(source, destination)
|
|
84
|
-
}
|
|
85
|
-
} else {
|
|
86
|
-
throw error
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
if (root) {
|
|
91
|
-
await Promise.all(symlinks.map(async ({ source: symSource, destination: symDestination }) => {
|
|
92
|
-
let target = await readlink(symSource)
|
|
93
|
-
// junction symlinks in windows will be absolute paths, so we need to
|
|
94
|
-
// make sure they point to the symlink destination
|
|
95
|
-
if (isAbsolute(target)) {
|
|
96
|
-
target = resolve(symDestination, relative(symSource, target))
|
|
97
|
-
}
|
|
98
|
-
// try to determine what the actual file is so we can create the correct
|
|
99
|
-
// type of symlink in windows
|
|
100
|
-
let targetStat = 'file'
|
|
101
|
-
try {
|
|
102
|
-
targetStat = await stat(resolve(dirname(symSource), target))
|
|
103
|
-
if (targetStat.isDirectory()) {
|
|
104
|
-
targetStat = 'junction'
|
|
105
|
-
}
|
|
106
|
-
} catch {
|
|
107
|
-
// targetStat remains 'file'
|
|
108
|
-
}
|
|
109
|
-
await symlink(
|
|
110
|
-
target,
|
|
111
|
-
symDestination,
|
|
112
|
-
targetStat
|
|
113
|
-
)
|
|
114
|
-
}))
|
|
115
|
-
await rimraf(source)
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
const moveFileSync = (source, destination, options = {}, root = true, symlinks = []) => {
|
|
120
|
-
if (!source || !destination) {
|
|
121
|
-
throw new TypeError('`source` and `destination` file required')
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
options = {
|
|
125
|
-
overwrite: true,
|
|
126
|
-
...options,
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
if (!options.overwrite && pathExistsSync(destination)) {
|
|
130
|
-
throw new Error(`The destination file exists: ${destination}`)
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
mkdirp.sync(dirname(destination))
|
|
134
|
-
|
|
135
|
-
try {
|
|
136
|
-
renameSync(source, destination)
|
|
137
|
-
} catch (error) {
|
|
138
|
-
if (error.code === 'EXDEV' || error.code === 'EPERM') {
|
|
139
|
-
const sourceStat = lstatSync(source)
|
|
140
|
-
if (sourceStat.isDirectory()) {
|
|
141
|
-
const files = readdirSync(source)
|
|
142
|
-
for (const file of files) {
|
|
143
|
-
moveFileSync(join(source, file), join(destination, file), options, false, symlinks)
|
|
144
|
-
}
|
|
145
|
-
} else if (sourceStat.isSymbolicLink()) {
|
|
146
|
-
symlinks.push({ source, destination })
|
|
147
|
-
} else {
|
|
148
|
-
copyFileSync(source, destination)
|
|
149
|
-
}
|
|
150
|
-
} else {
|
|
151
|
-
throw error
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
if (root) {
|
|
156
|
-
for (const { source: symSource, destination: symDestination } of symlinks) {
|
|
157
|
-
let target = readlinkSync(symSource)
|
|
158
|
-
// junction symlinks in windows will be absolute paths, so we need to
|
|
159
|
-
// make sure they point to the symlink destination
|
|
160
|
-
if (isAbsolute(target)) {
|
|
161
|
-
target = resolve(symDestination, relative(symSource, target))
|
|
162
|
-
}
|
|
163
|
-
// try to determine what the actual file is so we can create the correct
|
|
164
|
-
// type of symlink in windows
|
|
165
|
-
let targetStat = 'file'
|
|
166
|
-
try {
|
|
167
|
-
targetStat = statSync(resolve(dirname(symSource), target))
|
|
168
|
-
if (targetStat.isDirectory()) {
|
|
169
|
-
targetStat = 'junction'
|
|
170
|
-
}
|
|
171
|
-
} catch {
|
|
172
|
-
// targetStat remains 'file'
|
|
173
|
-
}
|
|
174
|
-
symlinkSync(
|
|
175
|
-
target,
|
|
176
|
-
symDestination,
|
|
177
|
-
targetStat
|
|
178
|
-
)
|
|
179
|
-
}
|
|
180
|
-
rimrafSync(source)
|
|
181
|
-
}
|
|
182
|
-
}
|
|
183
|
-
|
|
184
|
-
module.exports = moveFile
|
|
185
|
-
module.exports.sync = moveFileSync
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@npmcli/move-file",
|
|
3
|
-
"version": "2.0.1",
|
|
4
|
-
"files": [
|
|
5
|
-
"bin/",
|
|
6
|
-
"lib/"
|
|
7
|
-
],
|
|
8
|
-
"main": "lib/index.js",
|
|
9
|
-
"description": "move a file (fork of move-file)",
|
|
10
|
-
"dependencies": {
|
|
11
|
-
"mkdirp": "^1.0.4",
|
|
12
|
-
"rimraf": "^3.0.2"
|
|
13
|
-
},
|
|
14
|
-
"devDependencies": {
|
|
15
|
-
"@npmcli/eslint-config": "^3.0.1",
|
|
16
|
-
"@npmcli/template-oss": "3.5.0",
|
|
17
|
-
"tap": "^16.0.1"
|
|
18
|
-
},
|
|
19
|
-
"scripts": {
|
|
20
|
-
"test": "tap",
|
|
21
|
-
"snap": "tap",
|
|
22
|
-
"preversion": "npm test",
|
|
23
|
-
"postversion": "npm publish",
|
|
24
|
-
"prepublishOnly": "git push origin --follow-tags",
|
|
25
|
-
"lint": "eslint \"**/*.js\"",
|
|
26
|
-
"postlint": "template-oss-check",
|
|
27
|
-
"template-oss-apply": "template-oss-apply --force",
|
|
28
|
-
"lintfix": "npm run lint -- --fix",
|
|
29
|
-
"posttest": "npm run lint"
|
|
30
|
-
},
|
|
31
|
-
"repository": {
|
|
32
|
-
"type": "git",
|
|
33
|
-
"url": "https://github.com/npm/move-file.git"
|
|
34
|
-
},
|
|
35
|
-
"tap": {
|
|
36
|
-
"check-coverage": true
|
|
37
|
-
},
|
|
38
|
-
"license": "MIT",
|
|
39
|
-
"engines": {
|
|
40
|
-
"node": "^12.13.0 || ^14.15.0 || >=16.0.0"
|
|
41
|
-
},
|
|
42
|
-
"author": "GitHub Inc.",
|
|
43
|
-
"templateOSS": {
|
|
44
|
-
"//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.",
|
|
45
|
-
"version": "3.5.0"
|
|
46
|
-
}
|
|
47
|
-
}
|
|
@@ -1,145 +0,0 @@
|
|
|
1
|
-
'use strict'
|
|
2
|
-
|
|
3
|
-
const util = require('util')
|
|
4
|
-
|
|
5
|
-
const chownr = util.promisify(require('chownr'))
|
|
6
|
-
const mkdirp = require('mkdirp')
|
|
7
|
-
const inflight = require('promise-inflight')
|
|
8
|
-
const inferOwner = require('infer-owner')
|
|
9
|
-
|
|
10
|
-
// Memoize getuid()/getgid() calls.
|
|
11
|
-
// patch process.setuid/setgid to invalidate cached value on change
|
|
12
|
-
const self = { uid: null, gid: null }
|
|
13
|
-
const getSelf = () => {
|
|
14
|
-
if (typeof self.uid !== 'number') {
|
|
15
|
-
self.uid = process.getuid()
|
|
16
|
-
const setuid = process.setuid
|
|
17
|
-
process.setuid = (uid) => {
|
|
18
|
-
self.uid = null
|
|
19
|
-
process.setuid = setuid
|
|
20
|
-
return process.setuid(uid)
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
if (typeof self.gid !== 'number') {
|
|
24
|
-
self.gid = process.getgid()
|
|
25
|
-
const setgid = process.setgid
|
|
26
|
-
process.setgid = (gid) => {
|
|
27
|
-
self.gid = null
|
|
28
|
-
process.setgid = setgid
|
|
29
|
-
return process.setgid(gid)
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
module.exports.chownr = fixOwner
|
|
35
|
-
|
|
36
|
-
async function fixOwner (cache, filepath) {
|
|
37
|
-
if (!process.getuid) {
|
|
38
|
-
// This platform doesn't need ownership fixing
|
|
39
|
-
return
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
getSelf()
|
|
43
|
-
if (self.uid !== 0) {
|
|
44
|
-
// almost certainly can't chown anyway
|
|
45
|
-
return
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
const { uid, gid } = await inferOwner(cache)
|
|
49
|
-
|
|
50
|
-
// No need to override if it's already what we used.
|
|
51
|
-
if (self.uid === uid && self.gid === gid) {
|
|
52
|
-
return
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
return inflight('fixOwner: fixing ownership on ' + filepath, () =>
|
|
56
|
-
chownr(
|
|
57
|
-
filepath,
|
|
58
|
-
typeof uid === 'number' ? uid : self.uid,
|
|
59
|
-
typeof gid === 'number' ? gid : self.gid
|
|
60
|
-
).catch((err) => {
|
|
61
|
-
if (err.code === 'ENOENT') {
|
|
62
|
-
return null
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
throw err
|
|
66
|
-
})
|
|
67
|
-
)
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
module.exports.chownr.sync = fixOwnerSync
|
|
71
|
-
|
|
72
|
-
function fixOwnerSync (cache, filepath) {
|
|
73
|
-
if (!process.getuid) {
|
|
74
|
-
// This platform doesn't need ownership fixing
|
|
75
|
-
return
|
|
76
|
-
}
|
|
77
|
-
const { uid, gid } = inferOwner.sync(cache)
|
|
78
|
-
getSelf()
|
|
79
|
-
if (self.uid !== 0) {
|
|
80
|
-
// almost certainly can't chown anyway
|
|
81
|
-
return
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
if (self.uid === uid && self.gid === gid) {
|
|
85
|
-
// No need to override if it's already what we used.
|
|
86
|
-
return
|
|
87
|
-
}
|
|
88
|
-
try {
|
|
89
|
-
chownr.sync(
|
|
90
|
-
filepath,
|
|
91
|
-
typeof uid === 'number' ? uid : self.uid,
|
|
92
|
-
typeof gid === 'number' ? gid : self.gid
|
|
93
|
-
)
|
|
94
|
-
} catch (err) {
|
|
95
|
-
// only catch ENOENT, any other error is a problem.
|
|
96
|
-
if (err.code === 'ENOENT') {
|
|
97
|
-
return null
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
throw err
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
module.exports.mkdirfix = mkdirfix
|
|
105
|
-
|
|
106
|
-
async function mkdirfix (cache, p, cb) {
|
|
107
|
-
// we have to infer the owner _before_ making the directory, even though
|
|
108
|
-
// we aren't going to use the results, since the cache itself might not
|
|
109
|
-
// exist yet. If we mkdirp it, then our current uid/gid will be assumed
|
|
110
|
-
// to be correct if it creates the cache folder in the process.
|
|
111
|
-
await inferOwner(cache)
|
|
112
|
-
try {
|
|
113
|
-
const made = await mkdirp(p)
|
|
114
|
-
if (made) {
|
|
115
|
-
await fixOwner(cache, made)
|
|
116
|
-
return made
|
|
117
|
-
}
|
|
118
|
-
} catch (err) {
|
|
119
|
-
if (err.code === 'EEXIST') {
|
|
120
|
-
await fixOwner(cache, p)
|
|
121
|
-
return null
|
|
122
|
-
}
|
|
123
|
-
throw err
|
|
124
|
-
}
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
module.exports.mkdirfix.sync = mkdirfixSync
|
|
128
|
-
|
|
129
|
-
function mkdirfixSync (cache, p) {
|
|
130
|
-
try {
|
|
131
|
-
inferOwner.sync(cache)
|
|
132
|
-
const made = mkdirp.sync(p)
|
|
133
|
-
if (made) {
|
|
134
|
-
fixOwnerSync(cache, made)
|
|
135
|
-
return made
|
|
136
|
-
}
|
|
137
|
-
} catch (err) {
|
|
138
|
-
if (err.code === 'EEXIST') {
|
|
139
|
-
fixOwnerSync(cache, p)
|
|
140
|
-
return null
|
|
141
|
-
} else {
|
|
142
|
-
throw err
|
|
143
|
-
}
|
|
144
|
-
}
|
|
145
|
-
}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
'use strict'
|
|
2
|
-
|
|
3
|
-
const fs = require('@npmcli/fs')
|
|
4
|
-
const move = require('@npmcli/move-file')
|
|
5
|
-
const pinflight = require('promise-inflight')
|
|
6
|
-
|
|
7
|
-
module.exports = moveFile
|
|
8
|
-
|
|
9
|
-
async function moveFile (src, dest) {
|
|
10
|
-
const isWindows = process.platform === 'win32'
|
|
11
|
-
|
|
12
|
-
// This isn't quite an fs.rename -- the assumption is that
|
|
13
|
-
// if `dest` already exists, and we get certain errors while
|
|
14
|
-
// trying to move it, we should just not bother.
|
|
15
|
-
//
|
|
16
|
-
// In the case of cache corruption, users will receive an
|
|
17
|
-
// EINTEGRITY error elsewhere, and can remove the offending
|
|
18
|
-
// content their own way.
|
|
19
|
-
//
|
|
20
|
-
// Note that, as the name suggests, this strictly only supports file moves.
|
|
21
|
-
try {
|
|
22
|
-
await fs.link(src, dest)
|
|
23
|
-
} catch (err) {
|
|
24
|
-
if (isWindows && err.code === 'EPERM') {
|
|
25
|
-
// XXX This is a really weird way to handle this situation, as it
|
|
26
|
-
// results in the src file being deleted even though the dest
|
|
27
|
-
// might not exist. Since we pretty much always write files to
|
|
28
|
-
// deterministic locations based on content hash, this is likely
|
|
29
|
-
// ok (or at worst, just ends in a future cache miss). But it would
|
|
30
|
-
// be worth investigating at some time in the future if this is
|
|
31
|
-
// really what we want to do here.
|
|
32
|
-
} else if (err.code === 'EEXIST' || err.code === 'EBUSY') {
|
|
33
|
-
// file already exists, so whatever
|
|
34
|
-
} else {
|
|
35
|
-
throw err
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
try {
|
|
39
|
-
await Promise.all([
|
|
40
|
-
fs.unlink(src),
|
|
41
|
-
!isWindows && fs.chmod(dest, '0444'),
|
|
42
|
-
])
|
|
43
|
-
} catch (e) {
|
|
44
|
-
return pinflight('cacache-move-file:' + dest, async () => {
|
|
45
|
-
await fs.stat(dest).catch((err) => {
|
|
46
|
-
if (err.code !== 'ENOENT') {
|
|
47
|
-
// Something else is wrong here. Bail bail bail
|
|
48
|
-
throw err
|
|
49
|
-
}
|
|
50
|
-
})
|
|
51
|
-
// file doesn't already exist! let's try a rename -> copy fallback
|
|
52
|
-
// only delete if it successfully copies
|
|
53
|
-
return move(src, dest)
|
|
54
|
-
})
|
|
55
|
-
}
|
|
56
|
-
}
|
|
@@ -1,244 +0,0 @@
|
|
|
1
|
-
exports.setopts = setopts
|
|
2
|
-
exports.ownProp = ownProp
|
|
3
|
-
exports.makeAbs = makeAbs
|
|
4
|
-
exports.finish = finish
|
|
5
|
-
exports.mark = mark
|
|
6
|
-
exports.isIgnored = isIgnored
|
|
7
|
-
exports.childrenIgnored = childrenIgnored
|
|
8
|
-
|
|
9
|
-
function ownProp (obj, field) {
|
|
10
|
-
return Object.prototype.hasOwnProperty.call(obj, field)
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
var fs = require("fs")
|
|
14
|
-
var path = require("path")
|
|
15
|
-
var minimatch = require("minimatch")
|
|
16
|
-
var isAbsolute = require("path").isAbsolute
|
|
17
|
-
var Minimatch = minimatch.Minimatch
|
|
18
|
-
|
|
19
|
-
function alphasort (a, b) {
|
|
20
|
-
return a.localeCompare(b, 'en')
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
function setupIgnores (self, options) {
|
|
24
|
-
self.ignore = options.ignore || []
|
|
25
|
-
|
|
26
|
-
if (!Array.isArray(self.ignore))
|
|
27
|
-
self.ignore = [self.ignore]
|
|
28
|
-
|
|
29
|
-
if (self.ignore.length) {
|
|
30
|
-
self.ignore = self.ignore.map(ignoreMap)
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
// ignore patterns are always in dot:true mode.
|
|
35
|
-
function ignoreMap (pattern) {
|
|
36
|
-
var gmatcher = null
|
|
37
|
-
if (pattern.slice(-3) === '/**') {
|
|
38
|
-
var gpattern = pattern.replace(/(\/\*\*)+$/, '')
|
|
39
|
-
gmatcher = new Minimatch(gpattern, { dot: true })
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
return {
|
|
43
|
-
matcher: new Minimatch(pattern, { dot: true }),
|
|
44
|
-
gmatcher: gmatcher
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
function setopts (self, pattern, options) {
|
|
49
|
-
if (!options)
|
|
50
|
-
options = {}
|
|
51
|
-
|
|
52
|
-
// base-matching: just use globstar for that.
|
|
53
|
-
if (options.matchBase && -1 === pattern.indexOf("/")) {
|
|
54
|
-
if (options.noglobstar) {
|
|
55
|
-
throw new Error("base matching requires globstar")
|
|
56
|
-
}
|
|
57
|
-
pattern = "**/" + pattern
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
self.windowsPathsNoEscape = !!options.windowsPathsNoEscape ||
|
|
61
|
-
options.allowWindowsEscape === false
|
|
62
|
-
if (self.windowsPathsNoEscape) {
|
|
63
|
-
pattern = pattern.replace(/\\/g, '/')
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
self.silent = !!options.silent
|
|
67
|
-
self.pattern = pattern
|
|
68
|
-
self.strict = options.strict !== false
|
|
69
|
-
self.realpath = !!options.realpath
|
|
70
|
-
self.realpathCache = options.realpathCache || Object.create(null)
|
|
71
|
-
self.follow = !!options.follow
|
|
72
|
-
self.dot = !!options.dot
|
|
73
|
-
self.mark = !!options.mark
|
|
74
|
-
self.nodir = !!options.nodir
|
|
75
|
-
if (self.nodir)
|
|
76
|
-
self.mark = true
|
|
77
|
-
self.sync = !!options.sync
|
|
78
|
-
self.nounique = !!options.nounique
|
|
79
|
-
self.nonull = !!options.nonull
|
|
80
|
-
self.nosort = !!options.nosort
|
|
81
|
-
self.nocase = !!options.nocase
|
|
82
|
-
self.stat = !!options.stat
|
|
83
|
-
self.noprocess = !!options.noprocess
|
|
84
|
-
self.absolute = !!options.absolute
|
|
85
|
-
self.fs = options.fs || fs
|
|
86
|
-
|
|
87
|
-
self.maxLength = options.maxLength || Infinity
|
|
88
|
-
self.cache = options.cache || Object.create(null)
|
|
89
|
-
self.statCache = options.statCache || Object.create(null)
|
|
90
|
-
self.symlinks = options.symlinks || Object.create(null)
|
|
91
|
-
|
|
92
|
-
setupIgnores(self, options)
|
|
93
|
-
|
|
94
|
-
self.changedCwd = false
|
|
95
|
-
var cwd = process.cwd()
|
|
96
|
-
if (!ownProp(options, "cwd"))
|
|
97
|
-
self.cwd = path.resolve(cwd)
|
|
98
|
-
else {
|
|
99
|
-
self.cwd = path.resolve(options.cwd)
|
|
100
|
-
self.changedCwd = self.cwd !== cwd
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
self.root = options.root || path.resolve(self.cwd, "/")
|
|
104
|
-
self.root = path.resolve(self.root)
|
|
105
|
-
|
|
106
|
-
// TODO: is an absolute `cwd` supposed to be resolved against `root`?
|
|
107
|
-
// e.g. { cwd: '/test', root: __dirname } === path.join(__dirname, '/test')
|
|
108
|
-
self.cwdAbs = isAbsolute(self.cwd) ? self.cwd : makeAbs(self, self.cwd)
|
|
109
|
-
self.nomount = !!options.nomount
|
|
110
|
-
|
|
111
|
-
if (process.platform === "win32") {
|
|
112
|
-
self.root = self.root.replace(/\\/g, "/")
|
|
113
|
-
self.cwd = self.cwd.replace(/\\/g, "/")
|
|
114
|
-
self.cwdAbs = self.cwdAbs.replace(/\\/g, "/")
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
// disable comments and negation in Minimatch.
|
|
118
|
-
// Note that they are not supported in Glob itself anyway.
|
|
119
|
-
options.nonegate = true
|
|
120
|
-
options.nocomment = true
|
|
121
|
-
|
|
122
|
-
self.minimatch = new Minimatch(pattern, options)
|
|
123
|
-
self.options = self.minimatch.options
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
function finish (self) {
|
|
127
|
-
var nou = self.nounique
|
|
128
|
-
var all = nou ? [] : Object.create(null)
|
|
129
|
-
|
|
130
|
-
for (var i = 0, l = self.matches.length; i < l; i ++) {
|
|
131
|
-
var matches = self.matches[i]
|
|
132
|
-
if (!matches || Object.keys(matches).length === 0) {
|
|
133
|
-
if (self.nonull) {
|
|
134
|
-
// do like the shell, and spit out the literal glob
|
|
135
|
-
var literal = self.minimatch.globSet[i]
|
|
136
|
-
if (nou)
|
|
137
|
-
all.push(literal)
|
|
138
|
-
else
|
|
139
|
-
all[literal] = true
|
|
140
|
-
}
|
|
141
|
-
} else {
|
|
142
|
-
// had matches
|
|
143
|
-
var m = Object.keys(matches)
|
|
144
|
-
if (nou)
|
|
145
|
-
all.push.apply(all, m)
|
|
146
|
-
else
|
|
147
|
-
m.forEach(function (m) {
|
|
148
|
-
all[m] = true
|
|
149
|
-
})
|
|
150
|
-
}
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
if (!nou)
|
|
154
|
-
all = Object.keys(all)
|
|
155
|
-
|
|
156
|
-
if (!self.nosort)
|
|
157
|
-
all = all.sort(alphasort)
|
|
158
|
-
|
|
159
|
-
// at *some* point we statted all of these
|
|
160
|
-
if (self.mark) {
|
|
161
|
-
for (var i = 0; i < all.length; i++) {
|
|
162
|
-
all[i] = self._mark(all[i])
|
|
163
|
-
}
|
|
164
|
-
if (self.nodir) {
|
|
165
|
-
all = all.filter(function (e) {
|
|
166
|
-
var notDir = !(/\/$/.test(e))
|
|
167
|
-
var c = self.cache[e] || self.cache[makeAbs(self, e)]
|
|
168
|
-
if (notDir && c)
|
|
169
|
-
notDir = c !== 'DIR' && !Array.isArray(c)
|
|
170
|
-
return notDir
|
|
171
|
-
})
|
|
172
|
-
}
|
|
173
|
-
}
|
|
174
|
-
|
|
175
|
-
if (self.ignore.length)
|
|
176
|
-
all = all.filter(function(m) {
|
|
177
|
-
return !isIgnored(self, m)
|
|
178
|
-
})
|
|
179
|
-
|
|
180
|
-
self.found = all
|
|
181
|
-
}
|
|
182
|
-
|
|
183
|
-
function mark (self, p) {
|
|
184
|
-
var abs = makeAbs(self, p)
|
|
185
|
-
var c = self.cache[abs]
|
|
186
|
-
var m = p
|
|
187
|
-
if (c) {
|
|
188
|
-
var isDir = c === 'DIR' || Array.isArray(c)
|
|
189
|
-
var slash = p.slice(-1) === '/'
|
|
190
|
-
|
|
191
|
-
if (isDir && !slash)
|
|
192
|
-
m += '/'
|
|
193
|
-
else if (!isDir && slash)
|
|
194
|
-
m = m.slice(0, -1)
|
|
195
|
-
|
|
196
|
-
if (m !== p) {
|
|
197
|
-
var mabs = makeAbs(self, m)
|
|
198
|
-
self.statCache[mabs] = self.statCache[abs]
|
|
199
|
-
self.cache[mabs] = self.cache[abs]
|
|
200
|
-
}
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
return m
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
// lotta situps...
|
|
207
|
-
function makeAbs (self, f) {
|
|
208
|
-
var abs = f
|
|
209
|
-
if (f.charAt(0) === '/') {
|
|
210
|
-
abs = path.join(self.root, f)
|
|
211
|
-
} else if (isAbsolute(f) || f === '') {
|
|
212
|
-
abs = f
|
|
213
|
-
} else if (self.changedCwd) {
|
|
214
|
-
abs = path.resolve(self.cwd, f)
|
|
215
|
-
} else {
|
|
216
|
-
abs = path.resolve(f)
|
|
217
|
-
}
|
|
218
|
-
|
|
219
|
-
if (process.platform === 'win32')
|
|
220
|
-
abs = abs.replace(/\\/g, '/')
|
|
221
|
-
|
|
222
|
-
return abs
|
|
223
|
-
}
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
// Return true, if pattern ends with globstar '**', for the accompanying parent directory.
|
|
227
|
-
// Ex:- If node_modules/** is the pattern, add 'node_modules' to ignore list along with it's contents
|
|
228
|
-
function isIgnored (self, path) {
|
|
229
|
-
if (!self.ignore.length)
|
|
230
|
-
return false
|
|
231
|
-
|
|
232
|
-
return self.ignore.some(function(item) {
|
|
233
|
-
return item.matcher.match(path) || !!(item.gmatcher && item.gmatcher.match(path))
|
|
234
|
-
})
|
|
235
|
-
}
|
|
236
|
-
|
|
237
|
-
function childrenIgnored (self, path) {
|
|
238
|
-
if (!self.ignore.length)
|
|
239
|
-
return false
|
|
240
|
-
|
|
241
|
-
return self.ignore.some(function(item) {
|
|
242
|
-
return !!(item.gmatcher && item.gmatcher.match(path))
|
|
243
|
-
})
|
|
244
|
-
}
|