setup-cpp/dist/modern/setup-cpp.mjs.map

1 line
1.6 MiB
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

{"version":3,"file":"setup-cpp.mjs","sources":["../../node_modules/.pnpm/@actions+core@1.11.1/node_modules/@actions/core/lib/command.js","../../node_modules/.pnpm/@actions+http-client@2.2.3_patch_hash=gqcf2jay7nqqezf3jni6mxu74u/node_modules/@actions/http-client/lib/esnext/proxy.js","../../node_modules/.pnpm/tunnel@0.0.6/node_modules/tunnel/lib/tunnel.js","../../node_modules/.pnpm/@actions+core@1.11.1/node_modules/@actions/core/lib/summary.js","../../node_modules/.pnpm/@actions+io@1.1.3/node_modules/@actions/io/lib/io.js","../../node_modules/.pnpm/@actions+exec@1.1.1/node_modules/@actions/exec/lib/exec.js","../../node_modules/.pnpm/@actions+exec@1.1.1/node_modules/@actions/exec/lib/toolrunner.js","../../node_modules/.pnpm/@actions+core@1.11.1/node_modules/@actions/core/lib/core.js","../../node_modules/.pnpm/@actions+core@1.11.1/node_modules/@actions/core/lib/oidc-utils.js","../../node_modules/.pnpm/@actions+core@1.11.1/node_modules/@actions/core/lib/path-utils.js","../../node_modules/.pnpm/@actions+core@1.11.1/node_modules/@actions/core/lib/platform.js","../../packages/ci-log/dist/index.js","../../node_modules/.pnpm/is-plain-obj@4.1.0/node_modules/is-plain-obj/index.js","../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/index.js","../../node_modules/.pnpm/cross-spawn@7.0.3/node_modules/cross-spawn/lib/util/resolveCommand.js","../../node_modules/.pnpm/cross-spawn@7.0.3/node_modules/cross-spawn/lib/enoent.js","../../node_modules/.pnpm/cross-spawn@7.0.3/node_modules/cross-spawn/index.js","../../node_modules/.pnpm/path-key@4.0.0/node_modules/path-key/index.js","../../node_modules/.pnpm/unicorn-magic@0.3.0/node_modules/unicorn-magic/node.js","../../node_modules/.pnpm/strip-final-newline@4.0.0/node_modules/strip-final-newline/index.js","../../node_modules/.pnpm/is-stream@4.0.1/node_modules/is-stream/index.js","../../node_modules/.pnpm/@sec-ant+readable-stream@0.4.1/node_modules/@sec-ant/readable-stream/dist/ponyfill/asyncIterator.js","../../node_modules/.pnpm/pretty-ms@9.1.0/node_modules/pretty-ms/index.js","../../node_modules/.pnpm/parse-ms@4.0.0/node_modules/parse-ms/index.js","../../node_modules/.pnpm/@sindresorhus+merge-streams@4.0.0/node_modules/@sindresorhus/merge-streams/index.js","../../packages/exec-powershell/dist/index.js","../../node_modules/.pnpm/is-stream@3.0.0/node_modules/is-stream/index.js","../../node_modules/.pnpm/get-stream@6.0.1/node_modules/get-stream/index.js","../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/index.js","../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/kill.js","../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/promise.js","../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/stream.js","../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/pipe.js","../../node_modules/.pnpm/admina@1.0.1/node_modules/admina/dist/index.node.mjs","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/mixin.js","../../node_modules/.pnpm/ext@1.7.0/node_modules/ext/global-this/index.js","../../node_modules/.pnpm/ext@1.7.0/node_modules/ext/global-this/is-implemented.js","../../node_modules/.pnpm/ext@1.7.0/node_modules/ext/global-this/implementation.js","../../node_modules/.pnpm/es6-symbol@3.1.4/node_modules/es6-symbol/validate-symbol.js","../../node_modules/.pnpm/es6-symbol@3.1.4/node_modules/es6-symbol/is-symbol.js","../../node_modules/.pnpm/es6-symbol@3.1.4/node_modules/es6-symbol/index.js","../../node_modules/.pnpm/es6-symbol@3.1.4/node_modules/es6-symbol/is-implemented.js","../../node_modules/.pnpm/es6-symbol@3.1.4/node_modules/es6-symbol/polyfill.js","../../node_modules/.pnpm/es6-symbol@3.1.4/node_modules/es6-symbol/lib/private/generate-name.js","../../node_modules/.pnpm/es6-symbol@3.1.4/node_modules/es6-symbol/lib/private/setup/standard-symbols.js","../../node_modules/.pnpm/es6-symbol@3.1.4/node_modules/es6-symbol/lib/private/setup/symbol-registry.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/array/from/index.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/array/from/is-implemented.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/array/from/shim.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/function/is-arguments.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/function/is-function.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/string/is-string.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/array/#/e-index-of.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/number/is-nan/index.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/number/is-nan/is-implemented.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/number/is-nan/shim.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/map.js","../../node_modules/.pnpm/next-tick@1.1.0/node_modules/next-tick/index.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/is-callable.js","../../node_modules/.pnpm/is-promise@2.2.2/node_modules/is-promise/index.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/ext/promise.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/primitive-set.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/validate-stringifiable-value.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/validate-stringifiable.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/to-short-string-representation.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/safe-to-string.js","../../node_modules/.pnpm/path-exists@5.0.0/node_modules/path-exists/index.js","../../packages/untildify-user/dist/index.js","../../packages/envosman/dist/rc-file.js","../../packages/envosman/dist/add-env.js","../../packages/envosman/dist/utils.js","../../packages/envosman/dist/add-path.js","../../node_modules/.pnpm/time-delta@https+++codeload.github.com+aminya+time-delta+tar.gz+69d91a4/node_modules/time-delta/lib/time-delta.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/classes/range.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/classes/comparator.js","../../node_modules/.pnpm/simple-update-notifier@2.0.0/node_modules/simple-update-notifier/build/index.js","../../node_modules/.pnpm/mri@1.2.0/node_modules/mri/lib/index.mjs","../../packages/setup-apt/dist/alternatives.js","../../packages/setup-apt/dist/apt-env.js","../../packages/setup-apt/dist/get-apt.js","../../node_modules/.pnpm/escape-string-regexp@5.0.0/node_modules/escape-string-regexp/index.js","../../packages/setup-apt/dist/is-installed.js","../../packages/setup-apt/dist/qualify-install.js","../../packages/setup-apt/dist/install.js","../../packages/setup-apt/dist/apt-repository.js","../../packages/setup-apt/dist/apt-key.js","../../packages/setup-brew/dist/install.js","../../packages/setup-brew/dist/install-pack.js","../../src/utils/env/hasDnf.ts","../../src/utils/env/isArch.ts","../../src/utils/env/isUbuntu.ts","../../src/chocolatey/chocolatey.ts","../../src/utils/setup/setupChocoPack.ts","../../src/utils/setup/setupDnfPack.ts","../../src/utils/setup/setupPacmanPack.ts","../../node_modules/.pnpm/patha@0.4.1/node_modules/patha/dist/index.node.mjs","../../node_modules/.pnpm/@actions+tool-cache@2.0.1/node_modules/@actions/tool-cache/lib/tool-cache.js","../../node_modules/.pnpm/retry-as-promised@7.0.4/node_modules/retry-as-promised/dist/index.js","../../src/sevenzip/sevenzip.ts","../../src/utils/setup/extract.ts","../../src/utils/setup/setupBin.ts","../../src/cmake/cmake.ts","../../src/utils/setup/version.ts","../../src/utils/std/index.ts","../../src/python/python.ts","../../src/versions/versions.ts","../../src/utils/env/ubuntu_version.ts","../../src/utils/setup/setupPipPack.ts","../../src/cmakelang/cmakelang.ts","../../src/graphviz/graphviz.ts","../../src/utils/setup/setupDmg.ts","../../src/doxygen/doxygen.ts","../../src/macos-sdk/macos-sdk.ts","../../src/gcc/gccMatcher.ts","../../src/utils/asset/load-assets.ts","../../src/gcc/mingw.ts","../../src/gcc/gcc.ts","../../src/gcovr/gcovr.ts","../../src/infer/infer.ts","../../src/ninja/ninja.ts","../../src/kcov/kcov.ts","../../src/llvm/apple-clang.ts","../../node_modules/.pnpm/msvc-dev-cmd@https+++codeload.github.com+aminya+msvc-dev-cmd+tar.gz+c01f519bd995460228ed3dec4df51df92dc290fd/node_modules/msvc-dev-cmd/lib.js","../../src/vcvarsall/vcvarsall.ts","../../src/installTool.ts","../../node_modules/.pnpm/p-timeout@6.1.2/node_modules/p-timeout/index.js","../../src/llvm/llvm_url.ts","../../src/llvm/llvm.ts","../../src/llvm/llvm_installer.ts","../../src/msvc/msvc.ts","../../src/opencppcoverage/opencppcoverage.ts","../../src/powershell/powershell.ts","../../src/task/task.ts","../../src/cli-options.ts","../../node_modules/.pnpm/ci-info@4.0.0/node_modules/ci-info/index.js","../../node_modules/.pnpm/@actions+core@1.11.1/node_modules/@actions/core/lib/utils.js","../../node_modules/.pnpm/@actions+core@1.11.1/node_modules/@actions/core/lib/file-command.js","../../node_modules/.pnpm/tunnel@0.0.6/node_modules/tunnel/index.js","../../node_modules/.pnpm/@actions+http-client@2.2.3_patch_hash=gqcf2jay7nqqezf3jni6mxu74u/node_modules/@actions/http-client/lib/esnext/index.js","../../node_modules/.pnpm/@actions+http-client@2.2.3_patch_hash=gqcf2jay7nqqezf3jni6mxu74u/node_modules/@actions/http-client/lib/auth.js","../../node_modules/.pnpm/@actions+io@1.1.3/node_modules/@actions/io/lib/io-util.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/arguments/file-url.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/methods/parameters.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/utils/uint-array.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/methods/template.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/utils/standard-stream.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/arguments/specific.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/verbose/values.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/arguments/escape.js","../../node_modules/.pnpm/figures@6.1.0/node_modules/figures/index.js","../../node_modules/.pnpm/is-unicode-supported@2.1.0/node_modules/is-unicode-supported/index.js","../../node_modules/.pnpm/yoctocolors@2.1.1/node_modules/yoctocolors/base.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/verbose/default.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/verbose/custom.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/verbose/log.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/verbose/info.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/return/duration.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/arguments/command.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/verbose/start.js","../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/windows.js","../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/mode.js","../../node_modules/.pnpm/which@2.0.2/node_modules/which/which.js","../../node_modules/.pnpm/path-key@3.1.1/node_modules/path-key/index.js","../../node_modules/.pnpm/cross-spawn@7.0.3/node_modules/cross-spawn/lib/util/escape.js","../../node_modules/.pnpm/shebang-command@2.0.0/node_modules/shebang-command/index.js","../../node_modules/.pnpm/shebang-regex@3.0.0/node_modules/shebang-regex/index.js","../../node_modules/.pnpm/cross-spawn@7.0.3/node_modules/cross-spawn/lib/util/readShebang.js","../../node_modules/.pnpm/cross-spawn@7.0.3/node_modules/cross-spawn/lib/parse.js","../../node_modules/.pnpm/npm-run-path@6.0.0/node_modules/npm-run-path/index.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/return/final-error.js","../../node_modules/.pnpm/human-signals@8.0.0/node_modules/human-signals/build/src/realtime.js","../../node_modules/.pnpm/human-signals@8.0.0/node_modules/human-signals/build/src/core.js","../../node_modules/.pnpm/human-signals@8.0.0/node_modules/human-signals/build/src/signals.js","../../node_modules/.pnpm/human-signals@8.0.0/node_modules/human-signals/build/src/main.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/terminate/signal.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/terminate/kill.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/utils/abort-signal.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/terminate/cancel.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/validation.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/utils/deferred.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/arguments/fd-options.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/utils/max-listeners.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/reference.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/incoming.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/forward.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/strict.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/outgoing.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/send.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/graceful.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/terminate/graceful.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/terminate/timeout.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/ipc-input.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/arguments/encoding-option.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/arguments/cwd.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/arguments/options.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/methods/node.js","../../node_modules/.pnpm/get-stream@9.0.1/node_modules/get-stream/source/stream.js","../../node_modules/.pnpm/get-stream@9.0.1/node_modules/get-stream/source/contents.js","../../node_modules/.pnpm/get-stream@9.0.1/node_modules/get-stream/source/utils.js","../../node_modules/.pnpm/get-stream@9.0.1/node_modules/get-stream/source/array.js","../../node_modules/.pnpm/get-stream@9.0.1/node_modules/get-stream/source/array-buffer.js","../../node_modules/.pnpm/get-stream@9.0.1/node_modules/get-stream/source/string.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/io/max-buffer.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/return/message.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/return/result.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/verbose/complete.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/return/reject.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/verbose/error.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/stdio/type.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/transform/object-mode.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/transform/normalize.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/stdio/direction.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/stdio/stdio-option.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/stdio/native.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/stdio/input-option.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/stdio/duplicate.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/stdio/handle.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/array.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/stdio/handle-sync.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/io/strip-newline.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/transform/split.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/transform/validate.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/transform/encoding-transform.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/transform/run-async.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/transform/run-sync.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/transform/generator.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/io/input-sync.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/verbose/output.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/io/output-sync.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/resolve/exit-async.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/resolve/exit-sync.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/methods/main-sync.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/resolve/all-sync.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/get-one.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/get-each.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/methods.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/return/early-error.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/stdio/handle-async.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/io/pipeline.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/io/output-async.js","../../node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/mjs/signals.js","../../node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/mjs/index.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/terminate/cleanup.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/pipe/pipe-arguments.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/pipe/throw.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/pipe/sequence.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/pipe/streaming.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/pipe/abort.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/pipe/setup.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/io/iterate.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/io/contents.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/resolve/wait-stream.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/resolve/stdio.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/resolve/all-async.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/verbose/ipc.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/ipc/buffer-messages.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/resolve/wait-subprocess.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/convert/concurrent.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/convert/shared.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/convert/readable.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/convert/writable.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/convert/duplex.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/convert/iterable.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/convert/add.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/methods/promise.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/methods/main-async.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/methods/bind.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/methods/create.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/methods/command.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/lib/methods/script.js","../../node_modules/.pnpm/execa@9.4.1/node_modules/execa/index.js","../../node_modules/.pnpm/isexe@3.1.1/node_modules/isexe/dist/cjs/posix.js","../../node_modules/.pnpm/isexe@3.1.1/node_modules/isexe/dist/cjs/win32.js","../../node_modules/.pnpm/isexe@3.1.1/node_modules/isexe/dist/cjs/options.js","../../node_modules/.pnpm/isexe@3.1.1/node_modules/isexe/dist/cjs/index.js","../../node_modules/.pnpm/which@5.0.0/node_modules/which/lib/index.js","../../node_modules/.pnpm/which@4.0.0/node_modules/which/lib/index.js","../../node_modules/.pnpm/npm-run-path@5.3.0/node_modules/npm-run-path/index.js","../../node_modules/.pnpm/mimic-fn@4.0.0/node_modules/mimic-fn/index.js","../../node_modules/.pnpm/onetime@6.0.0/node_modules/onetime/index.js","../../node_modules/.pnpm/human-signals@4.3.1/node_modules/human-signals/build/src/realtime.js","../../node_modules/.pnpm/human-signals@4.3.1/node_modules/human-signals/build/src/core.js","../../node_modules/.pnpm/human-signals@4.3.1/node_modules/human-signals/build/src/signals.js","../../node_modules/.pnpm/human-signals@4.3.1/node_modules/human-signals/build/src/main.js","../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/error.js","../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/stdio.js","../../node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/index.js","../../node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/signals.js","../../node_modules/.pnpm/get-stream@6.0.1/node_modules/get-stream/buffer-stream.js","../../node_modules/.pnpm/merge-stream@2.0.0/node_modules/merge-stream/index.js","../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/command.js","../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/verbose.js","../../node_modules/.pnpm/strip-final-newline@3.0.0/node_modules/strip-final-newline/index.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/math/sign/is-implemented.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/_iterate.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/assign/is-implemented.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/is-value.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/normalize-options.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/number/to-integer.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/math/sign/index.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/math/sign/shim.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/number/to-pos-integer.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/lib/resolve-length.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/valid-callable.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/valid-value.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/for-each.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/assign/index.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/assign/shim.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/keys/index.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/keys/is-implemented.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/keys/shim.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/object/is-object.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/error/custom.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/function/_define-length.js","../../node_modules/.pnpm/type@2.7.3/node_modules/type/value/is.js","../../node_modules/.pnpm/type@2.7.3/node_modules/type/object/is.js","../../node_modules/.pnpm/type@2.7.3/node_modules/type/function/is.js","../../node_modules/.pnpm/type@2.7.3/node_modules/type/prototype/is.js","../../node_modules/.pnpm/type@2.7.3/node_modules/type/plain-function/is.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/string/#/contains/is-implemented.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/string/#/contains/index.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/string/#/contains/shim.js","../../node_modules/.pnpm/d@1.0.2/node_modules/d/index.js","../../node_modules/.pnpm/event-emitter@0.3.5/node_modules/event-emitter/index.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/lib/resolve-resolve.js","../../node_modules/.pnpm/es5-ext@0.10.64/node_modules/es5-ext/array/to-array.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/lib/resolve-normalize.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/lib/configure-map.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/plain.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/index.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/normalizers/primitive.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/normalizers/get-primitive-fixed.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/normalizers/get.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/normalizers/get-1.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/normalizers/get-fixed.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/ext/async.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/ext/dispose.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/ext/max-age.js","../../node_modules/.pnpm/timers-ext@0.1.8/node_modules/timers-ext/valid-timeout.js","../../node_modules/.pnpm/timers-ext@0.1.8/node_modules/timers-ext/max-timeout.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/ext/max.js","../../node_modules/.pnpm/lru-queue@0.1.0/node_modules/lru-queue/index.js","../../node_modules/.pnpm/memoizee@0.4.17/node_modules/memoizee/ext/ref-counter.js","../../node_modules/.pnpm/escape-path-with-spaces@1.0.2/node_modules/escape-path-with-spaces/index.js","../../node_modules/.pnpm/escape-quotes@1.0.2/node_modules/escape-quotes/lib/escape-quotes.js","../../node_modules/.pnpm/escape-string-regexp@1.0.5/node_modules/escape-string-regexp/index.js","../../node_modules/.pnpm/numerous@1.0.3/node_modules/numerous/lib/numerous.js","../../node_modules/.pnpm/numerous@1.0.3/node_modules/numerous/index.js","../../node_modules/.pnpm/numerous@1.0.3/node_modules/numerous/locales/en.js","../../node_modules/.pnpm/is-node@1.0.2/node_modules/is-node/index.js","../../node_modules/.pnpm/time-delta@https+++codeload.github.com+aminya+time-delta+tar.gz+69d91a4/node_modules/time-delta/locales/en.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/internal/constants.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/internal/debug.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/internal/re.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/internal/parse-options.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/internal/identifiers.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/classes/semver.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/parse.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/valid.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/clean.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/inc.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/diff.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/major.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/minor.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/patch.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/prerelease.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/compare.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/rcompare.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/compare-loose.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/compare-build.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/sort.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/rsort.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/gt.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/lt.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/eq.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/neq.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/gte.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/lte.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/cmp.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/coerce.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/internal/lrucache.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/functions/satisfies.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/ranges/to-comparators.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/ranges/max-satisfying.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/ranges/min-satisfying.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/ranges/min-version.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/ranges/valid.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/ranges/outside.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/ranges/gtr.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/ranges/ltr.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/ranges/intersects.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/ranges/simplify.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/ranges/subset.js","../../node_modules/.pnpm/semver@7.6.3/node_modules/semver/index.js","../../node_modules/.pnpm/node-downloader-helper@2.1.9/node_modules/node-downloader-helper/dist/index.js","../../packages/setup-apt/dist/apt-timeout.js","../../packages/setup-apt/dist/update.js","../../packages/setup-apt/dist/init-apt.js","../../node_modules/.pnpm/replace-ext@2.0.0/node_modules/replace-ext/index.js","../../src/utils/env/arch.ts","../../node_modules/.pnpm/semver@6.3.1/node_modules/semver/semver.js","../../node_modules/.pnpm/@actions+tool-cache@2.0.1/node_modules/@actions/tool-cache/lib/manifest.js","../../node_modules/.pnpm/uuid@3.4.0/node_modules/uuid/lib/bytesToUuid.js","../../node_modules/.pnpm/uuid@3.4.0/node_modules/uuid/lib/rng.js","../../node_modules/.pnpm/uuid@3.4.0/node_modules/uuid/v4.js","../../node_modules/.pnpm/@actions+tool-cache@2.0.1/node_modules/@actions/tool-cache/lib/retry-helper.js","../../node_modules/.pnpm/mkdirp@3.0.1/node_modules/mkdirp/dist/mjs/opts-arg.js","../../node_modules/.pnpm/mkdirp@3.0.1/node_modules/mkdirp/dist/mjs/mkdirp-manual.js","../../node_modules/.pnpm/mkdirp@3.0.1/node_modules/mkdirp/dist/mjs/find-made.js","../../node_modules/.pnpm/mkdirp@3.0.1/node_modules/mkdirp/dist/mjs/mkdirp-native.js","../../node_modules/.pnpm/mkdirp@3.0.1/node_modules/mkdirp/dist/mjs/path-arg.js","../../node_modules/.pnpm/mkdirp@3.0.1/node_modules/mkdirp/dist/mjs/use-native.js","../../node_modules/.pnpm/mkdirp@3.0.1/node_modules/mkdirp/dist/mjs/index.js","../../src/versions/default_versions.ts","../../node_modules/.pnpm/ubuntu-version@2.0.0/node_modules/ubuntu-version/index.js","../../node_modules/.pnpm/macos-release@3.3.0/node_modules/macos-release/index.js","../../src/utils/env/macos_version.ts","../../src/nala/nala.ts","../../src/vcpkg/vcpkg.ts","../../src/tool.ts","../../src/bazel/bazel.ts","../../src/conan/conan.ts","../../src/meson/meson.ts","../../src/ccache/ccache.ts","../../src/sccache/sccache.ts","../../src/cppcheck/cppcheck.ts","../../src/cpplint/cpplint.ts","../../src/flawfinder/flawfinder.ts","../../src/lizard/lizard.ts","../../src/make/make.ts","../../src/setup-cpp.ts","../../src/check-updates.ts","../../src/compilers.ts"],"sourcesContent":["\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.issue = exports.issueCommand = void 0;\nconst os = __importStar(require(\"os\"));\nconst utils_1 = require(\"./utils\");\n/**\n * Commands\n *\n * Command Format:\n * ::name key=value,key=value::message\n *\n * Examples:\n * ::warning::This is the message\n * ::set-env name=MY_VAR::some value\n */\nfunction issueCommand(command, properties, message) {\n const cmd = new Command(command, properties, message);\n process.stdout.write(cmd.toString() + os.EOL);\n}\nexports.issueCommand = issueCommand;\nfunction issue(name, message = '') {\n issueCommand(name, {}, message);\n}\nexports.issue = issue;\nconst CMD_STRING = '::';\nclass Command {\n constructor(command, properties, message) {\n if (!command) {\n command = 'missing.command';\n }\n this.command = command;\n this.properties = properties;\n this.message = message;\n }\n toString() {\n let cmdStr = CMD_STRING + this.command;\n if (this.properties && Object.keys(this.properties).length > 0) {\n cmdStr += ' ';\n let first = true;\n for (const key in this.properties) {\n if (this.properties.hasOwnProperty(key)) {\n const val = this.properties[key];\n if (val) {\n if (first) {\n first = false;\n }\n else {\n cmdStr += ',';\n }\n cmdStr += `${key}=${escapeProperty(val)}`;\n }\n }\n }\n }\n cmdStr += `${CMD_STRING}${escapeData(this.message)}`;\n return cmdStr;\n }\n}\nfunction escapeData(s) {\n return (0, utils_1.toCommandValue)(s)\n .replace(/%/g, '%25')\n .replace(/\\r/g, '%0D')\n .replace(/\\n/g, '%0A');\n}\nfunction escapeProperty(s) {\n return (0, utils_1.toCommandValue)(s)\n .replace(/%/g, '%25')\n .replace(/\\r/g, '%0D')\n .replace(/\\n/g, '%0A')\n .replace(/:/g, '%3A')\n .replace(/,/g, '%2C');\n}\n//# sourceMappingURL=command.js.map","export function getProxyUrl(reqUrl) {\n const usingSsl = reqUrl.protocol === 'https:';\n if (checkBypass(reqUrl)) {\n return undefined;\n }\n const proxyVar = (() => {\n if (usingSsl) {\n return process.env['https_proxy'] || process.env['HTTPS_PROXY'];\n }\n else {\n return process.env['http_proxy'] || process.env['HTTP_PROXY'];\n }\n })();\n if (proxyVar) {\n try {\n return new DecodedURL(proxyVar);\n }\n catch {\n if (!proxyVar.startsWith('http://') && !proxyVar.startsWith('https://'))\n return new DecodedURL(`http://${proxyVar}`);\n }\n }\n else {\n return undefined;\n }\n}\nexport function checkBypass(reqUrl) {\n if (!reqUrl.hostname) {\n return false;\n }\n const reqHost = reqUrl.hostname;\n if (isLoopbackAddress(reqHost)) {\n return true;\n }\n const noProxy = process.env['no_proxy'] || process.env['NO_PROXY'] || '';\n if (!noProxy) {\n return false;\n }\n // Determine the request port\n let reqPort;\n if (reqUrl.port) {\n reqPort = Number(reqUrl.port);\n }\n else if (reqUrl.protocol === 'http:') {\n reqPort = 80;\n }\n else if (reqUrl.protocol === 'https:') {\n reqPort = 443;\n }\n // Format the request hostname and hostname with port\n const upperReqHosts = [reqUrl.hostname.toUpperCase()];\n if (typeof reqPort === 'number') {\n upperReqHosts.push(`${upperReqHosts[0]}:${reqPort}`);\n }\n // Compare request host against noproxy\n for (const upperNoProxyItem of noProxy\n .split(',')\n .map(x => x.trim().toUpperCase())\n .filter(x => x)) {\n if (upperNoProxyItem === '*' ||\n upperReqHosts.some(x => x === upperNoProxyItem ||\n x.endsWith(`.${upperNoProxyItem}`) ||\n (upperNoProxyItem.startsWith('.') &&\n x.endsWith(`${upperNoProxyItem}`)))) {\n return true;\n }\n }\n return false;\n}\nfunction isLoopbackAddress(host) {\n const hostLower = host.toLowerCase();\n return (hostLower === 'localhost' ||\n hostLower.startsWith('127.') ||\n hostLower.startsWith('[::1]') ||\n hostLower.startsWith('[0:0:0:0:0:0:0:1]'));\n}\nclass DecodedURL extends URL {\n _decodedUsername;\n _decodedPassword;\n constructor(url, base) {\n super(url, base);\n this._decodedUsername = decodeURIComponent(super.username);\n this._decodedPassword = decodeURIComponent(super.password);\n }\n get username() {\n return this._decodedUsername;\n }\n get password() {\n return this._decodedPassword;\n }\n}\n//# sourceMappingURL=proxy.js.map","'use strict';\n\nvar net = require('net');\nvar tls = require('tls');\nvar http = require('http');\nvar https = require('https');\nvar events = require('events');\nvar assert = require('assert');\nvar util = require('util');\n\n\nexports.httpOverHttp = httpOverHttp;\nexports.httpsOverHttp = httpsOverHttp;\nexports.httpOverHttps = httpOverHttps;\nexports.httpsOverHttps = httpsOverHttps;\n\n\nfunction httpOverHttp(options) {\n var agent = new TunnelingAgent(options);\n agent.request = http.request;\n return agent;\n}\n\nfunction httpsOverHttp(options) {\n var agent = new TunnelingAgent(options);\n agent.request = http.request;\n agent.createSocket = createSecureSocket;\n agent.defaultPort = 443;\n return agent;\n}\n\nfunction httpOverHttps(options) {\n var agent = new TunnelingAgent(options);\n agent.request = https.request;\n return agent;\n}\n\nfunction httpsOverHttps(options) {\n var agent = new TunnelingAgent(options);\n agent.request = https.request;\n agent.createSocket = createSecureSocket;\n agent.defaultPort = 443;\n return agent;\n}\n\n\nfunction TunnelingAgent(options) {\n var self = this;\n self.options = options || {};\n self.proxyOptions = self.options.proxy || {};\n self.maxSockets = self.options.maxSockets || http.Agent.defaultMaxSockets;\n self.requests = [];\n self.sockets = [];\n\n self.on('free', function onFree(socket, host, port, localAddress) {\n var options = toOptions(host, port, localAddress);\n for (var i = 0, len = self.requests.length; i < len; ++i) {\n var pending = self.requests[i];\n if (pending.host === options.host && pending.port === options.port) {\n // Detect the request to connect same origin server,\n // reuse the connection.\n self.requests.splice(i, 1);\n pending.request.onSocket(socket);\n return;\n }\n }\n socket.destroy();\n self.removeSocket(socket);\n });\n}\nutil.inherits(TunnelingAgent, events.EventEmitter);\n\nTunnelingAgent.prototype.addRequest = function addRequest(req, host, port, localAddress) {\n var self = this;\n var options = mergeOptions({request: req}, self.options, toOptions(host, port, localAddress));\n\n if (self.sockets.length >= this.maxSockets) {\n // We are over limit so we'll add it to the queue.\n self.requests.push(options);\n return;\n }\n\n // If we are under maxSockets create a new one.\n self.createSocket(options, function(socket) {\n socket.on('free', onFree);\n socket.on('close', onCloseOrRemove);\n socket.on('agentRemove', onCloseOrRemove);\n req.onSocket(socket);\n\n function onFree() {\n self.emit('free', socket, options);\n }\n\n function onCloseOrRemove(err) {\n self.removeSocket(socket);\n socket.removeListener('free', onFree);\n socket.removeListener('close', onCloseOrRemove);\n socket.removeListener('agentRemove', onCloseOrRemove);\n }\n });\n};\n\nTunnelingAgent.prototype.createSocket = function createSocket(options, cb) {\n var self = this;\n var placeholder = {};\n self.sockets.push(placeholder);\n\n var connectOptions = mergeOptions({}, self.proxyOptions, {\n method: 'CONNECT',\n path: options.host + ':' + options.port,\n agent: false,\n headers: {\n host: options.host + ':' + options.port\n }\n });\n if (options.localAddress) {\n connectOptions.localAddress = options.localAddress;\n }\n if (connectOptions.proxyAuth) {\n connectOptions.headers = connectOptions.headers || {};\n connectOptions.headers['Proxy-Authorization'] = 'Basic ' +\n new Buffer(connectOptions.proxyAuth).toString('base64');\n }\n\n debug('making CONNECT request');\n var connectReq = self.request(connectOptions);\n connectReq.useChunkedEncodingByDefault = false; // for v0.6\n connectReq.once('response', onResponse); // for v0.6\n connectReq.once('upgrade', onUpgrade); // for v0.6\n connectReq.once('connect', onConnect); // for v0.7 or later\n connectReq.once('error', onError);\n connectReq.end();\n\n function onResponse(res) {\n // Very hacky. This is necessary to avoid http-parser leaks.\n res.upgrade = true;\n }\n\n function onUpgrade(res, socket, head) {\n // Hacky.\n process.nextTick(function() {\n onConnect(res, socket, head);\n });\n }\n\n function onConnect(res, socket, head) {\n connectReq.removeAllListeners();\n socket.removeAllListeners();\n\n if (res.statusCode !== 200) {\n debug('tunneling socket could not be established, statusCode=%d',\n res.statusCode);\n socket.destroy();\n var error = new Error('tunneling socket could not be established, ' +\n 'statusCode=' + res.statusCode);\n error.code = 'ECONNRESET';\n options.request.emit('error', error);\n self.removeSocket(placeholder);\n return;\n }\n if (head.length > 0) {\n debug('got illegal response body from proxy');\n socket.destroy();\n var error = new Error('got illegal response body from proxy');\n error.code = 'ECONNRESET';\n options.request.emit('error', error);\n self.removeSocket(placeholder);\n return;\n }\n debug('tunneling connection has established');\n self.sockets[self.sockets.indexOf(placeholder)] = socket;\n return cb(socket);\n }\n\n function onError(cause) {\n connectReq.removeAllListeners();\n\n debug('tunneling socket could not be established, cause=%s\\n',\n cause.message, cause.stack);\n var error = new Error('tunneling socket could not be established, ' +\n 'cause=' + cause.message);\n error.code = 'ECONNRESET';\n options.request.emit('error', error);\n self.removeSocket(placeholder);\n }\n};\n\nTunnelingAgent.prototype.removeSocket = function removeSocket(socket) {\n var pos = this.sockets.indexOf(socket)\n if (pos === -1) {\n return;\n }\n this.sockets.splice(pos, 1);\n\n var pending = this.requests.shift();\n if (pending) {\n // If we have pending requests and a socket gets closed a new one\n // needs to be created to take over in the pool for the one that closed.\n this.createSocket(pending, function(socket) {\n pending.request.onSocket(socket);\n });\n }\n};\n\nfunction createSecureSocket(options, cb) {\n var self = this;\n TunnelingAgent.prototype.createSocket.call(self, options, function(socket) {\n var hostHeader = options.request.getHeader('host');\n var tlsOptions = mergeOptions({}, self.options, {\n socket: socket,\n servername: hostHeader ? hostHeader.replace(/:.*$/, '') : options.host\n });\n\n // 0 is dummy port for v0.6\n var secureSocket = tls.connect(0, tlsOptions);\n self.sockets[self.sockets.indexOf(socket)] = secureSocket;\n cb(secureSocket);\n });\n}\n\n\nfunction toOptions(host, port, localAddress) {\n if (typeof host === 'string') { // since v0.10\n return {\n host: host,\n port: port,\n localAddress: localAddress\n };\n }\n return host; // for v0.11 or later\n}\n\nfunction mergeOptions(target) {\n for (var i = 1, len = arguments.length; i < len; ++i) {\n var overrides = arguments[i];\n if (typeof overrides === 'object') {\n var keys = Object.keys(overrides);\n for (var j = 0, keyLen = keys.length; j < keyLen; ++j) {\n var k = keys[j];\n if (overrides[k] !== undefined) {\n target[k] = overrides[k];\n }\n }\n }\n }\n return target;\n}\n\n\nvar debug;\nif (process.env.NODE_DEBUG && /\\btunnel\\b/.test(process.env.NODE_DEBUG)) {\n debug = function() {\n var args = Array.prototype.slice.call(arguments);\n if (typeof args[0] === 'string') {\n args[0] = 'TUNNEL: ' + args[0];\n } else {\n args.unshift('TUNNEL:');\n }\n console.error.apply(console, args);\n }\n} else {\n debug = function() {};\n}\nexports.debug = debug; // for test\n","\"use strict\";\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.summary = exports.markdownSummary = exports.SUMMARY_DOCS_URL = exports.SUMMARY_ENV_VAR = void 0;\nconst os_1 = require(\"os\");\nconst fs_1 = require(\"fs\");\nconst { access, appendFile, writeFile } = fs_1.promises;\nexports.SUMMARY_ENV_VAR = 'GITHUB_STEP_SUMMARY';\nexports.SUMMARY_DOCS_URL = 'https://docs.github.com/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary';\nclass Summary {\n constructor() {\n this._buffer = '';\n }\n /**\n * Finds the summary file path from the environment, rejects if env var is not found or file does not exist\n * Also checks r/w permissions.\n *\n * @returns step summary file path\n */\n filePath() {\n return __awaiter(this, void 0, void 0, function* () {\n if (this._filePath) {\n return this._filePath;\n }\n const pathFromEnv = process.env[exports.SUMMARY_ENV_VAR];\n if (!pathFromEnv) {\n throw new Error(`Unable to find environment variable for $${exports.SUMMARY_ENV_VAR}. Check if your runtime environment supports job summaries.`);\n }\n try {\n yield access(pathFromEnv, fs_1.constants.R_OK | fs_1.constants.W_OK);\n }\n catch (_a) {\n throw new Error(`Unable to access summary file: '${pathFromEnv}'. Check if the file has correct read/write permissions.`);\n }\n this._filePath = pathFromEnv;\n return this._filePath;\n });\n }\n /**\n * Wraps content in an HTML tag, adding any HTML attributes\n *\n * @param {string} tag HTML tag to wrap\n * @param {string | null} content content within the tag\n * @param {[attribute: string]: string} attrs key-value list of HTML attributes to add\n *\n * @returns {string} content wrapped in HTML element\n */\n wrap(tag, content, attrs = {}) {\n const htmlAttrs = Object.entries(attrs)\n .map(([key, value]) => ` ${key}=\"${value}\"`)\n .join('');\n if (!content) {\n return `<${tag}${htmlAttrs}>`;\n }\n return `<${tag}${htmlAttrs}>${content}</${tag}>`;\n }\n /**\n * Writes text in the buffer to the summary buffer file and empties buffer. Will append by default.\n *\n * @param {SummaryWriteOptions} [options] (optional) options for write operation\n *\n * @returns {Promise<Summary>} summary instance\n */\n write(options) {\n return __awaiter(this, void 0, void 0, function* () {\n const overwrite = !!(options === null || options === void 0 ? void 0 : options.overwrite);\n const filePath = yield this.filePath();\n const writeFunc = overwrite ? writeFile : appendFile;\n yield writeFunc(filePath, this._buffer, { encoding: 'utf8' });\n return this.emptyBuffer();\n });\n }\n /**\n * Clears the summary buffer and wipes the summary file\n *\n * @returns {Summary} summary instance\n */\n clear() {\n return __awaiter(this, void 0, void 0, function* () {\n return this.emptyBuffer().write({ overwrite: true });\n });\n }\n /**\n * Returns the current summary buffer as a string\n *\n * @returns {string} string of summary buffer\n */\n stringify() {\n return this._buffer;\n }\n /**\n * If the summary buffer is empty\n *\n * @returns {boolen} true if the buffer is empty\n */\n isEmptyBuffer() {\n return this._buffer.length === 0;\n }\n /**\n * Resets the summary buffer without writing to summary file\n *\n * @returns {Summary} summary instance\n */\n emptyBuffer() {\n this._buffer = '';\n return this;\n }\n /**\n * Adds raw text to the summary buffer\n *\n * @param {string} text content to add\n * @param {boolean} [addEOL=false] (optional) append an EOL to the raw text (default: false)\n *\n * @returns {Summary} summary instance\n */\n addRaw(text, addEOL = false) {\n this._buffer += text;\n return addEOL ? this.addEOL() : this;\n }\n /**\n * Adds the operating system-specific end-of-line marker to the buffer\n *\n * @returns {Summary} summary instance\n */\n addEOL() {\n return this.addRaw(os_1.EOL);\n }\n /**\n * Adds an HTML codeblock to the summary buffer\n *\n * @param {string} code content to render within fenced code block\n * @param {string} lang (optional) language to syntax highlight code\n *\n * @returns {Summary} summary instance\n */\n addCodeBlock(code, lang) {\n const attrs = Object.assign({}, (lang && { lang }));\n const element = this.wrap('pre', this.wrap('code', code), attrs);\n return this.addRaw(element).addEOL();\n }\n /**\n * Adds an HTML list to the summary buffer\n *\n * @param {string[]} items list of items to render\n * @param {boolean} [ordered=false] (optional) if the rendered list should be ordered or not (default: false)\n *\n * @returns {Summary} summary instance\n */\n addList(items, ordered = false) {\n const tag = ordered ? 'ol' : 'ul';\n const listItems = items.map(item => this.wrap('li', item)).join('');\n const element = this.wrap(tag, listItems);\n return this.addRaw(element).addEOL();\n }\n /**\n * Adds an HTML table to the summary buffer\n *\n * @param {SummaryTableCell[]} rows table rows\n *\n * @returns {Summary} summary instance\n */\n addTable(rows) {\n const tableBody = rows\n .map(row => {\n const cells = row\n .map(cell => {\n if (typeof cell === 'string') {\n return this.wrap('td', cell);\n }\n const { header, data, colspan, rowspan } = cell;\n const tag = header ? 'th' : 'td';\n const attrs = Object.assign(Object.assign({}, (colspan && { colspan })), (rowspan && { rowspan }));\n return this.wrap(tag, data, attrs);\n })\n .join('');\n return this.wrap('tr', cells);\n })\n .join('');\n const element = this.wrap('table', tableBody);\n return this.addRaw(element).addEOL();\n }\n /**\n * Adds a collapsable HTML details element to the summary buffer\n *\n * @param {string} label text for the closed state\n * @param {string} content collapsable content\n *\n * @returns {Summary} summary instance\n */\n addDetails(label, content) {\n const element = this.wrap('details', this.wrap('summary', label) + content);\n return this.addRaw(element).addEOL();\n }\n /**\n * Adds an HTML image tag to the summary buffer\n *\n * @param {string} src path to the image you to embed\n * @param {string} alt text description of the image\n * @param {SummaryImageOptions} options (optional) addition image attributes\n *\n * @returns {Summary} summary instance\n */\n addImage(src, alt, options) {\n const { width, height } = options || {};\n const attrs = Object.assign(Object.assign({}, (width && { width })), (height && { height }));\n const element = this.wrap('img', null, Object.assign({ src, alt }, attrs));\n return this.addRaw(element).addEOL();\n }\n /**\n * Adds an HTML section heading element\n *\n * @param {string} text heading text\n * @param {number | string} [level=1] (optional) the heading level, default: 1\n *\n * @returns {Summary} summary instance\n */\n addHeading(text, level) {\n const tag = `h${level}`;\n const allowedTag = ['h1', 'h2', 'h3', 'h4', 'h5', 'h6'].includes(tag)\n ? tag\n : 'h1';\n const element = this.wrap(allowedTag, text);\n return this.addRaw(element).addEOL();\n }\n /**\n * Adds an HTML thematic break (<hr>) to the summary buffer\n *\n * @returns {Summary} summary instance\n */\n addSeparator() {\n const element = this.wrap('hr', null);\n return this.addRaw(element).addEOL();\n }\n /**\n * Adds an HTML line break (<br>) to the summary buffer\n *\n * @returns {Summary} summary instance\n */\n addBreak() {\n const element = this.wrap('br', null);\n return this.addRaw(element).addEOL();\n }\n /**\n * Adds an HTML blockquote to the summary buffer\n *\n * @param {string} text quote text\n * @param {string} cite (optional) citation url\n *\n * @returns {Summary} summary instance\n */\n addQuote(text, cite) {\n const attrs = Object.assign({}, (cite && { cite }));\n const element = this.wrap('blockquote', text, attrs);\n return this.addRaw(element).addEOL();\n }\n /**\n * Adds an HTML anchor tag to the summary buffer\n *\n * @param {string} text link text/content\n * @param {string} href hyperlink\n *\n * @returns {Summary} summary instance\n */\n addLink(text, href) {\n const element = this.wrap('a', text, { href });\n return this.addRaw(element).addEOL();\n }\n}\nconst _summary = new Summary();\n/**\n * @deprecated use `core.summary`\n */\nexports.markdownSummary = _summary;\nexports.summary = _summary;\n//# sourceMappingURL=summary.js.map","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.findInPath = exports.which = exports.mkdirP = exports.rmRF = exports.mv = exports.cp = void 0;\nconst assert_1 = require(\"assert\");\nconst path = __importStar(require(\"path\"));\nconst ioUtil = __importStar(require(\"./io-util\"));\n/**\n * Copies a file or folder.\n * Based off of shelljs - https://github.com/shelljs/shelljs/blob/9237f66c52e5daa40458f94f9565e18e8132f5a6/src/cp.js\n *\n * @param source source path\n * @param dest destination path\n * @param options optional. See CopyOptions.\n */\nfunction cp(source, dest, options = {}) {\n return __awaiter(this, void 0, void 0, function* () {\n const { force, recursive, copySourceDirectory } = readCopyOptions(options);\n const destStat = (yield ioUtil.exists(dest)) ? yield ioUtil.stat(dest) : null;\n // Dest is an existing file, but not forcing\n if (destStat && destStat.isFile() && !force) {\n return;\n }\n // If dest is an existing directory, should copy inside.\n const newDest = destStat && destStat.isDirectory() && copySourceDirectory\n ? path.join(dest, path.basename(source))\n : dest;\n if (!(yield ioUtil.exists(source))) {\n throw new Error(`no such file or directory: ${source}`);\n }\n const sourceStat = yield ioUtil.stat(source);\n if (sourceStat.isDirectory()) {\n if (!recursive) {\n throw new Error(`Failed to copy. ${source} is a directory, but tried to copy without recursive flag.`);\n }\n else {\n yield cpDirRecursive(source, newDest, 0, force);\n }\n }\n else {\n if (path.relative(source, newDest) === '') {\n // a file cannot be copied to itself\n throw new Error(`'${newDest}' and '${source}' are the same file`);\n }\n yield copyFile(source, newDest, force);\n }\n });\n}\nexports.cp = cp;\n/**\n * Moves a path.\n *\n * @param source source path\n * @param dest destination path\n * @param options optional. See MoveOptions.\n */\nfunction mv(source, dest, options = {}) {\n return __awaiter(this, void 0, void 0, function* () {\n if (yield ioUtil.exists(dest)) {\n let destExists = true;\n if (yield ioUtil.isDirectory(dest)) {\n // If dest is directory copy src into dest\n dest = path.join(dest, path.basename(source));\n destExists = yield ioUtil.exists(dest);\n }\n if (destExists) {\n if (options.force == null || options.force) {\n yield rmRF(dest);\n }\n else {\n throw new Error('Destination already exists');\n }\n }\n }\n yield mkdirP(path.dirname(dest));\n yield ioUtil.rename(source, dest);\n });\n}\nexports.mv = mv;\n/**\n * Remove a path recursively with force\n *\n * @param inputPath path to remove\n */\nfunction rmRF(inputPath) {\n return __awaiter(this, void 0, void 0, function* () {\n if (ioUtil.IS_WINDOWS) {\n // Check for invalid characters\n // https://docs.microsoft.com/en-us/windows/win32/fileio/naming-a-file\n if (/[*\"<>|]/.test(inputPath)) {\n throw new Error('File path must not contain `*`, `\"`, `<`, `>` or `|` on Windows');\n }\n }\n try {\n // note if path does not exist, error is silent\n yield ioUtil.rm(inputPath, {\n force: true,\n maxRetries: 3,\n recursive: true,\n retryDelay: 300\n });\n }\n catch (err) {\n throw new Error(`File was unable to be removed ${err}`);\n }\n });\n}\nexports.rmRF = rmRF;\n/**\n * Make a directory. Creates the full path with folders in between\n * Will throw if it fails\n *\n * @param fsPath path to create\n * @returns Promise<void>\n */\nfunction mkdirP(fsPath) {\n return __awaiter(this, void 0, void 0, function* () {\n assert_1.ok(fsPath, 'a path argument must be provided');\n yield ioUtil.mkdir(fsPath, { recursive: true });\n });\n}\nexports.mkdirP = mkdirP;\n/**\n * Returns path of a tool had the tool actually been invoked. Resolves via paths.\n * If you check and the tool does not exist, it will throw.\n *\n * @param tool name of the tool\n * @param check whether to check if tool exists\n * @returns Promise<string> path to tool\n */\nfunction which(tool, check) {\n return __awaiter(this, void 0, void 0, function* () {\n if (!tool) {\n throw new Error(\"parameter 'tool' is required\");\n }\n // recursive when check=true\n if (check) {\n const result = yield which(tool, false);\n if (!result) {\n if (ioUtil.IS_WINDOWS) {\n throw new Error(`Unable to locate executable file: ${tool}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.`);\n }\n else {\n throw new Error(`Unable to locate executable file: ${tool}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.`);\n }\n }\n return result;\n }\n const matches = yield findInPath(tool);\n if (matches && matches.length > 0) {\n return matches[0];\n }\n return '';\n });\n}\nexports.which = which;\n/**\n * Returns a list of all occurrences of the given tool on the system path.\n *\n * @returns Promise<string[]> the paths of the tool\n */\nfunction findInPath(tool) {\n return __awaiter(this, void 0, void 0, function* () {\n if (!tool) {\n throw new Error(\"parameter 'tool' is required\");\n }\n // build the list of extensions to try\n const extensions = [];\n if (ioUtil.IS_WINDOWS && process.env['PATHEXT']) {\n for (const extension of process.env['PATHEXT'].split(path.delimiter)) {\n if (extension) {\n extensions.push(extension);\n }\n }\n }\n // if it's rooted, return it if exists. otherwise return empty.\n if (ioUtil.isRooted(tool)) {\n const filePath = yield ioUtil.tryGetExecutablePath(tool, extensions);\n if (filePath) {\n return [filePath];\n }\n return [];\n }\n // if any path separators, return empty\n if (tool.includes(path.sep)) {\n return [];\n }\n // build the list of directories\n //\n // Note, technically \"where\" checks the current directory on Windows. From a toolkit perspective,\n // it feels like we should not do this. Checking the current directory seems like more of a use\n // case of a shell, and the which() function exposed by the toolkit should strive for consistency\n // across platforms.\n const directories = [];\n if (process.env.PATH) {\n for (const p of process.env.PATH.split(path.delimiter)) {\n if (p) {\n directories.push(p);\n }\n }\n }\n // find all matches\n const matches = [];\n for (const directory of directories) {\n const filePath = yield ioUtil.tryGetExecutablePath(path.join(directory, tool), extensions);\n if (filePath) {\n matches.push(filePath);\n }\n }\n return matches;\n });\n}\nexports.findInPath = findInPath;\nfunction readCopyOptions(options) {\n const force = options.force == null ? true : options.force;\n const recursive = Boolean(options.recursive);\n const copySourceDirectory = options.copySourceDirectory == null\n ? true\n : Boolean(options.copySourceDirectory);\n return { force, recursive, copySourceDirectory };\n}\nfunction cpDirRecursive(sourceDir, destDir, currentDepth, force) {\n return __awaiter(this, void 0, void 0, function* () {\n // Ensure there is not a run away recursive copy\n if (currentDepth >= 255)\n return;\n currentDepth++;\n yield mkdirP(destDir);\n const files = yield ioUtil.readdir(sourceDir);\n for (const fileName of files) {\n const srcFile = `${sourceDir}/${fileName}`;\n const destFile = `${destDir}/${fileName}`;\n const srcFileStat = yield ioUtil.lstat(srcFile);\n if (srcFileStat.isDirectory()) {\n // Recurse\n yield cpDirRecursive(srcFile, destFile, currentDepth, force);\n }\n else {\n yield copyFile(srcFile, destFile, force);\n }\n }\n // Change the mode for the newly created directory\n yield ioUtil.chmod(destDir, (yield ioUtil.stat(sourceDir)).mode);\n });\n}\n// Buffered file copy\nfunction copyFile(srcFile, destFile, force) {\n return __awaiter(this, void 0, void 0, function* () {\n if ((yield ioUtil.lstat(srcFile)).isSymbolicLink()) {\n // unlink/re-link it\n try {\n yield ioUtil.lstat(destFile);\n yield ioUtil.unlink(destFile);\n }\n catch (e) {\n // Try to override file permission\n if (e.code === 'EPERM') {\n yield ioUtil.chmod(destFile, '0666');\n yield ioUtil.unlink(destFile);\n }\n // other errors = it doesn't exist, no work to do\n }\n // Copy over symlink\n const symlinkFull = yield ioUtil.readlink(srcFile);\n yield ioUtil.symlink(symlinkFull, destFile, ioUtil.IS_WINDOWS ? 'junction' : null);\n }\n else if (!(yield ioUtil.exists(destFile)) || force) {\n yield ioUtil.copyFile(srcFile, destFile);\n }\n });\n}\n//# sourceMappingURL=io.js.map","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getExecOutput = exports.exec = void 0;\nconst string_decoder_1 = require(\"string_decoder\");\nconst tr = __importStar(require(\"./toolrunner\"));\n/**\n * Exec a command.\n * Output will be streamed to the live console.\n * Returns promise with return code\n *\n * @param commandLine command to execute (can include additional args). Must be correctly escaped.\n * @param args optional arguments for tool. Escaping is handled by the lib.\n * @param options optional exec options. See ExecOptions\n * @returns Promise<number> exit code\n */\nfunction exec(commandLine, args, options) {\n return __awaiter(this, void 0, void 0, function* () {\n const commandArgs = tr.argStringToArray(commandLine);\n if (commandArgs.length === 0) {\n throw new Error(`Parameter 'commandLine' cannot be null or empty.`);\n }\n // Path to tool to execute should be first arg\n const toolPath = commandArgs[0];\n args = commandArgs.slice(1).concat(args || []);\n const runner = new tr.ToolRunner(toolPath, args, options);\n return runner.exec();\n });\n}\nexports.exec = exec;\n/**\n * Exec a command and get the output.\n * Output will be streamed to the live console.\n * Returns promise with the exit code and collected stdout and stderr\n *\n * @param commandLine command to execute (can include additional args). Must be correctly escaped.\n * @param args optional arguments for tool. Escaping is handled by the lib.\n * @param options optional exec options. See ExecOptions\n * @returns Promise<ExecOutput> exit code, stdout, and stderr\n */\nfunction getExecOutput(commandLine, args, options) {\n var _a, _b;\n return __awaiter(this, void 0, void 0, function* () {\n let stdout = '';\n let stderr = '';\n //Using string decoder covers the case where a mult-byte character is split\n const stdoutDecoder = new string_decoder_1.StringDecoder('utf8');\n const stderrDecoder = new string_decoder_1.StringDecoder('utf8');\n const originalStdoutListener = (_a = options === null || options === void 0 ? void 0 : options.listeners) === null || _a === void 0 ? void 0 : _a.stdout;\n const originalStdErrListener = (_b = options === null || options === void 0 ? void 0 : options.listeners) === null || _b === void 0 ? void 0 : _b.stderr;\n const stdErrListener = (data) => {\n stderr += stderrDecoder.write(data);\n if (originalStdErrListener) {\n originalStdErrListener(data);\n }\n };\n const stdOutListener = (data) => {\n stdout += stdoutDecoder.write(data);\n if (originalStdoutListener) {\n originalStdoutListener(data);\n }\n };\n const listeners = Object.assign(Object.assign({}, options === null || options === void 0 ? void 0 : options.listeners), { stdout: stdOutListener, stderr: stdErrListener });\n const exitCode = yield exec(commandLine, args, Object.assign(Object.assign({}, options), { listeners }));\n //flush any remaining characters\n stdout += stdoutDecoder.end();\n stderr += stderrDecoder.end();\n return {\n exitCode,\n stdout,\n stderr\n };\n });\n}\nexports.getExecOutput = getExecOutput;\n//# sourceMappingURL=exec.js.map","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.argStringToArray = exports.ToolRunner = void 0;\nconst os = __importStar(require(\"os\"));\nconst events = __importStar(require(\"events\"));\nconst child = __importStar(require(\"child_process\"));\nconst path = __importStar(require(\"path\"));\nconst io = __importStar(require(\"@actions/io\"));\nconst ioUtil = __importStar(require(\"@actions/io/lib/io-util\"));\nconst timers_1 = require(\"timers\");\n/* eslint-disable @typescript-eslint/unbound-method */\nconst IS_WINDOWS = process.platform === 'win32';\n/*\n * Class for running command line tools. Handles quoting and arg parsing in a platform agnostic way.\n */\nclass ToolRunner extends events.EventEmitter {\n constructor(toolPath, args, options) {\n super();\n if (!toolPath) {\n throw new Error(\"Parameter 'toolPath' cannot be null or empty.\");\n }\n this.toolPath = toolPath;\n this.args = args || [];\n this.options = options || {};\n }\n _debug(message) {\n if (this.options.listeners && this.options.listeners.debug) {\n this.options.listeners.debug(message);\n }\n }\n _getCommandString(options, noPrefix) {\n const toolPath = this._getSpawnFileName();\n const args = this._getSpawnArgs(options);\n let cmd = noPrefix ? '' : '[command]'; // omit prefix when piped to a second tool\n if (IS_WINDOWS) {\n // Windows + cmd file\n if (this._isCmdFile()) {\n cmd += toolPath;\n for (const a of args) {\n cmd += ` ${a}`;\n }\n }\n // Windows + verbatim\n else if (options.windowsVerbatimArguments) {\n cmd += `\"${toolPath}\"`;\n for (const a of args) {\n cmd += ` ${a}`;\n }\n }\n // Windows (regular)\n else {\n cmd += this._windowsQuoteCmdArg(toolPath);\n for (const a of args) {\n cmd += ` ${this._windowsQuoteCmdArg(a)}`;\n }\n }\n }\n else {\n // OSX/Linux - this can likely be improved with some form of quoting.\n // creating processes on Unix is fundamentally different than Windows.\n // on Unix, execvp() takes an arg array.\n cmd += toolPath;\n for (const a of args) {\n cmd += ` ${a}`;\n }\n }\n return cmd;\n }\n _processLineBuffer(data, strBuffer, onLine) {\n try {\n let s = strBuffer + data.toString();\n let n = s.indexOf(os.EOL);\n while (n > -1) {\n const line = s.substring(0, n);\n onLine(line);\n // the rest of the string ...\n s = s.substring(n + os.EOL.length);\n n = s.indexOf(os.EOL);\n }\n return s;\n }\n catch (err) {\n // streaming lines to console is best effort. Don't fail a build.\n this._debug(`error processing line. Failed with error ${err}`);\n return '';\n }\n }\n _getSpawnFileName() {\n if (IS_WINDOWS) {\n if (this._isCmdFile()) {\n return process.env['COMSPEC'] || 'cmd.exe';\n }\n }\n return this.toolPath;\n }\n _getSpawnArgs(options) {\n if (IS_WINDOWS) {\n if (this._isCmdFile()) {\n let argline = `/D /S /C \"${this._windowsQuoteCmdArg(this.toolPath)}`;\n for (const a of this.args) {\n argline += ' ';\n argline += options.windowsVerbatimArguments\n ? a\n : this._windowsQuoteCmdArg(a);\n }\n argline += '\"';\n return [argline];\n }\n }\n return this.args;\n }\n _endsWith(str, end) {\n return str.endsWith(end);\n }\n _isCmdFile() {\n const upperToolPath = this.toolPath.toUpperCase();\n return (this._endsWith(upperToolPath, '.CMD') ||\n this._endsWith(upperToolPath, '.BAT'));\n }\n _windowsQuoteCmdArg(arg) {\n // for .exe, apply the normal quoting rules that libuv applies\n if (!this._isCmdFile()) {\n return this._uvQuoteCmdArg(arg);\n }\n // otherwise apply quoting rules specific to the cmd.exe command line parser.\n // the libuv rules are generic and are not designed specifically for cmd.exe\n // command line parser.\n //\n // for a detailed description of the cmd.exe command line parser, refer to\n // http://stackoverflow.com/questions/4094699/how-does-the-windows-command-interpreter-cmd-exe-parse-scripts/7970912#7970912\n // need quotes for empty arg\n if (!arg) {\n return '\"\"';\n }\n // determine whether the arg needs to be quoted\n const cmdSpecialChars = [\n ' ',\n '\\t',\n '&',\n '(',\n ')',\n '[',\n ']',\n '{',\n '}',\n '^',\n '=',\n ';',\n '!',\n \"'\",\n '+',\n ',',\n '`',\n '~',\n '|',\n '<',\n '>',\n '\"'\n ];\n let needsQuotes = false;\n for (const char of arg) {\n if (cmdSpecialChars.some(x => x === char)) {\n needsQuotes = true;\n break;\n }\n }\n // short-circuit if quotes not needed\n if (!needsQuotes) {\n return arg;\n }\n // the following quoting rules are very similar to the rules that by libuv applies.\n //\n // 1) wrap the string in quotes\n //\n // 2) double-up quotes - i.e. \" => \"\"\n //\n // this is different from the libuv quoting rules. libuv replaces \" with \\\", which unfortunately\n // doesn't work well with a cmd.exe command line.\n //\n // note, replacing \" with \"\" also works well if the arg is passed to a downstream .NET console app.\n // for example, the command line:\n // foo.exe \"myarg:\"\"my val\"\"\"\n // is parsed by a .NET console app into an arg array:\n // [ \"myarg:\\\"my val\\\"\" ]\n // which is the same end result when applying libuv quoting rules. although the actual\n // command line from libuv quoting rules would look like:\n // foo.exe \"myarg:\\\"my val\\\"\"\n //\n // 3) double-up slashes that precede a quote,\n // e.g. hello \\world => \"hello \\world\"\n // hello\\\"world => \"hello\\\\\"\"world\"\n // hello\\\\\"world => \"hello\\\\\\\\\"\"world\"\n // hello world\\ => \"hello world\\\\\"\n //\n // technically this is not required for a cmd.exe command line, or the batch argument parser.\n // the reasons for including this as a .cmd quoting rule are:\n //\n // a) this is optimized for the scenario where the argument is passed from the .cmd file to an\n // external program. many programs (e.g. .NET console apps) rely on the slash-doubling rule.\n //\n // b) it's what we've been doing previously (by deferring to node default behavior) and we\n // haven't heard any complaints about that aspect.\n //\n // note, a weakness of the quoting rules chosen here, is that % is not escaped. in fact, % cannot be\n // escaped when used on the command line directly - even though within a .cmd file % can be escaped\n // by using %%.\n //\n // the saving grace is, on the command line, %var% is left as-is if var is not defined. this contrasts\n // the line parsing rules within a .cmd file, where if var is not defined it is replaced with nothing.\n //\n // one option that was explored was replacing % with ^% - i.e. %var% => ^%var^%. this hack would\n // often work, since it is unlikely that var^ would exist, and the ^ character is removed when the\n // variable is used. the problem, however, is that ^ is not removed when %* is used to pass the args\n // to an external program.\n //\n // an unexplored potential solution for the % escaping problem, is to create a wrapper .cmd file.\n // % can be escaped within a .cmd file.\n let reverse = '\"';\n let quoteHit = true;\n for (let i = arg.length; i > 0; i--) {\n // walk the string in reverse\n reverse += arg[i - 1];\n if (quoteHit && arg[i - 1] === '\\\\') {\n reverse += '\\\\'; // double the slash\n }\n else if (arg[i - 1] === '\"') {\n quoteHit = true;\n reverse += '\"'; // double the quote\n }\n else {\n quoteHit = false;\n }\n }\n reverse += '\"';\n return reverse\n .split('')\n .reverse()\n .join('');\n }\n _uvQuoteCmdArg(arg) {\n // Tool runner wraps child_process.spawn() and needs to apply the same quoting as\n // Node in certain cases where the undocumented spawn option windowsVerbatimArguments\n // is used.\n //\n // Since this function is a port of quote_cmd_arg from Node 4.x (technically, lib UV,\n // see https://github.com/nodejs/node/blob/v4.x/deps/uv/src/win/process.c for details),\n // pasting copyright notice from Node within this function:\n //\n // Copyright Joyent, Inc. and other Node contributors. All rights reserved.\n //\n // Permission is hereby granted, free of charge, to any person obtaining a copy\n // of this software and associated documentation files (the \"Software\"), to\n // deal in the Software without restriction, including without limitation the\n // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or\n // sell copies of the Software, and to permit persons to whom the Software is\n // furnished to do so, subject to the following conditions:\n //\n // The above copyright notice and this permission notice shall be included in\n // all copies or substantial portions of the Software.\n //\n // THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS\n // IN THE SOFTWARE.\n if (!arg) {\n // Need double quotation for empty argument\n return '\"\"';\n }\n if (!arg.includes(' ') && !arg.includes('\\t') && !arg.includes('\"')) {\n // No quotation needed\n return arg;\n }\n if (!arg.includes('\"') && !arg.includes('\\\\')) {\n // No embedded double quotes or backslashes, so I can just wrap\n // quote marks around the whole thing.\n return `\"${arg}\"`;\n }\n // Expected input/output:\n // input : hello\"world\n // output: \"hello\\\"world\"\n // input : hello\"\"world\n // output: \"hello\\\"\\\"world\"\n // input : hello\\world\n // output: hello\\world\n // input : hello\\\\world\n // output: hello\\\\world\n // input : hello\\\"world\n // output: \"hello\\\\\\\"world\"\n // input : hello\\\\\"world\n // output: \"hello\\\\\\\\\\\"world\"\n // input : hello world\\\n // output: \"hello world\\\\\" - note the comment in libuv actually reads \"hello world\\\"\n // but it appears the comment is wrong, it should be \"hello world\\\\\"\n let reverse = '\"';\n let quoteHit = true;\n for (let i = arg.length; i > 0; i--) {\n // walk the string in reverse\n reverse += arg[i - 1];\n if (quoteHit && arg[i - 1] === '\\\\') {\n reverse += '\\\\';\n }\n else if (arg[i - 1] === '\"') {\n quoteHit = true;\n reverse += '\\\\';\n }\n else {\n quoteHit = false;\n }\n }\n reverse += '\"';\n return reverse\n .split('')\n .reverse()\n .join('');\n }\n _cloneExecOptions(options) {\n options = options || {};\n const result = {\n cwd: options.cwd || process.cwd(),\n env: options.env || process.env,\n silent: options.silent || false,\n windowsVerbatimArguments: options.windowsVerbatimArguments || false,\n failOnStdErr: options.failOnStdErr || false,\n ignoreReturnCode: options.ignoreReturnCode || false,\n delay: options.delay || 10000\n };\n result.outStream = options.outStream || process.stdout;\n result.errStream = options.errStream || process.stderr;\n return result;\n }\n _getSpawnOptions(options, toolPath) {\n options = options || {};\n const result = {};\n result.cwd = options.cwd;\n result.env = options.env;\n result['windowsVerbatimArguments'] =\n options.windowsVerbatimArguments || this._isCmdFile();\n if (options.windowsVerbatimArguments) {\n result.argv0 = `\"${toolPath}\"`;\n }\n return result;\n }\n /**\n * Exec a tool.\n * Output will be streamed to the live console.\n * Returns promise with return code\n *\n * @param tool path to tool to exec\n * @param options optional exec options. See ExecOptions\n * @returns number\n */\n exec() {\n return __awaiter(this, void 0, void 0, function* () {\n // root the tool path if it is unrooted and contains relative pathing\n if (!ioUtil.isRooted(this.toolPath) &&\n (this.toolPath.includes('/') ||\n (IS_WINDOWS && this.toolPath.includes('\\\\')))) {\n // prefer options.cwd if it is specified, however options.cwd may also need to be rooted\n this.toolPath = path.resolve(process.cwd(), this.options.cwd || process.cwd(), this.toolPath);\n }\n // if the tool is only a file name, then resolve it from the PATH\n // otherwise verify it exists (add extension on Windows if necessary)\n this.toolPath = yield io.which(this.toolPath, true);\n return new Promise((resolve, reject) => __awaiter(this, void 0, void 0, function* () {\n this._debug(`exec tool: ${this.toolPath}`);\n this._debug('arguments:');\n for (const arg of this.args) {\n this._debug(` ${arg}`);\n }\n const optionsNonNull = this._cloneExecOptions(this.options);\n if (!optionsNonNull.silent && optionsNonNull.outStream) {\n optionsNonNull.outStream.write(this._getCommandString(optionsNonNull) + os.EOL);\n }\n const state = new ExecState(optionsNonNull, this.toolPath);\n state.on('debug', (message) => {\n this._debug(message);\n });\n if (this.options.cwd && !(yield ioUtil.exists(this.options.cwd))) {\n return reject(new Error(`The cwd: ${this.options.cwd} does not exist!`));\n }\n const fileName = this._getSpawnFileName();\n const cp = child.spawn(fileName, this._getSpawnArgs(optionsNonNull), this._getSpawnOptions(this.options, fileName));\n let stdbuffer = '';\n if (cp.stdout) {\n cp.stdout.on('data', (data) => {\n if (this.options.listeners && this.options.listeners.stdout) {\n this.options.listeners.stdout(data);\n }\n if (!optionsNonNull.silent && optionsNonNull.outStream) {\n optionsNonNull.outStream.write(data);\n }\n stdbuffer = this._processLineBuffer(data, stdbuffer, (line) => {\n if (this.options.listeners && this.options.listeners.stdline) {\n this.options.listeners.stdline(line);\n }\n });\n });\n }\n let errbuffer = '';\n if (cp.stderr) {\n cp.stderr.on('data', (data) => {\n state.processStderr = true;\n if (this.options.listeners && this.options.listeners.stderr) {\n this.options.listeners.stderr(data);\n }\n if (!optionsNonNull.silent &&\n optionsNonNull.errStream &&\n optionsNonNull.outStream) {\n const s = optionsNonNull.failOnStdErr\n ? optionsNonNull.errStream\n : optionsNonNull.outStream;\n s.write(data);\n }\n errbuffer = this._processLineBuffer(data, errbuffer, (line) => {\n if (this.options.listeners && this.options.listeners.errline) {\n this.options.listeners.errline(line);\n }\n });\n });\n }\n cp.on('error', (err) => {\n state.processError = err.message;\n state.processExited = true;\n state.processClosed = true;\n state.CheckComplete();\n });\n cp.on('exit', (code) => {\n state.processExitCode = code;\n state.processExited = true;\n this._debug(`Exit code ${code} received from tool '${this.toolPath}'`);\n state.CheckComplete();\n });\n cp.on('close', (code) => {\n state.processExitCode = code;\n state.processExited = true;\n state.processClosed = true;\n this._debug(`STDIO streams have closed for tool '${this.toolPath}'`);\n state.CheckComplete();\n });\n state.on('done', (error, exitCode) => {\n if (stdbuffer.length > 0) {\n this.emit('stdline', stdbuffer);\n }\n if (errbuffer.length > 0) {\n this.emit('errline', errbuffer);\n }\n cp.removeAllListeners();\n if (error) {\n reject(error);\n }\n else {\n resolve(exitCode);\n }\n });\n if (this.options.input) {\n if (!cp.stdin) {\n throw new Error('child process missing stdin');\n }\n cp.stdin.end(this.options.input);\n }\n }));\n });\n }\n}\nexports.ToolRunner = ToolRunner;\n/**\n * Convert an arg string to an array of args. Handles escaping\n *\n * @param argString string of arguments\n * @returns string[] array of arguments\n */\nfunction argStringToArray(argString) {\n const args = [];\n let inQuotes = false;\n let escaped = false;\n let arg = '';\n function append(c) {\n // we only escape double quotes.\n if (escaped && c !== '\"') {\n arg += '\\\\';\n }\n arg += c;\n escaped = false;\n }\n for (let i = 0; i < argString.length; i++) {\n const c = argString.charAt(i);\n if (c === '\"') {\n if (!escaped) {\n inQuotes = !inQuotes;\n }\n else {\n append(c);\n }\n continue;\n }\n if (c === '\\\\' && escaped) {\n append(c);\n continue;\n }\n if (c === '\\\\' && inQuotes) {\n escaped = true;\n continue;\n }\n if (c === ' ' && !inQuotes) {\n if (arg.length > 0) {\n args.push(arg);\n arg = '';\n }\n continue;\n }\n append(c);\n }\n if (arg.length > 0) {\n args.push(arg.trim());\n }\n return args;\n}\nexports.argStringToArray = argStringToArray;\nclass ExecState extends events.EventEmitter {\n constructor(options, toolPath) {\n super();\n this.processClosed = false; // tracks whether the process has exited and stdio is closed\n this.processError = '';\n this.processExitCode = 0;\n this.processExited = false; // tracks whether the process has exited\n this.processStderr = false; // tracks whether stderr was written to\n this.delay = 10000; // 10 seconds\n this.done = false;\n this.timeout = null;\n if (!toolPath) {\n throw new Error('toolPath must not be empty');\n }\n this.options = options;\n this.toolPath = toolPath;\n if (options.delay) {\n this.delay = options.delay;\n }\n }\n CheckComplete() {\n if (this.done) {\n return;\n }\n if (this.processClosed) {\n this._setResult();\n }\n else if (this.processExited) {\n this.timeout = timers_1.setTimeout(ExecState.HandleTimeout, this.delay, this);\n }\n }\n _debug(message) {\n this.emit('debug', message);\n }\n _setResult() {\n // determine whether there is an error\n let error;\n if (this.processExited) {\n if (this.processError) {\n error = new Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`);\n }\n else if (this.processExitCode !== 0 && !this.options.ignoreReturnCode) {\n error = new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`);\n }\n else if (this.processStderr && this.options.failOnStdErr) {\n error = new Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`);\n }\n }\n // clear the timeout\n if (this.timeout) {\n clearTimeout(this.timeout);\n this.timeout = null;\n }\n this.done = true;\n this.emit('done', error, this.processExitCode);\n }\n static HandleTimeout(state) {\n if (state.done) {\n return;\n }\n if (!state.processClosed && state.processExited) {\n const message = `The STDIO streams did not close within ${state.delay /\n 1000} seconds of the exit event from process '${state.toolPath}'. This may indicate a child process inherited the STDIO streams and has not yet exited.`;\n state._debug(message);\n }\n state._setResult();\n }\n}\n//# sourceMappingURL=toolrunner.js.map","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.platform = exports.toPlatformPath = exports.toWin32Path = exports.toPosixPath = exports.markdownSummary = exports.summary = exports.getIDToken = exports.getState = exports.saveState = exports.group = exports.endGroup = exports.startGroup = exports.info = exports.notice = exports.warning = exports.error = exports.debug = exports.isDebug = exports.setFailed = exports.setCommandEcho = exports.setOutput = exports.getBooleanInput = exports.getMultilineInput = exports.getInput = exports.addPath = exports.setSecret = exports.exportVariable = exports.ExitCode = void 0;\nconst command_1 = require(\"./command\");\nconst file_command_1 = require(\"./file-command\");\nconst utils_1 = require(\"./utils\");\nconst os = __importStar(require(\"os\"));\nconst path = __importStar(require(\"path\"));\nconst oidc_utils_1 = require(\"./oidc-utils\");\n/**\n * The code to exit an action\n */\nvar ExitCode;\n(function (ExitCode) {\n /**\n * A code indicating that the action was successful\n */\n ExitCode[ExitCode[\"Success\"] = 0] = \"Success\";\n /**\n * A code indicating that the action was a failure\n */\n ExitCode[ExitCode[\"Failure\"] = 1] = \"Failure\";\n})(ExitCode || (exports.ExitCode = ExitCode = {}));\n//-----------------------------------------------------------------------\n// Variables\n//-----------------------------------------------------------------------\n/**\n * Sets env variable for this action and future actions in the job\n * @param name the name of the variable to set\n * @param val the value of the variable. Non-string values will be converted to a string via JSON.stringify\n */\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction exportVariable(name, val) {\n const convertedVal = (0, utils_1.toCommandValue)(val);\n process.env[name] = convertedVal;\n const filePath = process.env['GITHUB_ENV'] || '';\n if (filePath) {\n return (0, file_command_1.issueFileCommand)('ENV', (0, file_command_1.prepareKeyValueMessage)(name, val));\n }\n (0, command_1.issueCommand)('set-env', { name }, convertedVal);\n}\nexports.exportVariable = exportVariable;\n/**\n * Registers a secret which will get masked from logs\n * @param secret value of the secret\n */\nfunction setSecret(secret) {\n (0, command_1.issueCommand)('add-mask', {}, secret);\n}\nexports.setSecret = setSecret;\n/**\n * Prepends inputPath to the PATH (for this action and future actions)\n * @param inputPath\n */\nfunction addPath(inputPath) {\n const filePath = process.env['GITHUB_PATH'] || '';\n if (filePath) {\n (0, file_command_1.issueFileCommand)('PATH', inputPath);\n }\n else {\n (0, command_1.issueCommand)('add-path', {}, inputPath);\n }\n process.env['PATH'] = `${inputPath}${path.delimiter}${process.env['PATH']}`;\n}\nexports.addPath = addPath;\n/**\n * Gets the value of an input.\n * Unless trimWhitespace is set to false in InputOptions, the value is also trimmed.\n * Returns an empty string if the value is not defined.\n *\n * @param name name of the input to get\n * @param options optional. See InputOptions.\n * @returns string\n */\nfunction getInput(name, options) {\n const val = process.env[`INPUT_${name.replace(/ /g, '_').toUpperCase()}`] || '';\n if (options && options.required && !val) {\n throw new Error(`Input required and not supplied: ${name}`);\n }\n if (options && options.trimWhitespace === false) {\n return val;\n }\n return val.trim();\n}\nexports.getInput = getInput;\n/**\n * Gets the values of an multiline input. Each value is also trimmed.\n *\n * @param name name of the input to get\n * @param options optional. See InputOptions.\n * @returns string[]\n *\n */\nfunction getMultilineInput(name, options) {\n const inputs = getInput(name, options)\n .split('\\n')\n .filter(x => x !== '');\n if (options && options.trimWhitespace === false) {\n return inputs;\n }\n return inputs.map(input => input.trim());\n}\nexports.getMultilineInput = getMultilineInput;\n/**\n * Gets the input value of the boolean type in the YAML 1.2 \"core schema\" specification.\n * Support boolean input list: `true | True | TRUE | false | False | FALSE` .\n * The return value is also in boolean type.\n * ref: https://yaml.org/spec/1.2/spec.html#id2804923\n *\n * @param name name of the input to get\n * @param options optional. See InputOptions.\n * @returns boolean\n */\nfunction getBooleanInput(name, options) {\n const trueValue = ['true', 'True', 'TRUE'];\n const falseValue = ['false', 'False', 'FALSE'];\n const val = getInput(name, options);\n if (trueValue.includes(val))\n return true;\n if (falseValue.includes(val))\n return false;\n throw new TypeError(`Input does not meet YAML 1.2 \"Core Schema\" specification: ${name}\\n` +\n `Support boolean input list: \\`true | True | TRUE | false | False | FALSE\\``);\n}\nexports.getBooleanInput = getBooleanInput;\n/**\n * Sets the value of an output.\n *\n * @param name name of the output to set\n * @param value value to store. Non-string values will be converted to a string via JSON.stringify\n */\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction setOutput(name, value) {\n const filePath = process.env['GITHUB_OUTPUT'] || '';\n if (filePath) {\n return (0, file_command_1.issueFileCommand)('OUTPUT', (0, file_command_1.prepareKeyValueMessage)(name, value));\n }\n process.stdout.write(os.EOL);\n (0, command_1.issueCommand)('set-output', { name }, (0, utils_1.toCommandValue)(value));\n}\nexports.setOutput = setOutput;\n/**\n * Enables or disables the echoing of commands into stdout for the rest of the step.\n * Echoing is disabled by default if ACTIONS_STEP_DEBUG is not set.\n *\n */\nfunction setCommandEcho(enabled) {\n (0, command_1.issue)('echo', enabled ? 'on' : 'off');\n}\nexports.setCommandEcho = setCommandEcho;\n//-----------------------------------------------------------------------\n// Results\n//-----------------------------------------------------------------------\n/**\n * Sets the action status to failed.\n * When the action exits it will be with an exit code of 1\n * @param message add error issue message\n */\nfunction setFailed(message) {\n process.exitCode = ExitCode.Failure;\n error(message);\n}\nexports.setFailed = setFailed;\n//-----------------------------------------------------------------------\n// Logging Commands\n//-----------------------------------------------------------------------\n/**\n * Gets whether Actions Step Debug is on or not\n */\nfunction isDebug() {\n return process.env['RUNNER_DEBUG'] === '1';\n}\nexports.isDebug = isDebug;\n/**\n * Writes debug message to user log\n * @param message debug message\n */\nfunction debug(message) {\n (0, command_1.issueCommand)('debug', {}, message);\n}\nexports.debug = debug;\n/**\n * Adds an error issue\n * @param message error issue message. Errors will be converted to string via toString()\n * @param properties optional properties to add to the annotation.\n */\nfunction error(message, properties = {}) {\n (0, command_1.issueCommand)('error', (0, utils_1.toCommandProperties)(properties), message instanceof Error ? message.toString() : message);\n}\nexports.error = error;\n/**\n * Adds a warning issue\n * @param message warning issue message. Errors will be converted to string via toString()\n * @param properties optional properties to add to the annotation.\n */\nfunction warning(message, properties = {}) {\n (0, command_1.issueCommand)('warning', (0, utils_1.toCommandProperties)(properties), message instanceof Error ? message.toString() : message);\n}\nexports.warning = warning;\n/**\n * Adds a notice issue\n * @param message notice issue message. Errors will be converted to string via toString()\n * @param properties optional properties to add to the annotation.\n */\nfunction notice(message, properties = {}) {\n (0, command_1.issueCommand)('notice', (0, utils_1.toCommandProperties)(properties), message instanceof Error ? message.toString() : message);\n}\nexports.notice = notice;\n/**\n * Writes info to log with console.log.\n * @param message info message\n */\nfunction info(message) {\n process.stdout.write(message + os.EOL);\n}\nexports.info = info;\n/**\n * Begin an output group.\n *\n * Output until the next `groupEnd` will be foldable in this group\n *\n * @param name The name of the output group\n */\nfunction startGroup(name) {\n (0, command_1.issue)('group', name);\n}\nexports.startGroup = startGroup;\n/**\n * End an output group.\n */\nfunction endGroup() {\n (0, command_1.issue)('endgroup');\n}\nexports.endGroup = endGroup;\n/**\n * Wrap an asynchronous function call in a group.\n *\n * Returns the same type as the function itself.\n *\n * @param name The name of the group\n * @param fn The function to wrap in the group\n */\nfunction group(name, fn) {\n return __awaiter(this, void 0, void 0, function* () {\n startGroup(name);\n let result;\n try {\n result = yield fn();\n }\n finally {\n endGroup();\n }\n return result;\n });\n}\nexports.group = group;\n//-----------------------------------------------------------------------\n// Wrapper action state\n//-----------------------------------------------------------------------\n/**\n * Saves state for current action, the state can only be retrieved by this action's post job execution.\n *\n * @param name name of the state to store\n * @param value value to store. Non-string values will be converted to a string via JSON.stringify\n */\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction saveState(name, value) {\n const filePath = process.env['GITHUB_STATE'] || '';\n if (filePath) {\n return (0, file_command_1.issueFileCommand)('STATE', (0, file_command_1.prepareKeyValueMessage)(name, value));\n }\n (0, command_1.issueCommand)('save-state', { name }, (0, utils_1.toCommandValue)(value));\n}\nexports.saveState = saveState;\n/**\n * Gets the value of an state set by this action's main execution.\n *\n * @param name name of the state to get\n * @returns string\n */\nfunction getState(name) {\n return process.env[`STATE_${name}`] || '';\n}\nexports.getState = getState;\nfunction getIDToken(aud) {\n return __awaiter(this, void 0, void 0, function* () {\n return yield oidc_utils_1.OidcClient.getIDToken(aud);\n });\n}\nexports.getIDToken = getIDToken;\n/**\n * Summary exports\n */\nvar summary_1 = require(\"./summary\");\nObject.defineProperty(exports, \"summary\", { enumerable: true, get: function () { return summary_1.summary; } });\n/**\n * @deprecated use core.summary\n */\nvar summary_2 = require(\"./summary\");\nObject.defineProperty(exports, \"markdownSummary\", { enumerable: true, get: function () { return summary_2.markdownSummary; } });\n/**\n * Path exports\n */\nvar path_utils_1 = require(\"./path-utils\");\nObject.defineProperty(exports, \"toPosixPath\", { enumerable: true, get: function () { return path_utils_1.toPosixPath; } });\nObject.defineProperty(exports, \"toWin32Path\", { enumerable: true, get: function () { return path_utils_1.toWin32Path; } });\nObject.defineProperty(exports, \"toPlatformPath\", { enumerable: true, get: function () { return path_utils_1.toPlatformPath; } });\n/**\n * Platform utilities exports\n */\nexports.platform = __importStar(require(\"./platform\"));\n//# sourceMappingURL=core.js.map","\"use strict\";\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.OidcClient = void 0;\nconst http_client_1 = require(\"@actions/http-client\");\nconst auth_1 = require(\"@actions/http-client/lib/auth\");\nconst core_1 = require(\"./core\");\nclass OidcClient {\n static createHttpClient(allowRetry = true, maxRetry = 10) {\n const requestOptions = {\n allowRetries: allowRetry,\n maxRetries: maxRetry\n };\n return new http_client_1.HttpClient('actions/oidc-client', [new auth_1.BearerCredentialHandler(OidcClient.getRequestToken())], requestOptions);\n }\n static getRequestToken() {\n const token = process.env['ACTIONS_ID_TOKEN_REQUEST_TOKEN'];\n if (!token) {\n throw new Error('Unable to get ACTIONS_ID_TOKEN_REQUEST_TOKEN env variable');\n }\n return token;\n }\n static getIDTokenUrl() {\n const runtimeUrl = process.env['ACTIONS_ID_TOKEN_REQUEST_URL'];\n if (!runtimeUrl) {\n throw new Error('Unable to get ACTIONS_ID_TOKEN_REQUEST_URL env variable');\n }\n return runtimeUrl;\n }\n static getCall(id_token_url) {\n var _a;\n return __awaiter(this, void 0, void 0, function* () {\n const httpclient = OidcClient.createHttpClient();\n const res = yield httpclient\n .getJson(id_token_url)\n .catch(error => {\n throw new Error(`Failed to get ID Token. \\n \n Error Code : ${error.statusCode}\\n \n Error Message: ${error.message}`);\n });\n const id_token = (_a = res.result) === null || _a === void 0 ? void 0 : _a.value;\n if (!id_token) {\n throw new Error('Response json body do not have ID Token field');\n }\n return id_token;\n });\n }\n static getIDToken(audience) {\n return __awaiter(this, void 0, void 0, function* () {\n try {\n // New ID Token is requested from action service\n let id_token_url = OidcClient.getIDTokenUrl();\n if (audience) {\n const encodedAudience = encodeURIComponent(audience);\n id_token_url = `${id_token_url}&audience=${encodedAudience}`;\n }\n (0, core_1.debug)(`ID token url is ${id_token_url}`);\n const id_token = yield OidcClient.getCall(id_token_url);\n (0, core_1.setSecret)(id_token);\n return id_token;\n }\n catch (error) {\n throw new Error(`Error message: ${error.message}`);\n }\n });\n }\n}\nexports.OidcClient = OidcClient;\n//# sourceMappingURL=oidc-utils.js.map","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.toPlatformPath = exports.toWin32Path = exports.toPosixPath = void 0;\nconst path = __importStar(require(\"path\"));\n/**\n * toPosixPath converts the given path to the posix form. On Windows, \\\\ will be\n * replaced with /.\n *\n * @param pth. Path to transform.\n * @return string Posix path.\n */\nfunction toPosixPath(pth) {\n return pth.replace(/[\\\\]/g, '/');\n}\nexports.toPosixPath = toPosixPath;\n/**\n * toWin32Path converts the given path to the win32 form. On Linux, / will be\n * replaced with \\\\.\n *\n * @param pth. Path to transform.\n * @return string Win32 path.\n */\nfunction toWin32Path(pth) {\n return pth.replace(/[/]/g, '\\\\');\n}\nexports.toWin32Path = toWin32Path;\n/**\n * toPlatformPath converts the given path to a platform-specific path. It does\n * this by replacing instances of / and \\ with the platform-specific path\n * separator.\n *\n * @param pth The path to platformize.\n * @return string The platform-specific path.\n */\nfunction toPlatformPath(pth) {\n return pth.replace(/[/\\\\]/g, path.sep);\n}\nexports.toPlatformPath = toPlatformPath;\n//# sourceMappingURL=path-utils.js.map","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getDetails = exports.isLinux = exports.isMacOS = exports.isWindows = exports.arch = exports.platform = void 0;\nconst os_1 = __importDefault(require(\"os\"));\nconst exec = __importStar(require(\"@actions/exec\"));\nconst getWindowsInfo = () => __awaiter(void 0, void 0, void 0, function* () {\n const { stdout: version } = yield exec.getExecOutput('powershell -command \"(Get-CimInstance -ClassName Win32_OperatingSystem).Version\"', undefined, {\n silent: true\n });\n const { stdout: name } = yield exec.getExecOutput('powershell -command \"(Get-CimInstance -ClassName Win32_OperatingSystem).Caption\"', undefined, {\n silent: true\n });\n return {\n name: name.trim(),\n version: version.trim()\n };\n});\nconst getMacOsInfo = () => __awaiter(void 0, void 0, void 0, function* () {\n var _a, _b, _c, _d;\n const { stdout } = yield exec.getExecOutput('sw_vers', undefined, {\n silent: true\n });\n const version = (_b = (_a = stdout.match(/ProductVersion:\\s*(.+)/)) === null || _a === void 0 ? void 0 : _a[1]) !== null && _b !== void 0 ? _b : '';\n const name = (_d = (_c = stdout.match(/ProductName:\\s*(.+)/)) === null || _c === void 0 ? void 0 : _c[1]) !== null && _d !== void 0 ? _d : '';\n return {\n name,\n version\n };\n});\nconst getLinuxInfo = () => __awaiter(void 0, void 0, void 0, function* () {\n const { stdout } = yield exec.getExecOutput('lsb_release', ['-i', '-r', '-s'], {\n silent: true\n });\n const [name, version] = stdout.trim().split('\\n');\n return {\n name,\n version\n };\n});\nexports.platform = os_1.default.platform();\nexports.arch = os_1.default.arch();\nexports.isWindows = exports.platform === 'win32';\nexports.isMacOS = exports.platform === 'darwin';\nexports.isLinux = exports.platform === 'linux';\nfunction getDetails() {\n return __awaiter(this, void 0, void 0, function* () {\n return Object.assign(Object.assign({}, (yield (exports.isWindows\n ? getWindowsInfo()\n : exports.isMacOS\n ? getMacOsInfo()\n : getLinuxInfo()))), { platform: exports.platform,\n arch: exports.arch,\n isWindows: exports.isWindows,\n isMacOS: exports.isMacOS,\n isLinux: exports.isLinux });\n });\n}\nexports.getDetails = getDetails;\n//# sourceMappingURL=platform.js.map","import * as core from \"@actions/core\";\nimport ciInfo from \"ci-info\";\nconst { GITHUB_ACTIONS } = ciInfo;\nexport function error(err) {\n return GITHUB_ACTIONS ? core.error(err) : console.log(`\\x1b[31m${err}\\x1b[0m`);\n}\nexport function success(msg) {\n return console.log(`\\x1b[32m${msg}\\x1b[0m`);\n}\nexport function warning(msg) {\n return GITHUB_ACTIONS ? core.warning(msg) : console.log(`\\x1b[33m${msg}\\x1b[0m`);\n}\nexport function notice(msg) {\n return GITHUB_ACTIONS ? core.notice(msg) : console.log(`\\x1b[94m${msg}\\x1b[0m`);\n}\nexport function info(msg) {\n return GITHUB_ACTIONS ? core.info(msg) : console.log(msg);\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxLQUFLLElBQUksTUFBTSxlQUFlLENB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HQUFHLENBQUMsR0FBRyxDQUFDLENBQUE7QUFDM0QsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCAqIGFzIGNvcmUgZnJvbSBcIkBhY3Rpb25zL2NvcmVcIlxuaW1wb3J0IGNpSW5mbyBmcm9tIFwiY2ktaW5mb1wiXG5jb25zdCB7IEdJVEhVQl9BQ1RJT05TIH0gPSBjaUluZm9cblxuZXhwb3J0IGZ1bmN0aW9uIGVycm9yKGVycjogc3RyaW5nIHwgRXJyb3IpIHtcbiAgcmV0dXJuIEdJVEhVQl9BQ1RJT05TID8gY29yZS5lcnJvcihlcnIpIDogY29uc29sZS5sb2coYFxceDFiWzMxbSR7ZXJyfVxceDFiWzBtYClcbn1cblxuZXhwb3J0IGZ1bmN0aW9uIHN1Y2Nlc3MobXNnOiBzdHJpbmcpIHtcbiAgcmV0dXJuIGNvbnNvbGUubG9nKGBcXHgxYlszMm0ke21zZ31cXHgxYlswbWApXG59XG5cbmV4cG9ydCBmdW5jdGlvbiB3YXJuaW5nKG1zZzogc3RyaW5nKSB7XG4gIHJldHVybiBHSVRIVUJfQUNUSU9OUyA/IGNvcmUud2FybmluZyhtc2cpIDogY29uc29sZS5sb2coYFxceDFiWzMzbSR7bXNnfVxceDFiWzBtYClcbn1cblxuZXhwb3J0IGZ1bmN0aW9uIG5vdGljZShtc2c6IHN0cmluZykge1xuICByZXR1cm4gR0lUSFVCX0FDVElPTlMgPyBjb3JlLm5vdGljZShtc2cpIDogY29uc29sZS5sb2coYFxceDFiWzk0bSR7bXNnfVxceDFiWzBtYClcbn1cblxuZXhwb3J0IGZ1bmN0aW9uIGluZm8obXNnOiBzdHJpbmcpIHtcbiAgcmV0dXJuIEdJVEhVQl9BQ1RJT05TID8gY29yZS5pbmZvKG1zZykgOiBjb25zb2xlLmxvZyhtc2cpXG59XG4iXX0=","export default function isPlainObject(value) {\n\tif (typeof value !== 'object' || value === null) {\n\t\treturn false;\n\t}\n\n\tconst prototype = Object.getPrototypeOf(value);\n\treturn (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in value) && !(Symbol.iterator in value);\n}\n","var fs = require('fs')\nvar core\nif (process.platform === 'win32' || global.TESTING_WINDOWS) {\n core = require('./windows.js')\n} else {\n core = require('./mode.js')\n}\n\nmodule.exports = isexe\nisexe.sync = sync\n\nfunction isexe (path, options, cb) {\n if (typeof options === 'function') {\n cb = options\n options = {}\n }\n\n if (!cb) {\n if (typeof Promise !== 'function') {\n throw new TypeError('callback not provided')\n }\n\n return new Promise(function (resolve, reject) {\n isexe(path, options || {}, function (er, is) {\n if (er) {\n reject(er)\n } else {\n resolve(is)\n }\n })\n })\n }\n\n core(path, options || {}, function (er, is) {\n // ignore EACCES because that just means we aren't allowed to run it\n if (er) {\n if (er.code === 'EACCES' || options && options.ignoreErrors) {\n er = null\n is = false\n }\n }\n cb(er, is)\n })\n}\n\nfunction sync (path, options) {\n // my kingdom for a filtered catch\n try {\n return core.sync(path, options || {})\n } catch (er) {\n if (options && options.ignoreErrors || er.code === 'EACCES') {\n return false\n } else {\n throw er\n }\n }\n}\n","'use strict';\n\nconst path = require('path');\nconst which = require('which');\nconst getPathKey = require('path-key');\n\nfunction resolveCommandAttempt(parsed, withoutPathExt) {\n const env = parsed.options.env || process.env;\n const cwd = process.cwd();\n const hasCustomCwd = parsed.options.cwd != null;\n // Worker threads do not have process.chdir()\n const shouldSwitchCwd = hasCustomCwd && process.chdir !== undefined && !process.chdir.disabled;\n\n // If a custom `cwd` was specified, we need to change the process cwd\n // because `which` will do stat calls but does not support a custom cwd\n if (shouldSwitchCwd) {\n try {\n process.chdir(parsed.options.cwd);\n } catch (err) {\n /* Empty */\n }\n }\n\n let resolved;\n\n try {\n resolved = which.sync(parsed.command, {\n path: env[getPathKey({ env })],\n pathExt: withoutPathExt ? path.delimiter : undefined,\n });\n } catch (e) {\n /* Empty */\n } finally {\n if (shouldSwitchCwd) {\n process.chdir(cwd);\n }\n }\n\n // If we successfully resolved, ensure that an absolute path is returned\n // Note that when a custom `cwd` was used, we need to resolve to an absolute path based on it\n if (resolved) {\n resolved = path.resolve(hasCustomCwd ? parsed.options.cwd : '', resolved);\n }\n\n return resolved;\n}\n\nfunction resolveCommand(parsed) {\n return resolveCommandAttempt(parsed) || resolveCommandAttempt(parsed, true);\n}\n\nmodule.exports = resolveCommand;\n","'use strict';\n\nconst isWin = process.platform === 'win32';\n\nfunction notFoundError(original, syscall) {\n return Object.assign(new Error(`${syscall} ${original.command} ENOENT`), {\n code: 'ENOENT',\n errno: 'ENOENT',\n syscall: `${syscall} ${original.command}`,\n path: original.command,\n spawnargs: original.args,\n });\n}\n\nfunction hookChildProcess(cp, parsed) {\n if (!isWin) {\n return;\n }\n\n const originalEmit = cp.emit;\n\n cp.emit = function (name, arg1) {\n // If emitting \"exit\" event and exit code is 1, we need to check if\n // the command exists and emit an \"error\" instead\n // See https://github.com/IndigoUnited/node-cross-spawn/issues/16\n if (name === 'exit') {\n const err = verifyENOENT(arg1, parsed, 'spawn');\n\n if (err) {\n return originalEmit.call(cp, 'error', err);\n }\n }\n\n return originalEmit.apply(cp, arguments); // eslint-disable-line prefer-rest-params\n };\n}\n\nfunction verifyENOENT(status, parsed) {\n if (isWin && status === 1 && !parsed.file) {\n return notFoundError(parsed.original, 'spawn');\n }\n\n return null;\n}\n\nfunction verifyENOENTSync(status, parsed) {\n if (isWin && status === 1 && !parsed.file) {\n return notFoundError(parsed.original, 'spawnSync');\n }\n\n return null;\n}\n\nmodule.exports = {\n hookChildProcess,\n verifyENOENT,\n verifyENOENTSync,\n notFoundError,\n};\n","'use strict';\n\nconst cp = require('child_process');\nconst parse = require('./lib/parse');\nconst enoent = require('./lib/enoent');\n\nfunction spawn(command, args, options) {\n // Parse the arguments\n const parsed = parse(command, args, options);\n\n // Spawn the child process\n const spawned = cp.spawn(parsed.command, parsed.args, parsed.options);\n\n // Hook into child process \"exit\" event to emit an error if the command\n // does not exists, see: https://github.com/IndigoUnited/node-cross-spawn/issues/16\n enoent.hookChildProcess(spawned, parsed);\n\n return spawned;\n}\n\nfunction spawnSync(command, args, options) {\n // Parse the arguments\n const parsed = parse(command, args, options);\n\n // Spawn the child process\n const result = cp.spawnSync(parsed.command, parsed.args, parsed.options);\n\n // Analyze if the command does not exist, see: https://github.com/IndigoUnited/node-cross-spawn/issues/16\n result.error = result.error || enoent.verifyENOENTSync(result.status, parsed);\n\n return result;\n}\n\nmodule.exports = spawn;\nmodule.exports.spawn = spawn;\nmodule.exports.sync = spawnSync;\n\nmodule.exports._parse = parse;\nmodule.exports._enoent = enoent;\n","export default function pathKey(options = {}) {\n\tconst {\n\t\tenv = process.env,\n\t\tplatform = process.platform\n\t} = options;\n\n\tif (platform !== 'win32') {\n\t\treturn 'PATH';\n\t}\n\n\treturn Object.keys(env).reverse().find(key => key.toUpperCase() === 'PATH') || 'Path';\n}\n","import {promisify} from 'node:util';\nimport {execFile as execFileCallback, execFileSync as execFileSyncOriginal} from 'node:child_process';\nimport path from 'node:path';\nimport {fileURLToPath} from 'node:url';\n\nconst execFileOriginal = promisify(execFileCallback);\n\nexport function toPath(urlOrPath) {\n\treturn urlOrPath instanceof URL ? fileURLToPath(urlOrPath) : urlOrPath;\n}\n\nexport function rootDirectory(pathInput) {\n\treturn path.parse(toPath(pathInput)).root;\n}\n\nexport function traversePathUp(startPath) {\n\treturn {\n\t\t* [Symbol.iterator]() {\n\t\t\tlet currentPath = path.resolve(toPath(startPath));\n\t\t\tlet previousPath;\n\n\t\t\twhile (previousPath !== currentPath) {\n\t\t\t\tyield currentPath;\n\t\t\t\tpreviousPath = currentPath;\n\t\t\t\tcurrentPath = path.resolve(currentPath, '..');\n\t\t\t}\n\t\t},\n\t};\n}\n\nconst TEN_MEGABYTES_IN_BYTES = 10 * 1024 * 1024;\n\nexport async function execFile(file, arguments_, options = {}) {\n\treturn execFileOriginal(file, arguments_, {\n\t\tmaxBuffer: TEN_MEGABYTES_IN_BYTES,\n\t\t...options,\n\t});\n}\n\nexport function execFileSync(file, arguments_ = [], options = {}) {\n\treturn execFileSyncOriginal(file, arguments_, {\n\t\tmaxBuffer: TEN_MEGABYTES_IN_BYTES,\n\t\tencoding: 'utf8',\n\t\tstdio: 'pipe',\n\t\t...options,\n\t});\n}\n\nexport * from './default.js';\n","export default function stripFinalNewline(input) {\n\tif (typeof input === 'string') {\n\t\treturn stripFinalNewlineString(input);\n\t}\n\n\tif (!(ArrayBuffer.isView(input) && input.BYTES_PER_ELEMENT === 1)) {\n\t\tthrow new Error('Input must be a string or a Uint8Array');\n\t}\n\n\treturn stripFinalNewlineBinary(input);\n}\n\nconst stripFinalNewlineString = input =>\n\tinput.at(-1) === LF\n\t\t? input.slice(0, input.at(-2) === CR ? -2 : -1)\n\t\t: input;\n\nconst stripFinalNewlineBinary = input =>\n\tinput.at(-1) === LF_BINARY\n\t\t? input.subarray(0, input.at(-2) === CR_BINARY ? -2 : -1)\n\t\t: input;\n\nconst LF = '\\n';\nconst LF_BINARY = LF.codePointAt(0);\nconst CR = '\\r';\nconst CR_BINARY = CR.codePointAt(0);\n","export function isStream(stream, {checkOpen = true} = {}) {\n\treturn stream !== null\n\t\t&& typeof stream === 'object'\n\t\t&& (stream.writable || stream.readable || !checkOpen || (stream.writable === undefined && stream.readable === undefined))\n\t\t&& typeof stream.pipe === 'function';\n}\n\nexport function isWritableStream(stream, {checkOpen = true} = {}) {\n\treturn isStream(stream, {checkOpen})\n\t\t&& (stream.writable || !checkOpen)\n\t\t&& typeof stream.write === 'function'\n\t\t&& typeof stream.end === 'function'\n\t\t&& typeof stream.writable === 'boolean'\n\t\t&& typeof stream.writableObjectMode === 'boolean'\n\t\t&& typeof stream.destroy === 'function'\n\t\t&& typeof stream.destroyed === 'boolean';\n}\n\nexport function isReadableStream(stream, {checkOpen = true} = {}) {\n\treturn isStream(stream, {checkOpen})\n\t\t&& (stream.readable || !checkOpen)\n\t\t&& typeof stream.read === 'function'\n\t\t&& typeof stream.readable === 'boolean'\n\t\t&& typeof stream.readableObjectMode === 'boolean'\n\t\t&& typeof stream.destroy === 'function'\n\t\t&& typeof stream.destroyed === 'boolean';\n}\n\nexport function isDuplexStream(stream, options) {\n\treturn isWritableStream(stream, options)\n\t\t&& isReadableStream(stream, options);\n}\n\nexport function isTransformStream(stream, options) {\n\treturn isDuplexStream(stream, options)\n\t\t&& typeof stream._transform === 'function';\n}\n","const a = Object.getPrototypeOf(\n Object.getPrototypeOf(\n /* istanbul ignore next */\n async function* () {\n }\n ).prototype\n);\nclass c {\n #t;\n #n;\n #r = !1;\n #e = void 0;\n constructor(e, t) {\n this.#t = e, this.#n = t;\n }\n next() {\n const e = () => this.#s();\n return this.#e = this.#e ? this.#e.then(e, e) : e(), this.#e;\n }\n return(e) {\n const t = () => this.#i(e);\n return this.#e ? this.#e.then(t, t) : t();\n }\n async #s() {\n if (this.#r)\n return {\n done: !0,\n value: void 0\n };\n let e;\n try {\n e = await this.#t.read();\n } catch (t) {\n throw this.#e = void 0, this.#r = !0, this.#t.releaseLock(), t;\n }\n return e.done && (this.#e = void 0, this.#r = !0, this.#t.releaseLock()), e;\n }\n async #i(e) {\n if (this.#r)\n return {\n done: !0,\n value: e\n };\n if (this.#r = !0, !this.#n) {\n const t = this.#t.cancel(e);\n return this.#t.releaseLock(), await t, {\n done: !0,\n value: e\n };\n }\n return this.#t.releaseLock(), {\n done: !0,\n value: e\n };\n }\n}\nconst n = Symbol();\nfunction i() {\n return this[n].next();\n}\nObject.defineProperty(i, \"name\", { value: \"next\" });\nfunction o(r) {\n return this[n].return(r);\n}\nObject.defineProperty(o, \"name\", { value: \"return\" });\nconst u = Object.create(a, {\n next: {\n enumerable: !0,\n configurable: !0,\n writable: !0,\n value: i\n },\n return: {\n enumerable: !0,\n configurable: !0,\n writable: !0,\n value: o\n }\n});\nfunction h({ preventCancel: r = !1 } = {}) {\n const e = this.getReader(), t = new c(\n e,\n r\n ), s = Object.create(u);\n return s[n] = t, s;\n}\nexport {\n h as asyncIterator\n};\n","import parseMilliseconds from 'parse-ms';\n\nconst isZero = value => value === 0 || value === 0n;\nconst pluralize = (word, count) => (count === 1 || count === 1n) ? word : `${word}s`;\n\nconst SECOND_ROUNDING_EPSILON = 0.000_000_1;\nconst ONE_DAY_IN_MILLISECONDS = 24n * 60n * 60n * 1000n;\n\nexport default function prettyMilliseconds(milliseconds, options) {\n\tconst isBigInt = typeof milliseconds === 'bigint';\n\tif (!isBigInt && !Number.isFinite(milliseconds)) {\n\t\tthrow new TypeError('Expected a finite number or bigint');\n\t}\n\n\toptions = {...options};\n\n\tconst sign = milliseconds < 0 ? '-' : '';\n\tmilliseconds = milliseconds < 0 ? -milliseconds : milliseconds; // Cannot use `Math.abs()` because of BigInt support.\n\n\tif (options.colonNotation) {\n\t\toptions.compact = false;\n\t\toptions.formatSubMilliseconds = false;\n\t\toptions.separateMilliseconds = false;\n\t\toptions.verbose = false;\n\t}\n\n\tif (options.compact) {\n\t\toptions.unitCount = 1;\n\t\toptions.secondsDecimalDigits = 0;\n\t\toptions.millisecondsDecimalDigits = 0;\n\t}\n\n\tlet result = [];\n\n\tconst floorDecimals = (value, decimalDigits) => {\n\t\tconst flooredInterimValue = Math.floor((value * (10 ** decimalDigits)) + SECOND_ROUNDING_EPSILON);\n\t\tconst flooredValue = Math.round(flooredInterimValue) / (10 ** decimalDigits);\n\t\treturn flooredValue.toFixed(decimalDigits);\n\t};\n\n\tconst add = (value, long, short, valueString) => {\n\t\tif (\n\t\t\t(result.length === 0 || !options.colonNotation)\n\t\t\t&& isZero(value)\n\t\t\t&& !(options.colonNotation && short === 'm')) {\n\t\t\treturn;\n\t\t}\n\n\t\tvalueString ??= String(value);\n\t\tif (options.colonNotation) {\n\t\t\tconst wholeDigits = valueString.includes('.') ? valueString.split('.')[0].length : valueString.length;\n\t\t\tconst minLength = result.length > 0 ? 2 : 1;\n\t\t\tvalueString = '0'.repeat(Math.max(0, minLength - wholeDigits)) + valueString;\n\t\t} else {\n\t\t\tvalueString += options.verbose ? ' ' + pluralize(long, value) : short;\n\t\t}\n\n\t\tresult.push(valueString);\n\t};\n\n\tconst parsed = parseMilliseconds(milliseconds);\n\tconst days = BigInt(parsed.days);\n\n\tadd(days / 365n, 'year', 'y');\n\tadd(days % 365n, 'day', 'd');\n\tadd(Number(parsed.hours), 'hour', 'h');\n\tadd(Number(parsed.minutes), 'minute', 'm');\n\n\tif (\n\t\toptions.separateMilliseconds\n\t\t|| options.formatSubMilliseconds\n\t\t|| (!options.colonNotation && milliseconds < 1000)\n\t) {\n\t\tconst seconds = Number(parsed.seconds);\n\t\tconst milliseconds = Number(parsed.milliseconds);\n\t\tconst microseconds = Number(parsed.microseconds);\n\t\tconst nanoseconds = Number(parsed.nanoseconds);\n\n\t\tadd(seconds, 'second', 's');\n\n\t\tif (options.formatSubMilliseconds) {\n\t\t\tadd(milliseconds, 'millisecond', 'ms');\n\t\t\tadd(microseconds, 'microsecond', 'µs');\n\t\t\tadd(nanoseconds, 'nanosecond', 'ns');\n\t\t} else {\n\t\t\tconst millisecondsAndBelow\n\t\t\t\t= milliseconds\n\t\t\t\t+ (microseconds / 1000)\n\t\t\t\t+ (nanoseconds / 1e6);\n\n\t\t\tconst millisecondsDecimalDigits\n\t\t\t\t= typeof options.millisecondsDecimalDigits === 'number'\n\t\t\t\t\t? options.millisecondsDecimalDigits\n\t\t\t\t\t: 0;\n\n\t\t\tconst roundedMilliseconds = millisecondsAndBelow >= 1\n\t\t\t\t? Math.round(millisecondsAndBelow)\n\t\t\t\t: Math.ceil(millisecondsAndBelow);\n\n\t\t\tconst millisecondsString = millisecondsDecimalDigits\n\t\t\t\t? millisecondsAndBelow.toFixed(millisecondsDecimalDigits)\n\t\t\t\t: roundedMilliseconds;\n\n\t\t\tadd(\n\t\t\t\tNumber.parseFloat(millisecondsString),\n\t\t\t\t'millisecond',\n\t\t\t\t'ms',\n\t\t\t\tmillisecondsString,\n\t\t\t);\n\t\t}\n\t} else {\n\t\tconst seconds = (\n\t\t\t(isBigInt ? Number(milliseconds % ONE_DAY_IN_MILLISECONDS) : milliseconds)\n\t\t\t/ 1000\n\t\t) % 60;\n\t\tconst secondsDecimalDigits\n\t\t\t= typeof options.secondsDecimalDigits === 'number'\n\t\t\t\t? options.secondsDecimalDigits\n\t\t\t\t: 1;\n\t\tconst secondsFixed = floorDecimals(seconds, secondsDecimalDigits);\n\t\tconst secondsString = options.keepDecimalsOnWholeSeconds\n\t\t\t? secondsFixed\n\t\t\t: secondsFixed.replace(/\\.0+$/, '');\n\t\tadd(Number.parseFloat(secondsString), 'second', 's', secondsString);\n\t}\n\n\tif (result.length === 0) {\n\t\treturn sign + '0' + (options.verbose ? ' milliseconds' : 'ms');\n\t}\n\n\tconst separator = options.colonNotation ? ':' : ' ';\n\tif (typeof options.unitCount === 'number') {\n\t\tresult = result.slice(0, Math.max(options.unitCount, 1));\n\t}\n\n\treturn sign + result.join(separator);\n}\n","const toZeroIfInfinity = value => Number.isFinite(value) ? value : 0;\n\nfunction parseNumber(milliseconds) {\n\treturn {\n\t\tdays: Math.trunc(milliseconds / 86_400_000),\n\t\thours: Math.trunc(milliseconds / 3_600_000 % 24),\n\t\tminutes: Math.trunc(milliseconds / 60_000 % 60),\n\t\tseconds: Math.trunc(milliseconds / 1000 % 60),\n\t\tmilliseconds: Math.trunc(milliseconds % 1000),\n\t\tmicroseconds: Math.trunc(toZeroIfInfinity(milliseconds * 1000) % 1000),\n\t\tnanoseconds: Math.trunc(toZeroIfInfinity(milliseconds * 1e6) % 1000),\n\t};\n}\n\nfunction parseBigint(milliseconds) {\n\treturn {\n\t\tdays: milliseconds / 86_400_000n,\n\t\thours: milliseconds / 3_600_000n % 24n,\n\t\tminutes: milliseconds / 60_000n % 60n,\n\t\tseconds: milliseconds / 1000n % 60n,\n\t\tmilliseconds: milliseconds % 1000n,\n\t\tmicroseconds: 0n,\n\t\tnanoseconds: 0n,\n\t};\n}\n\nexport default function parseMilliseconds(milliseconds) {\n\tswitch (typeof milliseconds) {\n\t\tcase 'number': {\n\t\t\tif (Number.isFinite(milliseconds)) {\n\t\t\t\treturn parseNumber(milliseconds);\n\t\t\t}\n\n\t\t\tbreak;\n\t\t}\n\n\t\tcase 'bigint': {\n\t\t\treturn parseBigint(milliseconds);\n\t\t}\n\n\t\t// No default\n\t}\n\n\tthrow new TypeError('Expected a finite number or bigint');\n}\n","import {on, once} from 'node:events';\nimport {PassThrough as PassThroughStream, getDefaultHighWaterMark} from 'node:stream';\nimport {finished} from 'node:stream/promises';\n\nexport default function mergeStreams(streams) {\n\tif (!Array.isArray(streams)) {\n\t\tthrow new TypeError(`Expected an array, got \\`${typeof streams}\\`.`);\n\t}\n\n\tfor (const stream of streams) {\n\t\tvalidateStream(stream);\n\t}\n\n\tconst objectMode = streams.some(({readableObjectMode}) => readableObjectMode);\n\tconst highWaterMark = getHighWaterMark(streams, objectMode);\n\tconst passThroughStream = new MergedStream({\n\t\tobjectMode,\n\t\twritableHighWaterMark: highWaterMark,\n\t\treadableHighWaterMark: highWaterMark,\n\t});\n\n\tfor (const stream of streams) {\n\t\tpassThroughStream.add(stream);\n\t}\n\n\treturn passThroughStream;\n}\n\nconst getHighWaterMark = (streams, objectMode) => {\n\tif (streams.length === 0) {\n\t\treturn getDefaultHighWaterMark(objectMode);\n\t}\n\n\tconst highWaterMarks = streams\n\t\t.filter(({readableObjectMode}) => readableObjectMode === objectMode)\n\t\t.map(({readableHighWaterMark}) => readableHighWaterMark);\n\treturn Math.max(...highWaterMarks);\n};\n\nclass MergedStream extends PassThroughStream {\n\t#streams = new Set([]);\n\t#ended = new Set([]);\n\t#aborted = new Set([]);\n\t#onFinished;\n\t#unpipeEvent = Symbol('unpipe');\n\t#streamPromises = new WeakMap();\n\n\tadd(stream) {\n\t\tvalidateStream(stream);\n\n\t\tif (this.#streams.has(stream)) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.#streams.add(stream);\n\n\t\tthis.#onFinished ??= onMergedStreamFinished(this, this.#streams, this.#unpipeEvent);\n\t\tconst streamPromise = endWhenStreamsDone({\n\t\t\tpassThroughStream: this,\n\t\t\tstream,\n\t\t\tstreams: this.#streams,\n\t\t\tended: this.#ended,\n\t\t\taborted: this.#aborted,\n\t\t\tonFinished: this.#onFinished,\n\t\t\tunpipeEvent: this.#unpipeEvent,\n\t\t});\n\t\tthis.#streamPromises.set(stream, streamPromise);\n\n\t\tstream.pipe(this, {end: false});\n\t}\n\n\tasync remove(stream) {\n\t\tvalidateStream(stream);\n\n\t\tif (!this.#streams.has(stream)) {\n\t\t\treturn false;\n\t\t}\n\n\t\tconst streamPromise = this.#streamPromises.get(stream);\n\t\tif (streamPromise === undefined) {\n\t\t\treturn false;\n\t\t}\n\n\t\tthis.#streamPromises.delete(stream);\n\n\t\tstream.unpipe(this);\n\t\tawait streamPromise;\n\t\treturn true;\n\t}\n}\n\nconst onMergedStreamFinished = async (passThroughStream, streams, unpipeEvent) => {\n\tupdateMaxListeners(passThroughStream, PASSTHROUGH_LISTENERS_COUNT);\n\tconst controller = new AbortController();\n\n\ttry {\n\t\tawait Promise.race([\n\t\t\tonMergedStreamEnd(passThroughStream, controller),\n\t\t\tonInputStreamsUnpipe(passThroughStream, streams, unpipeEvent, controller),\n\t\t]);\n\t} finally {\n\t\tcontroller.abort();\n\t\tupdateMaxListeners(passThroughStream, -PASSTHROUGH_LISTENERS_COUNT);\n\t}\n};\n\nconst onMergedStreamEnd = async (passThroughStream, {signal}) => {\n\ttry {\n\t\tawait finished(passThroughStream, {signal, cleanup: true});\n\t} catch (error) {\n\t\terrorOrAbortStream(passThroughStream, error);\n\t\tthrow error;\n\t}\n};\n\nconst onInputStreamsUnpipe = async (passThroughStream, streams, unpipeEvent, {signal}) => {\n\tfor await (const [unpipedStream] of on(passThroughStream, 'unpipe', {signal})) {\n\t\tif (streams.has(unpipedStream)) {\n\t\t\tunpipedStream.emit(unpipeEvent);\n\t\t}\n\t}\n};\n\nconst validateStream = stream => {\n\tif (typeof stream?.pipe !== 'function') {\n\t\tthrow new TypeError(`Expected a readable stream, got: \\`${typeof stream}\\`.`);\n\t}\n};\n\nconst endWhenStreamsDone = async ({passThroughStream, stream, streams, ended, aborted, onFinished, unpipeEvent}) => {\n\tupdateMaxListeners(passThroughStream, PASSTHROUGH_LISTENERS_PER_STREAM);\n\tconst controller = new AbortController();\n\n\ttry {\n\t\tawait Promise.race([\n\t\t\tafterMergedStreamFinished(onFinished, stream, controller),\n\t\t\tonInputStreamEnd({\n\t\t\t\tpassThroughStream,\n\t\t\t\tstream,\n\t\t\t\tstreams,\n\t\t\t\tended,\n\t\t\t\taborted,\n\t\t\t\tcontroller,\n\t\t\t}),\n\t\t\tonInputStreamUnpipe({\n\t\t\t\tstream,\n\t\t\t\tstreams,\n\t\t\t\tended,\n\t\t\t\taborted,\n\t\t\t\tunpipeEvent,\n\t\t\t\tcontroller,\n\t\t\t}),\n\t\t]);\n\t} finally {\n\t\tcontroller.abort();\n\t\tupdateMaxListeners(passThroughStream, -PASSTHROUGH_LISTENERS_PER_STREAM);\n\t}\n\n\tif (streams.size > 0 && streams.size === ended.size + aborted.size) {\n\t\tif (ended.size === 0 && aborted.size > 0) {\n\t\t\tabortStream(passThroughStream);\n\t\t} else {\n\t\t\tendStream(passThroughStream);\n\t\t}\n\t}\n};\n\nconst afterMergedStreamFinished = async (onFinished, stream, {signal}) => {\n\ttry {\n\t\tawait onFinished;\n\t\tif (!signal.aborted) {\n\t\t\tabortStream(stream);\n\t\t}\n\t} catch (error) {\n\t\tif (!signal.aborted) {\n\t\t\terrorOrAbortStream(stream, error);\n\t\t}\n\t}\n};\n\nconst onInputStreamEnd = async ({passThroughStream, stream, streams, ended, aborted, controller: {signal}}) => {\n\ttry {\n\t\tawait finished(stream, {\n\t\t\tsignal,\n\t\t\tcleanup: true,\n\t\t\treadable: true,\n\t\t\twritable: false,\n\t\t});\n\t\tif (streams.has(stream)) {\n\t\t\tended.add(stream);\n\t\t}\n\t} catch (error) {\n\t\tif (signal.aborted || !streams.has(stream)) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (isAbortError(error)) {\n\t\t\taborted.add(stream);\n\t\t} else {\n\t\t\terrorStream(passThroughStream, error);\n\t\t}\n\t}\n};\n\nconst onInputStreamUnpipe = async ({stream, streams, ended, aborted, unpipeEvent, controller: {signal}}) => {\n\tawait once(stream, unpipeEvent, {signal});\n\n\tif (!stream.readable) {\n\t\treturn once(signal, 'abort', {signal});\n\t}\n\n\tstreams.delete(stream);\n\tended.delete(stream);\n\taborted.delete(stream);\n};\n\nconst endStream = stream => {\n\tif (stream.writable) {\n\t\tstream.end();\n\t}\n};\n\nconst errorOrAbortStream = (stream, error) => {\n\tif (isAbortError(error)) {\n\t\tabortStream(stream);\n\t} else {\n\t\terrorStream(stream, error);\n\t}\n};\n\n// This is the error thrown by `finished()` on `stream.destroy()`\nconst isAbortError = error => error?.code === 'ERR_STREAM_PREMATURE_CLOSE';\n\nconst abortStream = stream => {\n\tif (stream.readable || stream.writable) {\n\t\tstream.destroy();\n\t}\n};\n\n// `stream.destroy(error)` crashes the process with `uncaughtException` if no `error` event listener exists on `stream`.\n// We take care of error handling on user behalf, so we do not want this to happen.\nconst errorStream = (stream, error) => {\n\tif (!stream.destroyed) {\n\t\tstream.once('error', noop);\n\t\tstream.destroy(error);\n\t}\n};\n\nconst noop = () => {};\n\nconst updateMaxListeners = (passThroughStream, increment) => {\n\tconst maxListeners = passThroughStream.getMaxListeners();\n\tif (maxListeners !== 0 && maxListeners !== Number.POSITIVE_INFINITY) {\n\t\tpassThroughStream.setMaxListeners(maxListeners + increment);\n\t}\n};\n\n// Number of times `passThroughStream.on()` is called regardless of streams:\n// - once due to `finished(passThroughStream)`\n// - once due to `on(passThroughStream)`\nconst PASSTHROUGH_LISTENERS_COUNT = 2;\n\n// Number of times `passThroughStream.on()` is called per stream:\n// - once due to `stream.pipe(passThroughStream)`\nconst PASSTHROUGH_LISTENERS_PER_STREAM = 1;\n","import * as execa from \"execa\";\nimport which from \"which\";\n/** The cached powershell path */\nlet powershell;\n/**\n * Asynchronously execute a powershell command.\n *\n * @param command The powershell command to execute\n * @param startupFlags The optional startup flags to be passed to powershell. Defaults to `[\"-NoProfile\", \"-NoLogo\",\n * \"-NonInteractive\"]`. This means that the Powershell profile is not sourced first.\n * @param execOptions The options passed to `execa`. Defaults to `{ stdio: \"inherit\" }`\n * @returns A promise to the execution result\n * @note It prefers `pwsh` over `powershell`\n */\nexport function execPowershell(command, startupFlags = [\"-NoProfile\", \"-NoLogo\", \"-NonInteractive\"], execOptions = { stdio: \"inherit\" }) {\n return execa.execa(getPowerShell(), [...startupFlags, \"-c\", command], execOptions);\n}\n/**\n * Execute a powershell command.\n *\n * @param command The powershell command to execute\n * @param startupFlags The optional startup flags to be passed to powershell. Defaults to `[\"-NoProfile\", \"-NoLogo\",\n * \"-NonInteractive\"]`. This means that the Powershell profile is not sourced first.\n * @param execOptions The options passed to `execa`. Defaults to `{ stdio: \"inherit\" }`\n * @returns The execution result\n * @note It prefers `pwsh` over `powershell`\n */\nexport function execPowershellSync(command, startupFlags = [\"-NoProfile\", \"-NoLogo\", \"-NonInteractive\"], execOptions = { stdio: \"inherit\" }) {\n return execa.execaSync(getPowerShell(), [...startupFlags, \"-c\", command], execOptions);\n}\n/**\n * Get the path to the powershell executable.\n *\n * @note It prefers `pwsh` over `powershell`\n * @note It caches the path for the subsequent calls to this function\n */\nexport function getPowerShell() {\n if (powershell === undefined) {\n const maybePwsh = which.sync(\"pwsh\", { nothrow: true });\n if (maybePwsh !== null) {\n powershell = maybePwsh;\n }\n const maybePowerShell = which.sync(\"powershell\", { nothrow: true });\n if (maybePowerShell !== null) {\n powershell = maybePowerShell;\n }\n }\n if (powershell === undefined) {\n throw new Error(\"Could not find powershell\");\n }\n return powershell;\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQU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CB7IG5vdGhyb3c6IHRydWUgfSlcbiAgICBpZiAobWF5YmVQd3NoICE9PSBudWxsKSB7XG4gICAgICBwb3dlcnNoZWxsID0gbWF5YmVQd3NoXG4gICAgfVxuICAgIGNvbnN0IG1heWJlUG93ZXJTaGVsbCA9IHdoaWNoLnN5bmMoXCJwb3dlcnNoZWxsXCIsIHsgbm90aHJvdzogdHJ1ZSB9KVxuICAgIGlmIChtYXliZVBvd2VyU2hlbGwgIT09IG51bGwpIHtcbiAgICAgIHBvd2Vyc2hlbGwgPSBtYXliZVBvd2VyU2hlbGxcbiAgICB9XG4gIH1cbiAgaWYgKHBvd2Vyc2hlbGwgPT09IHVuZGVmaW5lZCkge1xuICAgIHRocm93IG5ldyBFcnJvcihcIkNvdWxkIG5vdCBmaW5kIHBvd2Vyc2hlbGxcIilcbiAgfVxuICByZXR1cm4gcG93ZXJzaGVsbFxufVxuIl19","export function isStream(stream) {\n\treturn stream !== null\n\t\t&& typeof stream === 'object'\n\t\t&& typeof stream.pipe === 'function';\n}\n\nexport function isWritableStream(stream) {\n\treturn isStream(stream)\n\t\t&& stream.writable !== false\n\t\t&& typeof stream._write === 'function'\n\t\t&& typeof stream._writableState === 'object';\n}\n\nexport function isReadableStream(stream) {\n\treturn isStream(stream)\n\t\t&& stream.readable !== false\n\t\t&& typeof stream._read === 'function'\n\t\t&& typeof stream._readableState === 'object';\n}\n\nexport function isDuplexStream(stream) {\n\treturn isWritableStream(stream)\n\t\t&& isReadableStream(stream);\n}\n\nexport function isTransformStream(stream) {\n\treturn isDuplexStream(stream)\n\t\t&& typeof stream._transform === 'function';\n}\n","'use strict';\nconst {constants: BufferConstants} = require('buffer');\nconst stream = require('stream');\nconst {promisify} = require('util');\nconst bufferStream = require('./buffer-stream');\n\nconst streamPipelinePromisified = promisify(stream.pipeline);\n\nclass MaxBufferError extends Error {\n\tconstructor() {\n\t\tsuper('maxBuffer exceeded');\n\t\tthis.name = 'MaxBufferError';\n\t}\n}\n\nasync function getStream(inputStream, options) {\n\tif (!inputStream) {\n\t\tthrow new Error('Expected a stream');\n\t}\n\n\toptions = {\n\t\tmaxBuffer: Infinity,\n\t\t...options\n\t};\n\n\tconst {maxBuffer} = options;\n\tconst stream = bufferStream(options);\n\n\tawait new Promise((resolve, reject) => {\n\t\tconst rejectPromise = error => {\n\t\t\t// Don't retrieve an oversized buffer.\n\t\t\tif (error && stream.getBufferedLength() <= BufferConstants.MAX_LENGTH) {\n\t\t\t\terror.bufferedData = stream.getBufferedValue();\n\t\t\t}\n\n\t\t\treject(error);\n\t\t};\n\n\t\t(async () => {\n\t\t\ttry {\n\t\t\t\tawait streamPipelinePromisified(inputStream, stream);\n\t\t\t\tresolve();\n\t\t\t} catch (error) {\n\t\t\t\trejectPromise(error);\n\t\t\t}\n\t\t})();\n\n\t\tstream.on('data', () => {\n\t\t\tif (stream.getBufferedLength() > maxBuffer) {\n\t\t\t\trejectPromise(new MaxBufferError());\n\t\t\t}\n\t\t});\n\t});\n\n\treturn stream.getBufferedValue();\n}\n\nmodule.exports = getStream;\nmodule.exports.buffer = (stream, options) => getStream(stream, {...options, encoding: 'buffer'});\nmodule.exports.array = (stream, options) => getStream(stream, {...options, array: true});\nmodule.exports.MaxBufferError = MaxBufferError;\n","import {Buffer} from 'node:buffer';\nimport path from 'node:path';\nimport childProcess from 'node:child_process';\nimport process from 'node:process';\nimport crossSpawn from 'cross-spawn';\nimport stripFinalNewline from 'strip-final-newline';\nimport {npmRunPathEnv} from 'npm-run-path';\nimport onetime from 'onetime';\nimport {makeError} from './lib/error.js';\nimport {normalizeStdio, normalizeStdioNode} from './lib/stdio.js';\nimport {spawnedKill, spawnedCancel, setupTimeout, validateTimeout, setExitHandler} from './lib/kill.js';\nimport {addPipeMethods} from './lib/pipe.js';\nimport {handleInput, getSpawnedResult, makeAllStream, handleInputSync} from './lib/stream.js';\nimport {mergePromise, getSpawnedPromise} from './lib/promise.js';\nimport {joinCommand, parseCommand, parseTemplates, getEscapedCommand} from './lib/command.js';\nimport {logCommand, verboseDefault} from './lib/verbose.js';\n\nconst DEFAULT_MAX_BUFFER = 1000 * 1000 * 100;\n\nconst getEnv = ({env: envOption, extendEnv, preferLocal, localDir, execPath}) => {\n\tconst env = extendEnv ? {...process.env, ...envOption} : envOption;\n\n\tif (preferLocal) {\n\t\treturn npmRunPathEnv({env, cwd: localDir, execPath});\n\t}\n\n\treturn env;\n};\n\nconst handleArguments = (file, args, options = {}) => {\n\tconst parsed = crossSpawn._parse(file, args, options);\n\tfile = parsed.command;\n\targs = parsed.args;\n\toptions = parsed.options;\n\n\toptions = {\n\t\tmaxBuffer: DEFAULT_MAX_BUFFER,\n\t\tbuffer: true,\n\t\tstripFinalNewline: true,\n\t\textendEnv: true,\n\t\tpreferLocal: false,\n\t\tlocalDir: options.cwd || process.cwd(),\n\t\texecPath: process.execPath,\n\t\tencoding: 'utf8',\n\t\treject: true,\n\t\tcleanup: true,\n\t\tall: false,\n\t\twindowsHide: true,\n\t\tverbose: verboseDefault,\n\t\t...options,\n\t};\n\n\toptions.env = getEnv(options);\n\n\toptions.stdio = normalizeStdio(options);\n\n\tif (process.platform === 'win32' && path.basename(file, '.exe') === 'cmd') {\n\t\t// #116\n\t\targs.unshift('/q');\n\t}\n\n\treturn {file, args, options, parsed};\n};\n\nconst handleOutput = (options, value, error) => {\n\tif (typeof value !== 'string' && !Buffer.isBuffer(value)) {\n\t\t// When `execaSync()` errors, we normalize it to '' to mimic `execa()`\n\t\treturn error === undefined ? undefined : '';\n\t}\n\n\tif (options.stripFinalNewline) {\n\t\treturn stripFinalNewline(value);\n\t}\n\n\treturn value;\n};\n\nexport function execa(file, args, options) {\n\tconst parsed = handleArguments(file, args, options);\n\tconst command = joinCommand(file, args);\n\tconst escapedCommand = getEscapedCommand(file, args);\n\tlogCommand(escapedCommand, parsed.options);\n\n\tvalidateTimeout(parsed.options);\n\n\tlet spawned;\n\ttry {\n\t\tspawned = childProcess.spawn(parsed.file, parsed.args, parsed.options);\n\t} catch (error) {\n\t\t// Ensure the returned error is always both a promise and a child process\n\t\tconst dummySpawned = new childProcess.ChildProcess();\n\t\tconst errorPromise = Promise.reject(makeError({\n\t\t\terror,\n\t\t\tstdout: '',\n\t\t\tstderr: '',\n\t\t\tall: '',\n\t\t\tcommand,\n\t\t\tescapedCommand,\n\t\t\tparsed,\n\t\t\ttimedOut: false,\n\t\t\tisCanceled: false,\n\t\t\tkilled: false,\n\t\t}));\n\t\tmergePromise(dummySpawned, errorPromise);\n\t\treturn dummySpawned;\n\t}\n\n\tconst spawnedPromise = getSpawnedPromise(spawned);\n\tconst timedPromise = setupTimeout(spawned, parsed.options, spawnedPromise);\n\tconst processDone = setExitHandler(spawned, parsed.options, timedPromise);\n\n\tconst context = {isCanceled: false};\n\n\tspawned.kill = spawnedKill.bind(null, spawned.kill.bind(spawned));\n\tspawned.cancel = spawnedCancel.bind(null, spawned, context);\n\n\tconst handlePromise = async () => {\n\t\tconst [{error, exitCode, signal, timedOut}, stdoutResult, stderrResult, allResult] = await getSpawnedResult(spawned, parsed.options, processDone);\n\t\tconst stdout = handleOutput(parsed.options, stdoutResult);\n\t\tconst stderr = handleOutput(parsed.options, stderrResult);\n\t\tconst all = handleOutput(parsed.options, allResult);\n\n\t\tif (error || exitCode !== 0 || signal !== null) {\n\t\t\tconst returnedError = makeError({\n\t\t\t\terror,\n\t\t\t\texitCode,\n\t\t\t\tsignal,\n\t\t\t\tstdout,\n\t\t\t\tstderr,\n\t\t\t\tall,\n\t\t\t\tcommand,\n\t\t\t\tescapedCommand,\n\t\t\t\tparsed,\n\t\t\t\ttimedOut,\n\t\t\t\tisCanceled: context.isCanceled || (parsed.options.signal ? parsed.options.signal.aborted : false),\n\t\t\t\tkilled: spawned.killed,\n\t\t\t});\n\n\t\t\tif (!parsed.options.reject) {\n\t\t\t\treturn returnedError;\n\t\t\t}\n\n\t\t\tthrow returnedError;\n\t\t}\n\n\t\treturn {\n\t\t\tcommand,\n\t\t\tescapedCommand,\n\t\t\texitCode: 0,\n\t\t\tstdout,\n\t\t\tstderr,\n\t\t\tall,\n\t\t\tfailed: false,\n\t\t\ttimedOut: false,\n\t\t\tisCanceled: false,\n\t\t\tkilled: false,\n\t\t};\n\t};\n\n\tconst handlePromiseOnce = onetime(handlePromise);\n\n\thandleInput(spawned, parsed.options);\n\n\tspawned.all = makeAllStream(spawned, parsed.options);\n\n\taddPipeMethods(spawned);\n\tmergePromise(spawned, handlePromiseOnce);\n\treturn spawned;\n}\n\nexport function execaSync(file, args, options) {\n\tconst parsed = handleArguments(file, args, options);\n\tconst command = joinCommand(file, args);\n\tconst escapedCommand = getEscapedCommand(file, args);\n\tlogCommand(escapedCommand, parsed.options);\n\n\tconst input = handleInputSync(parsed.options);\n\n\tlet result;\n\ttry {\n\t\tresult = childProcess.spawnSync(parsed.file, parsed.args, {...parsed.options, input});\n\t} catch (error) {\n\t\tthrow makeError({\n\t\t\terror,\n\t\t\tstdout: '',\n\t\t\tstderr: '',\n\t\t\tall: '',\n\t\t\tcommand,\n\t\t\tescapedCommand,\n\t\t\tparsed,\n\t\t\ttimedOut: false,\n\t\t\tisCanceled: false,\n\t\t\tkilled: false,\n\t\t});\n\t}\n\n\tconst stdout = handleOutput(parsed.options, result.stdout, result.error);\n\tconst stderr = handleOutput(parsed.options, result.stderr, result.error);\n\n\tif (result.error || result.status !== 0 || result.signal !== null) {\n\t\tconst error = makeError({\n\t\t\tstdout,\n\t\t\tstderr,\n\t\t\terror: result.error,\n\t\t\tsignal: result.signal,\n\t\t\texitCode: result.status,\n\t\t\tcommand,\n\t\t\tescapedCommand,\n\t\t\tparsed,\n\t\t\ttimedOut: result.error && result.error.code === 'ETIMEDOUT',\n\t\t\tisCanceled: false,\n\t\t\tkilled: result.signal !== null,\n\t\t});\n\n\t\tif (!parsed.options.reject) {\n\t\t\treturn error;\n\t\t}\n\n\t\tthrow error;\n\t}\n\n\treturn {\n\t\tcommand,\n\t\tescapedCommand,\n\t\texitCode: 0,\n\t\tstdout,\n\t\tstderr,\n\t\tfailed: false,\n\t\ttimedOut: false,\n\t\tisCanceled: false,\n\t\tkilled: false,\n\t};\n}\n\nconst normalizeScriptStdin = ({input, inputFile, stdio}) => input === undefined && inputFile === undefined && stdio === undefined\n\t? {stdin: 'inherit'}\n\t: {};\n\nconst normalizeScriptOptions = (options = {}) => ({\n\tpreferLocal: true,\n\t...normalizeScriptStdin(options),\n\t...options,\n});\n\nfunction create$(options) {\n\tfunction $(templatesOrOptions, ...expressions) {\n\t\tif (!Array.isArray(templatesOrOptions)) {\n\t\t\treturn create$({...options, ...templatesOrOptions});\n\t\t}\n\n\t\tconst [file, ...args] = parseTemplates(templatesOrOptions, expressions);\n\t\treturn execa(file, args, normalizeScriptOptions(options));\n\t}\n\n\t$.sync = (templates, ...expressions) => {\n\t\tif (!Array.isArray(templates)) {\n\t\t\tthrow new TypeError('Please use $(options).sync`command` instead of $.sync(options)`command`.');\n\t\t}\n\n\t\tconst [file, ...args] = parseTemplates(templates, expressions);\n\t\treturn execaSync(file, args, normalizeScriptOptions(options));\n\t};\n\n\treturn $;\n}\n\nexport const $ = create$();\n\nexport function execaCommand(command, options) {\n\tconst [file, ...args] = parseCommand(command);\n\treturn execa(file, args, options);\n}\n\nexport function execaCommandSync(command, options) {\n\tconst [file, ...args] = parseCommand(command);\n\treturn execaSync(file, args, options);\n}\n\nexport function execaNode(scriptPath, args, options = {}) {\n\tif (args && !Array.isArray(args) && typeof args === 'object') {\n\t\toptions = args;\n\t\targs = [];\n\t}\n\n\tconst stdio = normalizeStdioNode(options);\n\tconst defaultExecArgv = process.execArgv.filter(arg => !arg.startsWith('--inspect'));\n\n\tconst {\n\t\tnodePath = process.execPath,\n\t\tnodeOptions = defaultExecArgv,\n\t} = options;\n\n\treturn execa(\n\t\tnodePath,\n\t\t[\n\t\t\t...nodeOptions,\n\t\t\tscriptPath,\n\t\t\t...(Array.isArray(args) ? args : []),\n\t\t],\n\t\t{\n\t\t\t...options,\n\t\t\tstdin: undefined,\n\t\t\tstdout: undefined,\n\t\t\tstderr: undefined,\n\t\t\tstdio,\n\t\t\tshell: false,\n\t\t},\n\t);\n}\n","import os from 'node:os';\nimport onExit from 'signal-exit';\n\nconst DEFAULT_FORCE_KILL_TIMEOUT = 1000 * 5;\n\n// Monkey-patches `childProcess.kill()` to add `forceKillAfterTimeout` behavior\nexport const spawnedKill = (kill, signal = 'SIGTERM', options = {}) => {\n\tconst killResult = kill(signal);\n\tsetKillTimeout(kill, signal, options, killResult);\n\treturn killResult;\n};\n\nconst setKillTimeout = (kill, signal, options, killResult) => {\n\tif (!shouldForceKill(signal, options, killResult)) {\n\t\treturn;\n\t}\n\n\tconst timeout = getForceKillAfterTimeout(options);\n\tconst t = setTimeout(() => {\n\t\tkill('SIGKILL');\n\t}, timeout);\n\n\t// Guarded because there's no `.unref()` when `execa` is used in the renderer\n\t// process in Electron. This cannot be tested since we don't run tests in\n\t// Electron.\n\t// istanbul ignore else\n\tif (t.unref) {\n\t\tt.unref();\n\t}\n};\n\nconst shouldForceKill = (signal, {forceKillAfterTimeout}, killResult) => isSigterm(signal) && forceKillAfterTimeout !== false && killResult;\n\nconst isSigterm = signal => signal === os.constants.signals.SIGTERM\n\t\t|| (typeof signal === 'string' && signal.toUpperCase() === 'SIGTERM');\n\nconst getForceKillAfterTimeout = ({forceKillAfterTimeout = true}) => {\n\tif (forceKillAfterTimeout === true) {\n\t\treturn DEFAULT_FORCE_KILL_TIMEOUT;\n\t}\n\n\tif (!Number.isFinite(forceKillAfterTimeout) || forceKillAfterTimeout < 0) {\n\t\tthrow new TypeError(`Expected the \\`forceKillAfterTimeout\\` option to be a non-negative integer, got \\`${forceKillAfterTimeout}\\` (${typeof forceKillAfterTimeout})`);\n\t}\n\n\treturn forceKillAfterTimeout;\n};\n\n// `childProcess.cancel()`\nexport const spawnedCancel = (spawned, context) => {\n\tconst killResult = spawned.kill();\n\n\tif (killResult) {\n\t\tcontext.isCanceled = true;\n\t}\n};\n\nconst timeoutKill = (spawned, signal, reject) => {\n\tspawned.kill(signal);\n\treject(Object.assign(new Error('Timed out'), {timedOut: true, signal}));\n};\n\n// `timeout` option handling\nexport const setupTimeout = (spawned, {timeout, killSignal = 'SIGTERM'}, spawnedPromise) => {\n\tif (timeout === 0 || timeout === undefined) {\n\t\treturn spawnedPromise;\n\t}\n\n\tlet timeoutId;\n\tconst timeoutPromise = new Promise((resolve, reject) => {\n\t\ttimeoutId = setTimeout(() => {\n\t\t\ttimeoutKill(spawned, killSignal, reject);\n\t\t}, timeout);\n\t});\n\n\tconst safeSpawnedPromise = spawnedPromise.finally(() => {\n\t\tclearTimeout(timeoutId);\n\t});\n\n\treturn Promise.race([timeoutPromise, safeSpawnedPromise]);\n};\n\nexport const validateTimeout = ({timeout}) => {\n\tif (timeout !== undefined && (!Number.isFinite(timeout) || timeout < 0)) {\n\t\tthrow new TypeError(`Expected the \\`timeout\\` option to be a non-negative integer, got \\`${timeout}\\` (${typeof timeout})`);\n\t}\n};\n\n// `cleanup` option handling\nexport const setExitHandler = async (spawned, {cleanup, detached}, timedPromise) => {\n\tif (!cleanup || detached) {\n\t\treturn timedPromise;\n\t}\n\n\tconst removeExitHandler = onExit(() => {\n\t\tspawned.kill();\n\t});\n\n\treturn timedPromise.finally(() => {\n\t\tremoveExitHandler();\n\t});\n};\n","// eslint-disable-next-line unicorn/prefer-top-level-await\nconst nativePromisePrototype = (async () => {})().constructor.prototype;\n\nconst descriptors = ['then', 'catch', 'finally'].map(property => [\n\tproperty,\n\tReflect.getOwnPropertyDescriptor(nativePromisePrototype, property),\n]);\n\n// The return value is a mixin of `childProcess` and `Promise`\nexport const mergePromise = (spawned, promise) => {\n\tfor (const [property, descriptor] of descriptors) {\n\t\t// Starting the main `promise` is deferred to avoid consuming streams\n\t\tconst value = typeof promise === 'function'\n\t\t\t? (...args) => Reflect.apply(descriptor.value, promise(), args)\n\t\t\t: descriptor.value.bind(promise);\n\n\t\tReflect.defineProperty(spawned, property, {...descriptor, value});\n\t}\n};\n\n// Use promises instead of `child_process` events\nexport const getSpawnedPromise = spawned => new Promise((resolve, reject) => {\n\tspawned.on('exit', (exitCode, signal) => {\n\t\tresolve({exitCode, signal});\n\t});\n\n\tspawned.on('error', error => {\n\t\treject(error);\n\t});\n\n\tif (spawned.stdin) {\n\t\tspawned.stdin.on('error', error => {\n\t\t\treject(error);\n\t\t});\n\t}\n});\n","import {createReadStream, readFileSync} from 'node:fs';\nimport {isStream} from 'is-stream';\nimport getStream from 'get-stream';\nimport mergeStream from 'merge-stream';\n\nconst validateInputOptions = input => {\n\tif (input !== undefined) {\n\t\tthrow new TypeError('The `input` and `inputFile` options cannot be both set.');\n\t}\n};\n\nconst getInputSync = ({input, inputFile}) => {\n\tif (typeof inputFile !== 'string') {\n\t\treturn input;\n\t}\n\n\tvalidateInputOptions(input);\n\treturn readFileSync(inputFile);\n};\n\n// `input` and `inputFile` option in sync mode\nexport const handleInputSync = options => {\n\tconst input = getInputSync(options);\n\n\tif (isStream(input)) {\n\t\tthrow new TypeError('The `input` option cannot be a stream in sync mode');\n\t}\n\n\treturn input;\n};\n\nconst getInput = ({input, inputFile}) => {\n\tif (typeof inputFile !== 'string') {\n\t\treturn input;\n\t}\n\n\tvalidateInputOptions(input);\n\treturn createReadStream(inputFile);\n};\n\n// `input` and `inputFile` option in async mode\nexport const handleInput = (spawned, options) => {\n\tconst input = getInput(options);\n\n\tif (input === undefined) {\n\t\treturn;\n\t}\n\n\tif (isStream(input)) {\n\t\tinput.pipe(spawned.stdin);\n\t} else {\n\t\tspawned.stdin.end(input);\n\t}\n};\n\n// `all` interleaves `stdout` and `stderr`\nexport const makeAllStream = (spawned, {all}) => {\n\tif (!all || (!spawned.stdout && !spawned.stderr)) {\n\t\treturn;\n\t}\n\n\tconst mixed = mergeStream();\n\n\tif (spawned.stdout) {\n\t\tmixed.add(spawned.stdout);\n\t}\n\n\tif (spawned.stderr) {\n\t\tmixed.add(spawned.stderr);\n\t}\n\n\treturn mixed;\n};\n\n// On failure, `result.stdout|stderr|all` should contain the currently buffered stream\nconst getBufferedData = async (stream, streamPromise) => {\n\t// When `buffer` is `false`, `streamPromise` is `undefined` and there is no buffered data to retrieve\n\tif (!stream || streamPromise === undefined) {\n\t\treturn;\n\t}\n\n\tstream.destroy();\n\n\ttry {\n\t\treturn await streamPromise;\n\t} catch (error) {\n\t\treturn error.bufferedData;\n\t}\n};\n\nconst getStreamPromise = (stream, {encoding, buffer, maxBuffer}) => {\n\tif (!stream || !buffer) {\n\t\treturn;\n\t}\n\n\tif (encoding) {\n\t\treturn getStream(stream, {encoding, maxBuffer});\n\t}\n\n\treturn getStream.buffer(stream, {maxBuffer});\n};\n\n// Retrieve result of child process: exit code, signal, error, streams (stdout/stderr/all)\nexport const getSpawnedResult = async ({stdout, stderr, all}, {encoding, buffer, maxBuffer}, processDone) => {\n\tconst stdoutPromise = getStreamPromise(stdout, {encoding, buffer, maxBuffer});\n\tconst stderrPromise = getStreamPromise(stderr, {encoding, buffer, maxBuffer});\n\tconst allPromise = getStreamPromise(all, {encoding, buffer, maxBuffer: maxBuffer * 2});\n\n\ttry {\n\t\treturn await Promise.all([processDone, stdoutPromise, stderrPromise, allPromise]);\n\t} catch (error) {\n\t\treturn Promise.all([\n\t\t\t{error, signal: error.signal, timedOut: error.timedOut},\n\t\t\tgetBufferedData(stdout, stdoutPromise),\n\t\t\tgetBufferedData(stderr, stderrPromise),\n\t\t\tgetBufferedData(all, allPromise),\n\t\t]);\n\t}\n};\n","import {createWriteStream} from 'node:fs';\nimport {ChildProcess} from 'node:child_process';\nimport {isWritableStream} from 'is-stream';\n\nconst isExecaChildProcess = target => target instanceof ChildProcess && typeof target.then === 'function';\n\nconst pipeToTarget = (spawned, streamName, target) => {\n\tif (typeof target === 'string') {\n\t\tspawned[streamName].pipe(createWriteStream(target));\n\t\treturn spawned;\n\t}\n\n\tif (isWritableStream(target)) {\n\t\tspawned[streamName].pipe(target);\n\t\treturn spawned;\n\t}\n\n\tif (!isExecaChildProcess(target)) {\n\t\tthrow new TypeError('The second argument must be a string, a stream or an Execa child process.');\n\t}\n\n\tif (!isWritableStream(target.stdin)) {\n\t\tthrow new TypeError('The target child process\\'s stdin must be available.');\n\t}\n\n\tspawned[streamName].pipe(target.stdin);\n\treturn target;\n};\n\nexport const addPipeMethods = spawned => {\n\tif (spawned.stdout !== null) {\n\t\tspawned.pipeStdout = pipeToTarget.bind(undefined, spawned, 'stdout');\n\t}\n\n\tif (spawned.stderr !== null) {\n\t\tspawned.pipeStderr = pipeToTarget.bind(undefined, spawned, 'stderr');\n\t}\n\n\tif (spawned.all !== undefined) {\n\t\tspawned.pipeAll = pipeToTarget.bind(undefined, spawned, 'all');\n\t}\n};\n","function e(e,t,r,o){Object.defineProperty(e,t,{get:r,set:o,enumerable:!0,configurable:!0})}function t(){return null!==m.sync(\"sudo\",{nothrow:!0})}function r(){return process.getuid?.()===0||!!process.env.CI}function o(){return r()&&t()}function n(e){return o()?`sudo ${e}`:e}function s(e,t=[],r=h){return o()?b(a(e,t),r):l(e,i(t),r)}function c(e,t=[],r=h){return o()?y(a(e,t),r):S(e,i(t),r)}function a(e,t){return`sudo ${i([e,...t]).join(\" \")}`}function i(e){return e.map(e=>`'${e}'`)}async function d(){try{return await S(\"fltmc\"),!0}catch{return!1}}async function u(){if(\"win32\"!==process.platform)return!1;try{return await S(\"fsutil\",[\"dirty\",\"query\",process.env.systemdrive??\"\"]),!0}catch(e){if(\"ENOENT\"===e.code)return d();return!1}}function f(){return\"win32\"===process.platform?R():r()}async function p(e){if((\"linux\"===process.platform||\"darwin\"===process.platform)&&o()&&void 0!==process.env.SUDO_USER){let t=w.statSync(e).isDirectory();await c(\"chown\",[...t?[\"-R\"]:[],process.env.SUDO_USER,e],h)}}var $,x={};import m from\"which\";import{execaCommandSync as b,execaSync as l,execaCommand as y,execa as S}from\"execa\";import w from\"fs\";e(x,\"hasSudo\",()=>t),e(x,\"isRoot\",()=>r),e(x,\"isSudo\",()=>o),e(x,\"prependSudo\",()=>n),e(x,\"defaultExecOptions\",()=>h),e(x,\"execRootSync\",()=>s),e(x,\"execRoot\",()=>c);let h={stdio:\"inherit\",shell:!0};e($={},\"isAdminWindows\",()=>R),e($,\"isAdminPosix\",()=>A),e($,\"isAdmin\",()=>f);let R=u,A=r;e({},\"grantUserWriteAccess\",()=>p);export{t as hasSudo,r as isRoot,o as isSudo,n as prependSudo,h as defaultExecOptions,s as execRootSync,c as execRoot,R as isAdminWindows,A as isAdminPosix,f as isAdmin,p as grantUserWriteAccess};\n//# sourceMappingURL=index.node.mjs.map\n","\"use strict\";\n\nvar value = require(\"./valid-value\")\n , defineProperty = Object.defineProperty\n , getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor\n , getOwnPropertyNames = Object.getOwnPropertyNames\n , getOwnPropertySymbols = Object.getOwnPropertySymbols;\n\nmodule.exports = function (target, source) {\n\tvar error, sourceObject = Object(value(source));\n\ttarget = Object(value(target));\n\tgetOwnPropertyNames(sourceObject).forEach(function (name) {\n\t\ttry {\n\t\t\tdefineProperty(target, name, getOwnPropertyDescriptor(source, name));\n\t\t} catch (e) { error = e; }\n\t});\n\tif (typeof getOwnPropertySymbols === \"function\") {\n\t\tgetOwnPropertySymbols(sourceObject).forEach(function (symbol) {\n\t\t\ttry {\n\t\t\t\tdefineProperty(target, symbol, getOwnPropertyDescriptor(source, symbol));\n\t\t\t} catch (e) { error = e; }\n\t\t});\n\t}\n\tif (error !== undefined) throw error;\n\treturn target;\n};\n","\"use strict\";\n\nmodule.exports = require(\"./is-implemented\")() ? globalThis : require(\"./implementation\");\n","\"use strict\";\n\nmodule.exports = function () {\n\tif (typeof globalThis !== \"object\") return false;\n\tif (!globalThis) return false;\n\treturn globalThis.Array === Array;\n};\n","var naiveFallback = function () {\n\tif (typeof self === \"object\" && self) return self;\n\tif (typeof window === \"object\" && window) return window;\n\tthrow new Error(\"Unable to resolve global `this`\");\n};\n\nmodule.exports = (function () {\n\tif (this) return this;\n\n\t// Unexpected strict mode (may happen if e.g. bundled into ESM module)\n\n\t// Thanks @mathiasbynens -> https://mathiasbynens.be/notes/globalthis\n\t// In all ES5+ engines global object inherits from Object.prototype\n\t// (if you approached one that doesn't please report)\n\ttry {\n\t\tObject.defineProperty(Object.prototype, \"__global__\", {\n\t\t\tget: function () { return this; },\n\t\t\tconfigurable: true\n\t\t});\n\t} catch (error) {\n\t\t// Unfortunate case of Object.prototype being sealed (via preventExtensions, seal or freeze)\n\t\treturn naiveFallback();\n\t}\n\ttry {\n\t\t// Safari case (window.__global__ is resolved with global context, but __global__ does not)\n\t\tif (!__global__) return naiveFallback();\n\t\treturn __global__;\n\t} finally {\n\t\tdelete Object.prototype.__global__;\n\t}\n})();\n","\"use strict\";\n\nvar isSymbol = require(\"./is-symbol\");\n\nmodule.exports = function (value) {\n\tif (!isSymbol(value)) throw new TypeError(value + \" is not a symbol\");\n\treturn value;\n};\n","\"use strict\";\n\nmodule.exports = function (value) {\n\tif (!value) return false;\n\tif (typeof value === \"symbol\") return true;\n\tif (!value.constructor) return false;\n\tif (value.constructor.name !== \"Symbol\") return false;\n\treturn value[value.constructor.toStringTag] === \"Symbol\";\n};\n","\"use strict\";\n\nmodule.exports = require(\"./is-implemented\")()\n\t? require(\"ext/global-this\").Symbol\n\t: require(\"./polyfill\");\n","\"use strict\";\n\nvar global = require(\"ext/global-this\")\n , validTypes = { object: true, symbol: true };\n\nmodule.exports = function () {\n\tvar Symbol = global.Symbol;\n\tvar symbol;\n\tif (typeof Symbol !== \"function\") return false;\n\tsymbol = Symbol(\"test symbol\");\n\ttry { String(symbol); }\n\tcatch (e) { return false; }\n\n\t// Return 'true' also for polyfills\n\tif (!validTypes[typeof Symbol.iterator]) return false;\n\tif (!validTypes[typeof Symbol.toPrimitive]) return false;\n\tif (!validTypes[typeof Symbol.toStringTag]) return false;\n\n\treturn true;\n};\n","// ES2015 Symbol polyfill for environments that do not (or partially) support it\n\n\"use strict\";\n\nvar d = require(\"d\")\n , validateSymbol = require(\"./validate-symbol\")\n , NativeSymbol = require(\"ext/global-this\").Symbol\n , generateName = require(\"./lib/private/generate-name\")\n , setupStandardSymbols = require(\"./lib/private/setup/standard-symbols\")\n , setupSymbolRegistry = require(\"./lib/private/setup/symbol-registry\");\n\nvar create = Object.create\n , defineProperties = Object.defineProperties\n , defineProperty = Object.defineProperty;\n\nvar SymbolPolyfill, HiddenSymbol, isNativeSafe;\n\nif (typeof NativeSymbol === \"function\") {\n\ttry {\n\t\tString(NativeSymbol());\n\t\tisNativeSafe = true;\n\t} catch (ignore) {}\n} else {\n\tNativeSymbol = null;\n}\n\n// Internal constructor (not one exposed) for creating Symbol instances.\n// This one is used to ensure that `someSymbol instanceof Symbol` always return false\nHiddenSymbol = function Symbol(description) {\n\tif (this instanceof HiddenSymbol) throw new TypeError(\"Symbol is not a constructor\");\n\treturn SymbolPolyfill(description);\n};\n\n// Exposed `Symbol` constructor\n// (returns instances of HiddenSymbol)\nmodule.exports = SymbolPolyfill = function Symbol(description) {\n\tvar symbol;\n\tif (this instanceof Symbol) throw new TypeError(\"Symbol is not a constructor\");\n\tif (isNativeSafe) return NativeSymbol(description);\n\tsymbol = create(HiddenSymbol.prototype);\n\tdescription = description === undefined ? \"\" : String(description);\n\treturn defineProperties(symbol, {\n\t\t__description__: d(\"\", description),\n\t\t__name__: d(\"\", generateName(description))\n\t});\n};\n\nsetupStandardSymbols(SymbolPolyfill);\nsetupSymbolRegistry(SymbolPolyfill);\n\n// Internal tweaks for real symbol producer\ndefineProperties(HiddenSymbol.prototype, {\n\tconstructor: d(SymbolPolyfill),\n\ttoString: d(\"\", function () { return this.__name__; })\n});\n\n// Proper implementation of methods exposed on Symbol.prototype\n// They won't be accessible on produced symbol instances as they derive from HiddenSymbol.prototype\ndefineProperties(SymbolPolyfill.prototype, {\n\ttoString: d(function () { return \"Symbol (\" + validateSymbol(this).__description__ + \")\"; }),\n\tvalueOf: d(function () { return validateSymbol(this); })\n});\ndefineProperty(\n\tSymbolPolyfill.prototype, SymbolPolyfill.toPrimitive,\n\td(\"\", function () {\n\t\tvar symbol = validateSymbol(this);\n\t\tif (typeof symbol === \"symbol\") return symbol;\n\t\treturn symbol.toString();\n\t})\n);\ndefineProperty(SymbolPolyfill.prototype, SymbolPolyfill.toStringTag, d(\"c\", \"Symbol\"));\n\n// Proper implementaton of toPrimitive and toStringTag for returned symbol instances\ndefineProperty(\n\tHiddenSymbol.prototype, SymbolPolyfill.toStringTag,\n\td(\"c\", SymbolPolyfill.prototype[SymbolPolyfill.toStringTag])\n);\n\n// Note: It's important to define `toPrimitive` as last one, as some implementations\n// implement `toPrimitive` natively without implementing `toStringTag` (or other specified symbols)\n// And that may invoke error in definition flow:\n// See: https://github.com/medikoo/es6-symbol/issues/13#issuecomment-164146149\ndefineProperty(\n\tHiddenSymbol.prototype, SymbolPolyfill.toPrimitive,\n\td(\"c\", SymbolPolyfill.prototype[SymbolPolyfill.toPrimitive])\n);\n","\"use strict\";\n\nvar d = require(\"d\");\n\nvar create = Object.create, defineProperty = Object.defineProperty, objPrototype = Object.prototype;\n\nvar created = create(null);\nmodule.exports = function (desc) {\n\tvar postfix = 0, name, ie11BugWorkaround;\n\twhile (created[desc + (postfix || \"\")]) ++postfix;\n\tdesc += postfix || \"\";\n\tcreated[desc] = true;\n\tname = \"@@\" + desc;\n\tdefineProperty(\n\t\tobjPrototype, name,\n\t\td.gs(null, function (value) {\n\t\t\t// For IE11 issue see:\n\t\t\t// https://connect.microsoft.com/IE/feedbackdetail/view/1928508/\n\t\t\t// ie11-broken-getters-on-dom-objects\n\t\t\t// https://github.com/medikoo/es6-symbol/issues/12\n\t\t\tif (ie11BugWorkaround) return;\n\t\t\tie11BugWorkaround = true;\n\t\t\tdefineProperty(this, name, d(value));\n\t\t\tie11BugWorkaround = false;\n\t\t})\n\t);\n\treturn name;\n};\n","\"use strict\";\n\nvar d = require(\"d\")\n , NativeSymbol = require(\"ext/global-this\").Symbol;\n\nmodule.exports = function (SymbolPolyfill) {\n\treturn Object.defineProperties(SymbolPolyfill, {\n\t\t// To ensure proper interoperability with other native functions (e.g. Array.from)\n\t\t// fallback to eventual native implementation of given symbol\n\t\thasInstance: d(\n\t\t\t\"\", (NativeSymbol && NativeSymbol.hasInstance) || SymbolPolyfill(\"hasInstance\")\n\t\t),\n\t\tisConcatSpreadable: d(\n\t\t\t\"\",\n\t\t\t(NativeSymbol && NativeSymbol.isConcatSpreadable) ||\n\t\t\t\tSymbolPolyfill(\"isConcatSpreadable\")\n\t\t),\n\t\titerator: d(\"\", (NativeSymbol && NativeSymbol.iterator) || SymbolPolyfill(\"iterator\")),\n\t\tmatch: d(\"\", (NativeSymbol && NativeSymbol.match) || SymbolPolyfill(\"match\")),\n\t\treplace: d(\"\", (NativeSymbol && NativeSymbol.replace) || SymbolPolyfill(\"replace\")),\n\t\tsearch: d(\"\", (NativeSymbol && NativeSymbol.search) || SymbolPolyfill(\"search\")),\n\t\tspecies: d(\"\", (NativeSymbol && NativeSymbol.species) || SymbolPolyfill(\"species\")),\n\t\tsplit: d(\"\", (NativeSymbol && NativeSymbol.split) || SymbolPolyfill(\"split\")),\n\t\ttoPrimitive: d(\n\t\t\t\"\", (NativeSymbol && NativeSymbol.toPrimitive) || SymbolPolyfill(\"toPrimitive\")\n\t\t),\n\t\ttoStringTag: d(\n\t\t\t\"\", (NativeSymbol && NativeSymbol.toStringTag) || SymbolPolyfill(\"toStringTag\")\n\t\t),\n\t\tunscopables: d(\n\t\t\t\"\", (NativeSymbol && NativeSymbol.unscopables) || SymbolPolyfill(\"unscopables\")\n\t\t)\n\t});\n};\n","\"use strict\";\n\nvar d = require(\"d\")\n , validateSymbol = require(\"../../../validate-symbol\");\n\nvar registry = Object.create(null);\n\nmodule.exports = function (SymbolPolyfill) {\n\treturn Object.defineProperties(SymbolPolyfill, {\n\t\tfor: d(function (key) {\n\t\t\tif (registry[key]) return registry[key];\n\t\t\treturn (registry[key] = SymbolPolyfill(String(key)));\n\t\t}),\n\t\tkeyFor: d(function (symbol) {\n\t\t\tvar key;\n\t\t\tvalidateSymbol(symbol);\n\t\t\tfor (key in registry) {\n\t\t\t\tif (registry[key] === symbol) return key;\n\t\t\t}\n\t\t\treturn undefined;\n\t\t})\n\t});\n};\n","\"use strict\";\n\nmodule.exports = require(\"./is-implemented\")() ? Array.from : require(\"./shim\");\n","\"use strict\";\n\nmodule.exports = function () {\n\tvar from = Array.from, arr, result;\n\tif (typeof from !== \"function\") return false;\n\tarr = [\"raz\", \"dwa\"];\n\tresult = from(arr);\n\treturn Boolean(result && result !== arr && result[1] === \"dwa\");\n};\n","\"use strict\";\n\nvar iteratorSymbol = require(\"es6-symbol\").iterator\n , isArguments = require(\"../../function/is-arguments\")\n , isFunction = require(\"../../function/is-function\")\n , toPosInt = require(\"../../number/to-pos-integer\")\n , callable = require(\"../../object/valid-callable\")\n , validValue = require(\"../../object/valid-value\")\n , isValue = require(\"../../object/is-value\")\n , isString = require(\"../../string/is-string\")\n , isArray = Array.isArray\n , call = Function.prototype.call\n , desc = { configurable: true, enumerable: true, writable: true, value: null }\n , defineProperty = Object.defineProperty;\n\n// eslint-disable-next-line complexity, max-lines-per-function\nmodule.exports = function (arrayLike /*, mapFn, thisArg*/) {\n\tvar mapFn = arguments[1]\n\t , thisArg = arguments[2]\n\t , Context\n\t , i\n\t , j\n\t , arr\n\t , length\n\t , code\n\t , iterator\n\t , result\n\t , getIterator\n\t , value;\n\n\tarrayLike = Object(validValue(arrayLike));\n\n\tif (isValue(mapFn)) callable(mapFn);\n\tif (!this || this === Array || !isFunction(this)) {\n\t\t// Result: Plain array\n\t\tif (!mapFn) {\n\t\t\tif (isArguments(arrayLike)) {\n\t\t\t\t// Source: Arguments\n\t\t\t\tlength = arrayLike.length;\n\t\t\t\tif (length !== 1) return Array.apply(null, arrayLike);\n\t\t\t\tarr = new Array(1);\n\t\t\t\tarr[0] = arrayLike[0];\n\t\t\t\treturn arr;\n\t\t\t}\n\t\t\tif (isArray(arrayLike)) {\n\t\t\t\t// Source: Array\n\t\t\t\tarr = new Array((length = arrayLike.length));\n\t\t\t\tfor (i = 0; i < length; ++i) arr[i] = arrayLike[i];\n\t\t\t\treturn arr;\n\t\t\t}\n\t\t}\n\t\tarr = [];\n\t} else {\n\t\t// Result: Non plain array\n\t\tContext = this;\n\t}\n\n\tif (!isArray(arrayLike)) {\n\t\tif ((getIterator = arrayLike[iteratorSymbol]) !== undefined) {\n\t\t\t// Source: Iterator\n\t\t\titerator = callable(getIterator).call(arrayLike);\n\t\t\tif (Context) arr = new Context();\n\t\t\tresult = iterator.next();\n\t\t\ti = 0;\n\t\t\twhile (!result.done) {\n\t\t\t\tvalue = mapFn ? call.call(mapFn, thisArg, result.value, i) : result.value;\n\t\t\t\tif (Context) {\n\t\t\t\t\tdesc.value = value;\n\t\t\t\t\tdefineProperty(arr, i, desc);\n\t\t\t\t} else {\n\t\t\t\t\tarr[i] = value;\n\t\t\t\t}\n\t\t\t\tresult = iterator.next();\n\t\t\t\t++i;\n\t\t\t}\n\t\t\tlength = i;\n\t\t} else if (isString(arrayLike)) {\n\t\t\t// Source: String\n\t\t\tlength = arrayLike.length;\n\t\t\tif (Context) arr = new Context();\n\t\t\tfor (i = 0, j = 0; i < length; ++i) {\n\t\t\t\tvalue = arrayLike[i];\n\t\t\t\tif (i + 1 < length) {\n\t\t\t\t\tcode = value.charCodeAt(0);\n\t\t\t\t\t// eslint-disable-next-line max-depth\n\t\t\t\t\tif (code >= 0xd800 && code <= 0xdbff) value += arrayLike[++i];\n\t\t\t\t}\n\t\t\t\tvalue = mapFn ? call.call(mapFn, thisArg, value, j) : value;\n\t\t\t\tif (Context) {\n\t\t\t\t\tdesc.value = value;\n\t\t\t\t\tdefineProperty(arr, j, desc);\n\t\t\t\t} else {\n\t\t\t\t\tarr[j] = value;\n\t\t\t\t}\n\t\t\t\t++j;\n\t\t\t}\n\t\t\tlength = j;\n\t\t}\n\t}\n\tif (length === undefined) {\n\t\t// Source: array or array-like\n\t\tlength = toPosInt(arrayLike.length);\n\t\tif (Context) arr = new Context(length);\n\t\tfor (i = 0; i < length; ++i) {\n\t\t\tvalue = mapFn ? call.call(mapFn, thisArg, arrayLike[i], i) : arrayLike[i];\n\t\t\tif (Context) {\n\t\t\t\tdesc.value = value;\n\t\t\t\tdefineProperty(arr, i, desc);\n\t\t\t} else {\n\t\t\t\tarr[i] = value;\n\t\t\t}\n\t\t}\n\t}\n\tif (Context) {\n\t\tdesc.value = null;\n\t\tarr.length = length;\n\t}\n\treturn arr;\n};\n","\"use strict\";\n\nvar objToString = Object.prototype.toString\n , id = objToString.call((function () { return arguments; })());\n\nmodule.exports = function (value) { return objToString.call(value) === id; };\n","\"use strict\";\n\nvar objToString = Object.prototype.toString\n , isFunctionStringTag = RegExp.prototype.test.bind(/^[object [A-Za-z0-9]*Function]$/);\n\nmodule.exports = function (value) {\n\treturn typeof value === \"function\" && isFunctionStringTag(objToString.call(value));\n};\n","\"use strict\";\n\nvar objToString = Object.prototype.toString, id = objToString.call(\"\");\n\nmodule.exports = function (value) {\n\treturn (\n\t\ttypeof value === \"string\" ||\n\t\t(value &&\n\t\t\ttypeof value === \"object\" &&\n\t\t\t(value instanceof String || objToString.call(value) === id)) ||\n\t\tfalse\n\t);\n};\n","\"use strict\";\n\nvar numberIsNaN = require(\"../../number/is-nan\")\n , toPosInt = require(\"../../number/to-pos-integer\")\n , value = require(\"../../object/valid-value\")\n , indexOf = Array.prototype.indexOf\n , objHasOwnProperty = Object.prototype.hasOwnProperty\n , abs = Math.abs\n , floor = Math.floor;\n\nmodule.exports = function (searchElement /*, fromIndex*/) {\n\tvar i, length, fromIndex, val;\n\tif (!numberIsNaN(searchElement)) return indexOf.apply(this, arguments);\n\n\tlength = toPosInt(value(this).length);\n\tfromIndex = arguments[1];\n\tif (isNaN(fromIndex)) fromIndex = 0;\n\telse if (fromIndex >= 0) fromIndex = floor(fromIndex);\n\telse fromIndex = toPosInt(this.length) - floor(abs(fromIndex));\n\n\tfor (i = fromIndex; i < length; ++i) {\n\t\tif (objHasOwnProperty.call(this, i)) {\n\t\t\tval = this[i];\n\t\t\tif (numberIsNaN(val)) return i; // Jslint: ignore\n\t\t}\n\t}\n\treturn -1;\n};\n","\"use strict\";\n\nmodule.exports = require(\"./is-implemented\")() ? Number.isNaN : require(\"./shim\");\n","\"use strict\";\n\nmodule.exports = function () {\n\tvar numberIsNaN = Number.isNaN;\n\tif (typeof numberIsNaN !== \"function\") return false;\n\treturn !numberIsNaN({}) && numberIsNaN(NaN) && !numberIsNaN(34);\n};\n","\"use strict\";\n\nmodule.exports = function (value) {\n\t// eslint-disable-next-line no-self-compare\n\treturn value !== value;\n};\n","\"use strict\";\n\nvar callable = require(\"./valid-callable\")\n , forEach = require(\"./for-each\")\n , call = Function.prototype.call;\n\nmodule.exports = function (obj, cb /*, thisArg*/) {\n\tvar result = {}, thisArg = arguments[2];\n\tcallable(cb);\n\tforEach(obj, function (value, key, targetObj, index) {\n\t\tresult[key] = call.call(cb, thisArg, value, key, targetObj, index);\n\t});\n\treturn result;\n};\n","'use strict';\n\nvar ensureCallable = function (fn) {\n\tif (typeof fn !== 'function') throw new TypeError(fn + \" is not a function\");\n\treturn fn;\n};\n\nvar byObserver = function (Observer) {\n\tvar node = document.createTextNode(''), queue, currentQueue, i = 0;\n\tnew Observer(function () {\n\t\tvar callback;\n\t\tif (!queue) {\n\t\t\tif (!currentQueue) return;\n\t\t\tqueue = currentQueue;\n\t\t} else if (currentQueue) {\n\t\t\tqueue = currentQueue.concat(queue);\n\t\t}\n\t\tcurrentQueue = queue;\n\t\tqueue = null;\n\t\tif (typeof currentQueue === 'function') {\n\t\t\tcallback = currentQueue;\n\t\t\tcurrentQueue = null;\n\t\t\tcallback();\n\t\t\treturn;\n\t\t}\n\t\tnode.data = (i = ++i % 2); // Invoke other batch, to handle leftover callbacks in case of crash\n\t\twhile (currentQueue) {\n\t\t\tcallback = currentQueue.shift();\n\t\t\tif (!currentQueue.length) currentQueue = null;\n\t\t\tcallback();\n\t\t}\n\t}).observe(node, { characterData: true });\n\treturn function (fn) {\n\t\tensureCallable(fn);\n\t\tif (queue) {\n\t\t\tif (typeof queue === 'function') queue = [queue, fn];\n\t\t\telse queue.push(fn);\n\t\t\treturn;\n\t\t}\n\t\tqueue = fn;\n\t\tnode.data = (i = ++i % 2);\n\t};\n};\n\nmodule.exports = (function () {\n\t// Node.js\n\tif ((typeof process === 'object') && process && (typeof process.nextTick === 'function')) {\n\t\treturn process.nextTick;\n\t}\n\n\t// queueMicrotask\n\tif (typeof queueMicrotask === \"function\") {\n\t\treturn function (cb) { queueMicrotask(ensureCallable(cb)); };\n\t}\n\n\t// MutationObserver\n\tif ((typeof document === 'object') && document) {\n\t\tif (typeof MutationObserver === 'function') return byObserver(MutationObserver);\n\t\tif (typeof WebKitMutationObserver === 'function') return byObserver(WebKitMutationObserver);\n\t}\n\n\t// W3C Draft\n\t// http://dvcs.w3.org/hg/webperf/raw-file/tip/specs/setImmediate/Overview.html\n\tif (typeof setImmediate === 'function') {\n\t\treturn function (cb) { setImmediate(ensureCallable(cb)); };\n\t}\n\n\t// Wide available standard\n\tif ((typeof setTimeout === 'function') || (typeof setTimeout === 'object')) {\n\t\treturn function (cb) { setTimeout(ensureCallable(cb), 0); };\n\t}\n\n\treturn null;\n}());\n","// Deprecated\n\n\"use strict\";\n\nmodule.exports = function (obj) { return typeof obj === \"function\"; };\n","module.exports = isPromise;\nmodule.exports.default = isPromise;\n\nfunction isPromise(obj) {\n return !!obj && (typeof obj === 'object' || typeof obj === 'function') && typeof obj.then === 'function';\n}\n","/* eslint max-statements: 0 */\n\n// Support for functions returning promise\n\n\"use strict\";\n\nvar objectMap = require(\"es5-ext/object/map\")\n , primitiveSet = require(\"es5-ext/object/primitive-set\")\n , ensureString = require(\"es5-ext/object/validate-stringifiable-value\")\n , toShortString = require(\"es5-ext/to-short-string-representation\")\n , isPromise = require(\"is-promise\")\n , nextTick = require(\"next-tick\");\n\nvar create = Object.create\n , supportedModes = primitiveSet(\"then\", \"then:finally\", \"done\", \"done:finally\");\n\nrequire(\"../lib/registered-extensions\").promise = function (mode, conf) {\n\tvar waiting = create(null), cache = create(null), promises = create(null);\n\n\tif (mode === true) {\n\t\tmode = null;\n\t} else {\n\t\tmode = ensureString(mode);\n\t\tif (!supportedModes[mode]) {\n\t\t\tthrow new TypeError(\"'\" + toShortString(mode) + \"' is not valid promise mode\");\n\t\t}\n\t}\n\n\t// After not from cache call\n\tconf.on(\"set\", function (id, ignore, promise) {\n\t\tvar isFailed = false;\n\n\t\tif (!isPromise(promise)) {\n\t\t\t// Non promise result\n\t\t\tcache[id] = promise;\n\t\t\tconf.emit(\"setasync\", id, 1);\n\t\t\treturn;\n\t\t}\n\t\twaiting[id] = 1;\n\t\tpromises[id] = promise;\n\t\tvar onSuccess = function (result) {\n\t\t\tvar count = waiting[id];\n\t\t\tif (isFailed) {\n\t\t\t\tthrow new Error(\n\t\t\t\t\t\"Memoizee error: Detected unordered then|done & finally resolution, which \" +\n\t\t\t\t\t\t\"in turn makes proper detection of success/failure impossible (when in \" +\n\t\t\t\t\t\t\"'done:finally' mode)\\n\" +\n\t\t\t\t\t\t\"Consider to rely on 'then' or 'done' mode instead.\"\n\t\t\t\t);\n\t\t\t}\n\t\t\tif (!count) return; // Deleted from cache before resolved\n\t\t\tdelete waiting[id];\n\t\t\tcache[id] = result;\n\t\t\tconf.emit(\"setasync\", id, count);\n\t\t};\n\t\tvar onFailure = function () {\n\t\t\tisFailed = true;\n\t\t\tif (!waiting[id]) return; // Deleted from cache (or succeed in case of finally)\n\t\t\tdelete waiting[id];\n\t\t\tdelete promises[id];\n\t\t\tconf.delete(id);\n\t\t};\n\n\t\tvar resolvedMode = mode;\n\t\tif (!resolvedMode) resolvedMode = \"then\";\n\n\t\tif (resolvedMode === \"then\") {\n\t\t\tvar nextTickFailure = function () { nextTick(onFailure); };\n\t\t\t// Eventual finally needs to be attached to non rejected promise\n\t\t\t// (so we not force propagation of unhandled rejection)\n\t\t\tpromise = promise.then(function (result) {\n\t\t\t\tnextTick(onSuccess.bind(this, result));\n\t\t\t}, nextTickFailure);\n\t\t\t// If `finally` is a function we attach to it to remove cancelled promises.\n\t\t\tif (typeof promise.finally === \"function\") {\n\t\t\t\tpromise.finally(nextTickFailure);\n\t\t\t}\n\t\t} else if (resolvedMode === \"done\") {\n\t\t\t// Not recommended, as it may mute any eventual \"Unhandled error\" events\n\t\t\tif (typeof promise.done !== \"function\") {\n\t\t\t\tthrow new Error(\n\t\t\t\t\t\"Memoizee error: Retrieved promise does not implement 'done' \" +\n\t\t\t\t\t\t\"in 'done' mode\"\n\t\t\t\t);\n\t\t\t}\n\t\t\tpromise.done(onSuccess, onFailure);\n\t\t} else if (resolvedMode === \"done:finally\") {\n\t\t\t// The only mode with no side effects assuming library does not throw unconditionally\n\t\t\t// for rejected promises.\n\t\t\tif (typeof promise.done !== \"function\") {\n\t\t\t\tthrow new Error(\n\t\t\t\t\t\"Memoizee error: Retrieved promise does not implement 'done' \" +\n\t\t\t\t\t\t\"in 'done:finally' mode\"\n\t\t\t\t);\n\t\t\t}\n\t\t\tif (typeof promise.finally !== \"function\") {\n\t\t\t\tthrow new Error(\n\t\t\t\t\t\"Memoizee error: Retrieved promise does not implement 'finally' \" +\n\t\t\t\t\t\t\"in 'done:finally' mode\"\n\t\t\t\t);\n\t\t\t}\n\t\t\tpromise.done(onSuccess);\n\t\t\tpromise.finally(onFailure);\n\t\t}\n\t});\n\n\t// From cache (sync)\n\tconf.on(\"get\", function (id, args, context) {\n\t\tvar promise;\n\t\tif (waiting[id]) {\n\t\t\t++waiting[id]; // Still waiting\n\t\t\treturn;\n\t\t}\n\t\tpromise = promises[id];\n\t\tvar emit = function () { conf.emit(\"getasync\", id, args, context); };\n\t\tif (isPromise(promise)) {\n\t\t\tif (typeof promise.done === \"function\") promise.done(emit);\n\t\t\telse {\n\t\t\t\tpromise.then(function () { nextTick(emit); });\n\t\t\t}\n\t\t} else {\n\t\t\temit();\n\t\t}\n\t});\n\n\t// On delete\n\tconf.on(\"delete\", function (id) {\n\t\tdelete promises[id];\n\t\tif (waiting[id]) {\n\t\t\tdelete waiting[id];\n\t\t\treturn; // Not yet resolved\n\t\t}\n\t\tif (!hasOwnProperty.call(cache, id)) return;\n\t\tvar result = cache[id];\n\t\tdelete cache[id];\n\t\tconf.emit(\"deleteasync\", id, [result]);\n\t});\n\n\t// On clear\n\tconf.on(\"clear\", function () {\n\t\tvar oldCache = cache;\n\t\tcache = create(null);\n\t\twaiting = create(null);\n\t\tpromises = create(null);\n\t\tconf.emit(\"clearasync\", objectMap(oldCache, function (data) { return [data]; }));\n\t});\n};\n","\"use strict\";\n\nvar forEach = Array.prototype.forEach, create = Object.create;\n\n// eslint-disable-next-line no-unused-vars\nmodule.exports = function (arg /*, …args*/) {\n\tvar set = create(null);\n\tforEach.call(arguments, function (name) { set[name] = true; });\n\treturn set;\n};\n","\"use strict\";\n\nvar ensureValue = require(\"./valid-value\")\n , stringifiable = require(\"./validate-stringifiable\");\n\nmodule.exports = function (value) { return stringifiable(ensureValue(value)); };\n","\"use strict\";\n\nvar isCallable = require(\"./is-callable\");\n\nmodule.exports = function (stringifiable) {\n\ttry {\n\t\tif (stringifiable && isCallable(stringifiable.toString)) return stringifiable.toString();\n\t\treturn String(stringifiable);\n\t} catch (e) {\n\t\tthrow new TypeError(\"Passed argument cannot be stringifed\");\n\t}\n};\n","\"use strict\";\n\nvar safeToString = require(\"./safe-to-string\");\n\nvar reNewLine = /[\\n\\r\\u2028\\u2029]/g;\n\nmodule.exports = function (value) {\n\tvar string = safeToString(value);\n\t// Trim if too long\n\tif (string.length > 100) string = string.slice(0, 99) + \"…\";\n\t// Replace eventual new lines\n\tstring = string.replace(reNewLine, function (char) {\n\t\treturn JSON.stringify(char).slice(1, -1);\n\t});\n\treturn string;\n};\n","\"use strict\";\n\nvar isCallable = require(\"./object/is-callable\");\n\nmodule.exports = function (value) {\n\ttry {\n\t\tif (value && isCallable(value.toString)) return value.toString();\n\t\treturn String(value);\n\t} catch (e) {\n\t\treturn \"<Non-coercible to string value>\";\n\t}\n};\n","import fs, {promises as fsPromises} from 'node:fs';\n\nexport async function pathExists(path) {\n\ttry {\n\t\tawait fsPromises.access(path);\n\t\treturn true;\n\t} catch {\n\t\treturn false;\n\t}\n}\n\nexport function pathExistsSync(path) {\n\ttry {\n\t\tfs.accessSync(path);\n\t\treturn true;\n\t} catch {\n\t\treturn false;\n\t}\n}\n","import { homedir } from \"os\";\nimport { join } from \"path\";\nimport { isSudo } from \"admina\";\nexport function userHomeDir() {\n if (isSudo() && typeof process.env.SUDO_USER === \"string\" && process.env.SUDO_USER !== \"\") {\n // use the user profile even if root\n if (process.platform === \"darwin\") {\n return join(\"/Users/\", process.env.SUDO_USER);\n }\n else {\n return join(\"/home/\", process.env.SUDO_USER);\n }\n }\n else {\n const maybeHomeDir = homedir();\n if (maybeHomeDir === \"\") {\n return undefined;\n }\n return maybeHomeDir;\n }\n}\nconst tildeRegex = /^~(?=$|\\/|\\\\)/;\n/**\n * Replaces a tilde with the user's home directory\n *\n * @example UntildifyUser(\"~/foo\") // /home/user/foo\n *\n * @param path The path to untildify\n * @returns The untildified path\n */\nexport function untildifyUser(path) {\n const maybeHomeDir = userHomeDir();\n if (maybeHomeDir === undefined) {\n return path;\n }\n return path.replace(tildeRegex, maybeHomeDir);\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLE9BQU8sRUFBRSxNQUFNLElBQUksQ0FBQTtBQUM1QixPQUFPLEVBQUUsSUFBSSxFQUFFLE1BQU0sTUFBTSxDQUFBO0FBQzNCLE9BQU8sRUFBRSxNQUFNLEVBQUUsTUFBTSxRQUFRLENBQUE7QUFFL0IsTUFBTSxVQUFVLFdBQVc7SUFDekIsSUFBSSxNQUFNLEVBQUUsSUFBSSxPQUFPLE9BQU8sQ0FBQyxHQUFHLENBQ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gbWF5YmVIb21lRGlyID0gdXNlckhvbWVEaXIoKVxuICBpZiAobWF5YmVIb21lRGlyID09PSB1bmRlZmluZWQpIHtcbiAgICByZXR1cm4gcGF0aFxuICB9XG5cbiAgcmV0dXJuIHBhdGgucmVwbGFjZSh0aWxkZVJlZ2V4LCBtYXliZUhvbWVEaXIpXG59XG4iXX0=","import { promises } from \"fs\";\nimport { grantUserWriteAccess } from \"admina\";\nimport { info, warning } from \"ci-log\";\nimport memoize from \"memoizee\";\nimport { pathExists } from \"path-exists\";\nimport { untildifyUser } from \"untildify-user\";\nconst { appendFile, readFile, writeFile } = promises;\nexport const defaultRcPath = untildifyUser(\"~/.bashrc\");\nasync function sourceRCInRc_(options) {\n const sourceRcString = options.guard === undefined\n ? `\\nsource \"${options.rcPath}\"\\n`\n : `\\n# ${options.guard}\\nif [[ \"$SOURCE_${options.guard.toUpperCase()}RC\" != 0 && -f \"${options.rcPath}\" ]]; then source \"${options.rcPath}\"; fi\\n`;\n try {\n await Promise.all([\n addRCHeader(options),\n addSourceToTargetRc(sourceRcString, untildifyUser(\"~/.bashrc\")),\n addSourceToTargetRc(sourceRcString, untildifyUser(\"~/.profile\")),\n ]);\n }\n catch (err) {\n warning(`Failed to add ${sourceRcString} to .profile or .bashrc. You should add it manually: ${err}`);\n }\n}\n/**\n * handles adding conditions to source rc file from .bashrc and .profile\n */\nexport const sourceRCInRc = memoize(sourceRCInRc_, { promise: true });\nasync function addRCHeader(options) {\n // a variable that prevents source rc from being called from .bashrc and .profile\n const rcHeader = options.guard === undefined\n ? \"\\n# Automatically Generated by envosman\\n\"\n : `\\n# Automatically Generated by envosman ${options.guard}\\nexport SOURCE_${options.guard.toUpperCase()}RC=0\\n`;\n if (await pathExists(options.rcPath)) {\n const rcContent = await readFile(options.rcPath, \"utf8\");\n if (!rcContent.includes(rcHeader)) {\n // already executed setupCppInProfile\n await appendFile(options.rcPath, `\\n${rcHeader}\\n`);\n info(`Added ${rcHeader} to ${options.rcPath}`);\n }\n }\n}\nasync function addSourceToTargetRc(sourceRcString, targetRcPath) {\n if (await pathExists(targetRcPath)) {\n const bashrcContent = await readFile(targetRcPath, \"utf-8\");\n if (!bashrcContent.includes(sourceRcString)) {\n await appendFile(targetRcPath, sourceRcString);\n info(`${sourceRcString} was added to ${targetRcPath}`);\n }\n }\n}\nexport async function finalizeRC(rcOptions) {\n if (await pathExists(rcOptions.rcPath)) {\n const entries = (await readFile(rcOptions.rcPath, \"utf-8\")).split(\"\\n\");\n const uniqueEntries = [...new Set(entries.reverse())].reverse(); // remove duplicates, keeping the latest entry\n await writeFile(rcOptions.rcPath, uniqueEntries.join(\"\\n\"));\n await grantUserWriteAccess(rcOptions.rcPath);\n }\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmMtZmlsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3NyYy9yYy1maWxlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxRQUFRLEVBQUUsTUFBTSxJQUFJLENBQUE7QUFDN0IsT0FBTyxFQUFFLG9CQUFvQixFQUFFLE1BQU0sUUFBUSxDQUFBO0FBQzdDLE9BQU8sRUFBRSxJQUFJLEVBQUUsT0FBTyxFQUFFLE1BQU0sUUFBUSxDQUFBO0FBQ3RDLE9BQU8sT0FBTyxNQUFNLFVBQVUsQ0FBQTtBQUM5QixPQUFPLEVBQUUsVUFBVSxFQUFFLE1BQU0sYUFBYSxDQUFBO0FBQ3hDLE9BQU8sRUFBRSxhQUFhLEVBQUUsTUFBTSxnQkFBZ0IsQ0FBQTtBQUM5QyxNQUFNLEVBQUUsVUFBVSxFQUFFLFFBQVEsRUFBRSxTQUFTLEVBQUUsR0FBRyxRQUFRLENBQUE7QUFFcEQsTUFBTSxDQUFDLE1BQU0sYUFBYSxHQUFHLGFBQWEsQ0FBQyxXQUFXLENBQUMsQ0FBQTtBQWF2RCxLQU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llcy5yZXZlcnNlKCkpXS5yZXZlcnNlKCkgLy8gcmVtb3ZlIGR1cGxpY2F0ZXMsIGtlZXBpbmcgdGhlIGxhdGVzdCBlbnRyeVxuXG4gICAgYXdhaXQgd3JpdGVGaWxlKHJjT3B0aW9ucy5yY1BhdGgsIHVuaXF1ZUVudHJpZXMuam9pbihcIlxcblwiKSlcblxuICAgIGF3YWl0IGdyYW50VXNlcldyaXRlQWNjZXNzKHJjT3B0aW9ucy5yY1BhdGgpXG4gIH1cbn1cbiJdfQ==","import { promises } from \"fs\";\nimport { exportVariable as ghExportVariable } from \"@actions/core\";\nimport ciInfo from \"ci-info\";\nconst { GITHUB_ACTIONS } = ciInfo;\nimport { error, info } from \"ci-log\";\nimport { execPowershell } from \"exec-powershell\";\nimport { defaultRcPath, sourceRCInRc } from \"./rc-file.js\";\nimport { escapeString } from \"./utils.js\";\nconst { appendFile } = promises;\n/**\n * Add an environment variable.\n *\n * This function is cross-platforms and works in all the local or CI systems.\n */\nexport async function addEnv(name, valGiven, givenOptions = {}) {\n const options = {\n escapeSpace: false,\n overwrite: true,\n rcPath: defaultRcPath,\n ...givenOptions,\n };\n const val = escapeString(valGiven ?? \"\", options.escapeSpace);\n try {\n if (GITHUB_ACTIONS) {\n try {\n if (!options.overwrite) {\n if (process.env[name] !== undefined) {\n info(`Environment variable ${name} is already defined. Skipping.`);\n return;\n }\n }\n ghExportVariable(name, val);\n }\n catch (err) {\n error(err);\n await addEnvSystem(name, val, options);\n }\n }\n else {\n await addEnvSystem(name, val, options);\n }\n }\n catch (err) {\n error(`${err}\\nFailed to export environment variable ${name}=${val}. You should add it manually.`);\n }\n}\nasync function addEnvSystem(name, valGiven, options) {\n const val = valGiven ?? \"\";\n switch (process.platform) {\n case \"win32\": {\n if (!options.overwrite) {\n if (process.env[name] !== undefined) {\n info(`Environment variable ${name} is already defined. Skipping.`);\n return;\n }\n }\n // We do not use `execaSync(`setx PATH \"${path};%PATH%\"`)` because of its character limit\n await execPowershell(`[Environment]::SetEnvironmentVariable('${name}', '${val}', \"User\")`);\n info(`${name}='${val}' was set in the environment.`);\n return;\n }\n case \"linux\":\n case \"darwin\": {\n await sourceRCInRc(options);\n if (!options.overwrite) {\n await appendFile(options.rcPath, `\\nif [ -z \"\\${${name}}\" ]; then export ${name}=\"${val}\"; fi\\n`);\n info(`if not defined ${name} then ${name}=\"${val}\" was added to \"${options.rcPath}`);\n }\n else {\n await appendFile(options.rcPath, `\\nexport ${name}=\"${val}\"\\n`);\n info(`${name}=\"${val}\" was added to \"${options.rcPath}`);\n }\n return;\n }\n default: {\n // fall through shell path modification\n }\n }\n process.env[name] = val;\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWRkLWVudi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3NyYy9hZGQtZW52LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxRQUFRLEVBQUUsTUFBTSxJQUFJLENBQUE7QUFDN0IsT0FBTyxFQUFFLGNBQWMsSUFBSSxnQkFBZ0IsRUFBRSxNQUFNLGVBQWUsQ0FBQTtBQUNsRSxPQUFPLE1BQU0sTUFBTSxTQUFTLENBQUE7QUFDNUIsTUFBTSxFQUFFLGNBQWMsRUFBRSxHQUFHLE1BQU0sQ0FBQTtBQUNqQyxPQUFPLEVBQUUsS0FBSyxFQUFFLElBQUksRUFBRSxNQUFNLFFBQVEsQ0FBQTtBQUNwQyxPQUFPLEVBQUUsY0FBYyxFQUFFLE1BQU0saUJBQWlCLENBQUE7QUFDaEQsT0FBTyxFQUFFLGFBQWEsRUFBRSxZQUFZLEVBQUUsTUFBTSxjQUFjLENBQUE7QUFDMUQsT0FBTyxFQUFFLFlBQVksRUFBRSxNQUFNLFlBQVksQ0FBQTtBQUN6QyxNQUFNLEVBQUUsVUFBVSxFQUFFLEdBQUcsUUFBUSxDQUFBO0FBaUIvQjs7OztHQUl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AgIGF3YWl0IGFwcGVuZEZpbGUob3B0aW9ucy5yY1BhdGgsIGBcXG5pZiBbIC16IFwiXFwkeyR7bmFtZX19XCIgXTsgdGhlbiBleHBvcnQgJHtuYW1lfT1cIiR7dmFsfVwiOyBmaVxcbmApXG4gICAgICAgIGluZm8oYGlmIG5vdCBkZWZpbmVkICR7bmFtZX0gdGhlbiAke25hbWV9PVwiJHt2YWx9XCIgd2FzIGFkZGVkIHRvIFwiJHtvcHRpb25zLnJjUGF0aH1gKVxuICAgICAgfSBlbHNlIHtcbiAgICAgICAgYXdhaXQgYXBwZW5kRmlsZShvcHRpb25zLnJjUGF0aCwgYFxcbmV4cG9ydCAke25hbWV9PVwiJHt2YWx9XCJcXG5gKVxuICAgICAgICBpbmZvKGAke25hbWV9PVwiJHt2YWx9XCIgd2FzIGFkZGVkIHRvIFwiJHtvcHRpb25zLnJjUGF0aH1gKVxuICAgICAgfVxuICAgICAgcmV0dXJuXG4gICAgfVxuICAgIGRlZmF1bHQ6IHtcbiAgICAgIC8vIGZhbGwgdGhyb3VnaCBzaGVsbCBwYXRoIG1vZGlmaWNhdGlvblxuICAgIH1cbiAgfVxuICBwcm9jZXNzLmVudltuYW1lXSA9IHZhbFxufVxuIl19","import escapeSpace from \"escape-path-with-spaces\";\nimport escapeQuote from \"escape-quotes\";\n/**\n * Escape a string for use in a shell command\n * @param valGiven The string to escape\n * @param shouldEscapeSpace Whether to escape spaces in the string\n *\n * @private\n */\nexport function escapeString(valGiven, shouldEscapeSpace = false) {\n const spaceEscaped = shouldEscapeSpace ? escapeSpace(valGiven) : valGiven;\n return escapeQuote(spaceEscaped, \"\\\"\", \"\\\\\");\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidXRpbHMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvdXRpbHMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxXQUFXLE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ises } from \"fs\";\nimport { delimiter } from \"path\";\nimport { addPath as ghAddPath } from \"@actions/core\";\nimport ciInfo from \"ci-info\";\nconst { GITHUB_ACTIONS } = ciInfo;\nimport { error, info } from \"ci-log\";\nimport { execPowershell } from \"exec-powershell\";\nimport { defaultRcPath, sourceRCInRc } from \"./rc-file.js\";\nconst { appendFile } = promises;\n/**\n * Add a path to the PATH environment variable.\n *\n * This function is cross-platforms and works in all the local or CI systems.\n */\nexport async function addPath(path, givenOptions = {}) {\n const options = { rcPath: defaultRcPath, ...givenOptions };\n if (isIgnoredPath(path)) {\n return;\n }\n process.env.PATH = `${path}${delimiter}${process.env.PATH}`;\n try {\n if (GITHUB_ACTIONS) {\n try {\n ghAddPath(path);\n }\n catch (err) {\n error(err);\n await addPathSystem(path, options);\n }\n }\n else {\n await addPathSystem(path, options);\n }\n }\n catch (err) {\n error(`${err}\\nFailed to add ${path} to the percistent PATH. You should add it manually.`);\n }\n}\nasync function addPathSystem(path, options) {\n switch (process.platform) {\n case \"win32\": {\n // We do not use `execaSync(`setx PATH \"${path};%PATH%\"`)` because of its character limit and also because %PATH% is different for user and system\n await execPowershell(`$USER_PATH=([Environment]::GetEnvironmentVariable(\"PATH\", \"User\")); [Environment]::SetEnvironmentVariable(\"PATH\", \"${path};$USER_PATH\", \"User\")`);\n info(`\"${path}\" was added to the PATH.`);\n return;\n }\n case \"linux\":\n case \"darwin\": {\n await sourceRCInRc(options);\n await appendFile(options.rcPath, `\\nexport PATH=\"${path}:$PATH\"\\n`);\n info(`\"${path}\" was added to \"${options.rcPath}\"`);\n return;\n }\n default: {\n return;\n }\n }\n}\nconst ignoredPaths = [/\\/usr\\/bin\\/?/, /\\/usr\\/local\\/bin\\/?/];\n/** Skip adding /usr/bin to PATH if it is already there */\nfunction isIgnoredPath(path) {\n if (ignoredPaths.some((checkedPath) => checkedPath.test(path))) {\n const paths = process.env.PATH?.split(delimiter) ?? [];\n return paths.includes(path);\n }\n return false;\n}\n//# sourceMappingURL=data:application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YWxzZVxufVxuIl19","\n//==============//\n// DEPENDENCIES //\n//==============//\n\nconst numerous = require('numerous');\nconst isNode = require('is-node');\n\n\n//================//\n// MODULE GLOBALS //\n//================//\n\n/**\n * Pre-calculating millisecond values for each time unit.\n */\nconst timeUnits = [\n ['years', 12 * 4 * 7 * 24 * 60 * 60 * 1000],\n ['months', 4 * 7 * 24 * 60 * 60 * 1000],\n ['weeks', 7 * 24 * 60 * 60 * 1000],\n ['days', 24 * 60 * 60 * 1000],\n ['hours', 60 * 60 * 1000],\n ['minutes', 60 * 1000],\n ['seconds', 1000],\n];\n\nconst defaultConfig = {\n locale: 'en',\n span: 2,\n delimiter: ', ',\n unitType: 'long',\n unitTypeLookupOrder: ['long', 'short', 'narrow'],\n autoloadLocales: true,\n};\n\n/**\n * Contains data of loaded locales.\n * @type {Object}\n */\nconst locales = {};\n\n\n//=========//\n// EXPORTS //\n//=========//\n\nmodule.exports = {\n create: timeDeltaFactory,\n addLocale,\n defaultConfig,\n};\n\n\n//===========//\n// FUNCTIONS //\n//===========//\n\n/**\n * Adds pluralization data for the specified locale.\n * Should be called in browser.\n *\n * @param {Object|Object[]} localeData\n */\nfunction addLocale(localeData) {\n\n // Normalizing input\n if (!Array.isArray(localeData)) {\n localeData = [localeData];\n }\n\n for (const item of localeData) {\n const { id, data } = item;\n locales[id] = data;\n }\n\n}\n\n\n/**\n * Creates new instance.\n *\n * @param {object?} config\n *\n * @returns {object}\n */\nfunction timeDeltaFactory(config) {\n\n // Initializing config by extending the default one\n config = Object.assign({}, defaultConfig, config || {});\n\n return {\n\n /**\n * Public proxy for internal format function.\n *\n * @param {Date} firstDate\n * @param {Date} secondDate\n * @param {object?} options\n *\n * @returns {string}\n */\n format: function (firstDate, secondDate, options) {\n\n // Allowing to override config with each individual call\n options = Object.assign({}, config, options || {});\n\n return format(firstDate, secondDate, options);\n\n }\n\n };\n\n}\n\n\n/**\n * Returns difference between two dates as a text string.\n *\n * @param {Date} firstDate\n * @param {Date} secondDate\n * @param {object} config\n *\n * @returns {string}\n */\nfunction format(firstDate, secondDate, config) {\n\n ensureLocaleLoadedOrThrow(config.locale, {\n autoload: config.autoloadLocales,\n });\n\n // Handling input arguments\n // -----\n\n if (!firstDate) {\n throw new Error('Missing first date argument');\n }\n\n if (!secondDate) {\n throw new Error('Missing second date argument');\n }\n\n // Calculating\n // -----\n\n const difference = getDifference(firstDate, secondDate);\n const parts = [];\n\n for (const unit of difference) {\n const [name, value] = unit;\n if (value > 0) {\n parts.push(pluralize(name, value, config));\n }\n if (parts.length >= config.span) {\n break;\n }\n }\n\n // Returning the string value\n return parts.join(config.delimiter);\n\n}\n\n\n/**\n * Checks if locale is loaded. If not, tries to load it in Node.js,\n * or throws and error in Browser.\n *\n * @param {string} locale\n * @param {Object?} options\n */\nfunction ensureLocaleLoadedOrThrow(locale, options) {\n\n const { autoload } = options;\n\n if (hasLocale(locale)) {\n return;\n }\n\n if (isNode && autoload) {\n requireLocale(locale);\n\n } else {\n throw new Error(\n `Missing locale: ${locale}, you must load it manually before using it`\n );\n }\n\n}\n\n\n/**\n * Returns true if specified locale is loaded, false otherwise.\n *\n * @param {string} localeId\n *\n * @returns {boolean}\n */\nfunction hasLocale(localeId) {\n return Boolean(locales[localeId]);\n}\n\n/**\n * Tries to load the specified locale.\n *\n * @param {string} localeId\n */\nfunction requireLocale(localeId) {\n try {\n addLocale(\n require(`../locales/${localeId}.js`)\n );\n\n } catch (error) {\n throw Error(\n `Failed to load locale: ${localeId} from ../locales/${localeId}.js. If using a bundled time-delta, set 'autoloadLocales: false' in the config: ${error}`\n );\n\n }\n}\n\n\n/**\n * Returns difference as separate time units.\n *\n * @param {Date} firstDate\n * @param {Date} secondDate\n *\n * @returns {Array}\n */\nfunction getDifference(firstDate, secondDate) {\n let difference = (secondDate - firstDate);\n const results = [];\n timeUnits.some(function (unit) {\n const name = unit[0];\n const divider = unit[1];\n const value = Math.floor(difference / divider);\n difference -= value * divider;\n results.push([name, value]);\n if (difference <= 0) {\n // Breaking the loop.\n return true;\n }\n });\n return results;\n}\n\n/**\n * Returns localized and pluralized time unit.\n *\n * @param {string} unit\n * @param {int} value\n * @param {object} config\n *\n * @returns {string}\n */\nfunction pluralize(unit, value, config) {\n const unitTypeData = getLocaleDataForUnitType(config);\n const unitString = numerous.pluralize(\n config.locale,\n value,\n unitTypeData[unit]\n );\n return unitString.replace('{0}', value);\n}\n\n\n/**\n * Returns locale data for preferred unit type.\n *\n * @param {object} config\n *\n * @returns {Array}\n */\nfunction getLocaleDataForUnitType(config) {\n\n const localeData = locales[config.locale];\n\n // Making a copy of array from config.\n let lookupOrder = config.unitTypeLookupOrder.slice();\n\n // Adding interested type to the top.\n lookupOrder.unshift(config.unitType);\n\n // Making sure only unique items are present.\n lookupOrder = arrayUnique(lookupOrder);\n\n let unitTypeData = null;\n lookupOrder.some(function (unitType) {\n if ('undefined' !== typeof localeData[unitType]) {\n unitTypeData = localeData[unitType];\n // Breaking the loop.\n return true;\n }\n });\n\n if (null === unitTypeData) {\n throw new Error('Can not find any unit type data for locale: ' + config.locale);\n }\n\n return unitTypeData;\n}\n\n/**\n * Returns array with only unique items.\n *\n * @param {Array} array\n *\n * @returns {Array}\n */\nfunction arrayUnique(array) {\n return Array.from(\n new Set(array)\n );\n}\n","const SPACE_CHARACTERS = /\\s+/g\n\n// hoisted class for cyclic dependency\nclass Range {\n constructor (range, options) {\n options = parseOptions(options)\n\n if (range instanceof Range) {\n if (\n range.loose === !!options.loose &&\n range.includePrerelease === !!options.includePrerelease\n ) {\n return range\n } else {\n return new Range(range.raw, options)\n }\n }\n\n if (range instanceof Comparator) {\n // just put it in the set and return\n this.raw = range.value\n this.set = [[range]]\n this.formatted = undefined\n return this\n }\n\n this.options = options\n this.loose = !!options.loose\n this.includePrerelease = !!options.includePrerelease\n\n // First reduce all whitespace as much as possible so we do not have to rely\n // on potentially slow regexes like \\s*. This is then stored and used for\n // future error messages as well.\n this.raw = range.trim().replace(SPACE_CHARACTERS, ' ')\n\n // First, split on ||\n this.set = this.raw\n .split('||')\n // map the range to a 2d array of comparators\n .map(r => this.parseRange(r.trim()))\n // throw out any comparator lists that are empty\n // this generally means that it was not a valid range, which is allowed\n // in loose mode, but will still throw if the WHOLE range is invalid.\n .filter(c => c.length)\n\n if (!this.set.length) {\n throw new TypeError(`Invalid SemVer Range: ${this.raw}`)\n }\n\n // if we have any that are not the null set, throw out null sets.\n if (this.set.length > 1) {\n // keep the first one, in case they're all null sets\n const first = this.set[0]\n this.set = this.set.filter(c => !isNullSet(c[0]))\n if (this.set.length === 0) {\n this.set = [first]\n } else if (this.set.length > 1) {\n // if we have any that are *, then the range is just *\n for (const c of this.set) {\n if (c.length === 1 && isAny(c[0])) {\n this.set = [c]\n break\n }\n }\n }\n }\n\n this.formatted = undefined\n }\n\n get range () {\n if (this.formatted === undefined) {\n this.formatted = ''\n for (let i = 0; i < this.set.length; i++) {\n if (i > 0) {\n this.formatted += '||'\n }\n const comps = this.set[i]\n for (let k = 0; k < comps.length; k++) {\n if (k > 0) {\n this.formatted += ' '\n }\n this.formatted += comps[k].toString().trim()\n }\n }\n }\n return this.formatted\n }\n\n format () {\n return this.range\n }\n\n toString () {\n return this.range\n }\n\n parseRange (range) {\n // memoize range parsing for performance.\n // this is a very hot path, and fully deterministic.\n const memoOpts =\n (this.options.includePrerelease && FLAG_INCLUDE_PRERELEASE) |\n (this.options.loose && FLAG_LOOSE)\n const memoKey = memoOpts + ':' + range\n const cached = cache.get(memoKey)\n if (cached) {\n return cached\n }\n\n const loose = this.options.loose\n // `1.2.3 - 1.2.4` => `>=1.2.3 <=1.2.4`\n const hr = loose ? re[t.HYPHENRANGELOOSE] : re[t.HYPHENRANGE]\n range = range.replace(hr, hyphenReplace(this.options.includePrerelease))\n debug('hyphen replace', range)\n\n // `> 1.2.3 < 1.2.5` => `>1.2.3 <1.2.5`\n range = range.replace(re[t.COMPARATORTRIM], comparatorTrimReplace)\n debug('comparator trim', range)\n\n // `~ 1.2.3` => `~1.2.3`\n range = range.replace(re[t.TILDETRIM], tildeTrimReplace)\n debug('tilde trim', range)\n\n // `^ 1.2.3` => `^1.2.3`\n range = range.replace(re[t.CARETTRIM], caretTrimReplace)\n debug('caret trim', range)\n\n // At this point, the range is completely trimmed and\n // ready to be split into comparators.\n\n let rangeList = range\n .split(' ')\n .map(comp => parseComparator(comp, this.options))\n .join(' ')\n .split(/\\s+/)\n // >=0.0.0 is equivalent to *\n .map(comp => replaceGTE0(comp, this.options))\n\n if (loose) {\n // in loose mode, throw out any that are not valid comparators\n rangeList = rangeList.filter(comp => {\n debug('loose invalid filter', comp, this.options)\n return !!comp.match(re[t.COMPARATORLOOSE])\n })\n }\n debug('range list', rangeList)\n\n // if any comparators are the null set, then replace with JUST null set\n // if more than one comparator, remove any * comparators\n // also, don't include the same comparator more than once\n const rangeMap = new Map()\n const comparators = rangeList.map(comp => new Comparator(comp, this.options))\n for (const comp of comparators) {\n if (isNullSet(comp)) {\n return [comp]\n }\n rangeMap.set(comp.value, comp)\n }\n if (rangeMap.size > 1 && rangeMap.has('')) {\n rangeMap.delete('')\n }\n\n const result = [...rangeMap.values()]\n cache.set(memoKey, result)\n return result\n }\n\n intersects (range, options) {\n if (!(range instanceof Range)) {\n throw new TypeError('a Range is required')\n }\n\n return this.set.some((thisComparators) => {\n return (\n isSatisfiable(thisComparators, options) &&\n range.set.some((rangeComparators) => {\n return (\n isSatisfiable(rangeComparators, options) &&\n thisComparators.every((thisComparator) => {\n return rangeComparators.every((rangeComparator) => {\n return thisComparator.intersects(rangeComparator, options)\n })\n })\n )\n })\n )\n })\n }\n\n // if ANY of the sets match ALL of its comparators, then pass\n test (version) {\n if (!version) {\n return false\n }\n\n if (typeof version === 'string') {\n try {\n version = new SemVer(version, this.options)\n } catch (er) {\n return false\n }\n }\n\n for (let i = 0; i < this.set.length; i++) {\n if (testSet(this.set[i], version, this.options)) {\n return true\n }\n }\n return false\n }\n}\n\nmodule.exports = Range\n\nconst LRU = require('../internal/lrucache')\nconst cache = new LRU()\n\nconst parseOptions = require('../internal/parse-options')\nconst Comparator = require('./comparator')\nconst debug = require('../internal/debug')\nconst SemVer = require('./semver')\nconst {\n safeRe: re,\n t,\n comparatorTrimReplace,\n tildeTrimReplace,\n caretTrimReplace,\n} = require('../internal/re')\nconst { FLAG_INCLUDE_PRERELEASE, FLAG_LOOSE } = require('../internal/constants')\n\nconst isNullSet = c => c.value === '<0.0.0-0'\nconst isAny = c => c.value === ''\n\n// take a set of comparators and determine whether there\n// exists a version which can satisfy it\nconst isSatisfiable = (comparators, options) => {\n let result = true\n const remainingComparators = comparators.slice()\n let testComparator = remainingComparators.pop()\n\n while (result && remainingComparators.length) {\n result = remainingComparators.every((otherComparator) => {\n return testComparator.intersects(otherComparator, options)\n })\n\n testComparator = remainingComparators.pop()\n }\n\n return result\n}\n\n// comprised of xranges, tildes, stars, and gtlt's at this point.\n// already replaced the hyphen ranges\n// turn into a set of JUST comparators.\nconst parseComparator = (comp, options) => {\n debug('comp', comp, options)\n comp = replaceCarets(comp, options)\n debug('caret', comp)\n comp = replaceTildes(comp, options)\n debug('tildes', comp)\n comp = replaceXRanges(comp, options)\n debug('xrange', comp)\n comp = replaceStars(comp, options)\n debug('stars', comp)\n return comp\n}\n\nconst isX = id => !id || id.toLowerCase() === 'x' || id === '*'\n\n// ~, ~> --> * (any, kinda silly)\n// ~2, ~2.x, ~2.x.x, ~>2, ~>2.x ~>2.x.x --> >=2.0.0 <3.0.0-0\n// ~2.0, ~2.0.x, ~>2.0, ~>2.0.x --> >=2.0.0 <2.1.0-0\n// ~1.2, ~1.2.x, ~>1.2, ~>1.2.x --> >=1.2.0 <1.3.0-0\n// ~1.2.3, ~>1.2.3 --> >=1.2.3 <1.3.0-0\n// ~1.2.0, ~>1.2.0 --> >=1.2.0 <1.3.0-0\n// ~0.0.1 --> >=0.0.1 <0.1.0-0\nconst replaceTildes = (comp, options) => {\n return comp\n .trim()\n .split(/\\s+/)\n .map((c) => replaceTilde(c, options))\n .join(' ')\n}\n\nconst replaceTilde = (comp, options) => {\n const r = options.loose ? re[t.TILDELOOSE] : re[t.TILDE]\n return comp.replace(r, (_, M, m, p, pr) => {\n debug('tilde', comp, _, M, m, p, pr)\n let ret\n\n if (isX(M)) {\n ret = ''\n } else if (isX(m)) {\n ret = `>=${M}.0.0 <${+M + 1}.0.0-0`\n } else if (isX(p)) {\n // ~1.2 == >=1.2.0 <1.3.0-0\n ret = `>=${M}.${m}.0 <${M}.${+m + 1}.0-0`\n } else if (pr) {\n debug('replaceTilde pr', pr)\n ret = `>=${M}.${m}.${p}-${pr\n } <${M}.${+m + 1}.0-0`\n } else {\n // ~1.2.3 == >=1.2.3 <1.3.0-0\n ret = `>=${M}.${m}.${p\n } <${M}.${+m + 1}.0-0`\n }\n\n debug('tilde return', ret)\n return ret\n })\n}\n\n// ^ --> * (any, kinda silly)\n// ^2, ^2.x, ^2.x.x --> >=2.0.0 <3.0.0-0\n// ^2.0, ^2.0.x --> >=2.0.0 <3.0.0-0\n// ^1.2, ^1.2.x --> >=1.2.0 <2.0.0-0\n// ^1.2.3 --> >=1.2.3 <2.0.0-0\n// ^1.2.0 --> >=1.2.0 <2.0.0-0\n// ^0.0.1 --> >=0.0.1 <0.0.2-0\n// ^0.1.0 --> >=0.1.0 <0.2.0-0\nconst replaceCarets = (comp, options) => {\n return comp\n .trim()\n .split(/\\s+/)\n .map((c) => replaceCaret(c, options))\n .join(' ')\n}\n\nconst replaceCaret = (comp, options) => {\n debug('caret', comp, options)\n const r = options.loose ? re[t.CARETLOOSE] : re[t.CARET]\n const z = options.includePrerelease ? '-0' : ''\n return comp.replace(r, (_, M, m, p, pr) => {\n debug('caret', comp, _, M, m, p, pr)\n let ret\n\n if (isX(M)) {\n ret = ''\n } else if (isX(m)) {\n ret = `>=${M}.0.0${z} <${+M + 1}.0.0-0`\n } else if (isX(p)) {\n if (M === '0') {\n ret = `>=${M}.${m}.0${z} <${M}.${+m + 1}.0-0`\n } else {\n ret = `>=${M}.${m}.0${z} <${+M + 1}.0.0-0`\n }\n } else if (pr) {\n debug('replaceCaret pr', pr)\n if (M === '0') {\n if (m === '0') {\n ret = `>=${M}.${m}.${p}-${pr\n } <${M}.${m}.${+p + 1}-0`\n } else {\n ret = `>=${M}.${m}.${p}-${pr\n } <${M}.${+m + 1}.0-0`\n }\n } else {\n ret = `>=${M}.${m}.${p}-${pr\n } <${+M + 1}.0.0-0`\n }\n } else {\n debug('no pr')\n if (M === '0') {\n if (m === '0') {\n ret = `>=${M}.${m}.${p\n }${z} <${M}.${m}.${+p + 1}-0`\n } else {\n ret = `>=${M}.${m}.${p\n }${z} <${M}.${+m + 1}.0-0`\n }\n } else {\n ret = `>=${M}.${m}.${p\n } <${+M + 1}.0.0-0`\n }\n }\n\n debug('caret return', ret)\n return ret\n })\n}\n\nconst replaceXRanges = (comp, options) => {\n debug('replaceXRanges', comp, options)\n return comp\n .split(/\\s+/)\n .map((c) => replaceXRange(c, options))\n .join(' ')\n}\n\nconst replaceXRange = (comp, options) => {\n comp = comp.trim()\n const r = options.loose ? re[t.XRANGELOOSE] : re[t.XRANGE]\n return comp.replace(r, (ret, gtlt, M, m, p, pr) => {\n debug('xRange', comp, ret, gtlt, M, m, p, pr)\n const xM = isX(M)\n const xm = xM || isX(m)\n const xp = xm || isX(p)\n const anyX = xp\n\n if (gtlt === '=' && anyX) {\n gtlt = ''\n }\n\n // if we're including prereleases in the match, then we need\n // to fix this to -0, the lowest possible prerelease value\n pr = options.includePrerelease ? '-0' : ''\n\n if (xM) {\n if (gtlt === '>' || gtlt === '<') {\n // nothing is allowed\n ret = '<0.0.0-0'\n } else {\n // nothing is forbidden\n ret = '*'\n }\n } else if (gtlt && anyX) {\n // we know patch is an x, because we have any x at all.\n // replace X with 0\n if (xm) {\n m = 0\n }\n p = 0\n\n if (gtlt === '>') {\n // >1 => >=2.0.0\n // >1.2 => >=1.3.0\n gtlt = '>='\n if (xm) {\n M = +M + 1\n m = 0\n p = 0\n } else {\n m = +m + 1\n p = 0\n }\n } else if (gtlt === '<=') {\n // <=0.7.x is actually <0.8.0, since any 0.7.x should\n // pass. Similarly, <=7.x is actually <8.0.0, etc.\n gtlt = '<'\n if (xm) {\n M = +M + 1\n } else {\n m = +m + 1\n }\n }\n\n if (gtlt === '<') {\n pr = '-0'\n }\n\n ret = `${gtlt + M}.${m}.${p}${pr}`\n } else if (xm) {\n ret = `>=${M}.0.0${pr} <${+M + 1}.0.0-0`\n } else if (xp) {\n ret = `>=${M}.${m}.0${pr\n } <${M}.${+m + 1}.0-0`\n }\n\n debug('xRange return', ret)\n\n return ret\n })\n}\n\n// Because * is AND-ed with everything else in the comparator,\n// and '' means \"any version\", just remove the *s entirely.\nconst replaceStars = (comp, options) => {\n debug('replaceStars', comp, options)\n // Looseness is ignored here. star is always as loose as it gets!\n return comp\n .trim()\n .replace(re[t.STAR], '')\n}\n\nconst replaceGTE0 = (comp, options) => {\n debug('replaceGTE0', comp, options)\n return comp\n .trim()\n .replace(re[options.includePrerelease ? t.GTE0PRE : t.GTE0], '')\n}\n\n// This function is passed to string.replace(re[t.HYPHENRANGE])\n// M, m, patch, prerelease, build\n// 1.2 - 3.4.5 => >=1.2.0 <=3.4.5\n// 1.2.3 - 3.4 => >=1.2.0 <3.5.0-0 Any 3.4.x will do\n// 1.2 - 3.4 => >=1.2.0 <3.5.0-0\n// TODO build?\nconst hyphenReplace = incPr => ($0,\n from, fM, fm, fp, fpr, fb,\n to, tM, tm, tp, tpr) => {\n if (isX(fM)) {\n from = ''\n } else if (isX(fm)) {\n from = `>=${fM}.0.0${incPr ? '-0' : ''}`\n } else if (isX(fp)) {\n from = `>=${fM}.${fm}.0${incPr ? '-0' : ''}`\n } else if (fpr) {\n from = `>=${from}`\n } else {\n from = `>=${from}${incPr ? '-0' : ''}`\n }\n\n if (isX(tM)) {\n to = ''\n } else if (isX(tm)) {\n to = `<${+tM + 1}.0.0-0`\n } else if (isX(tp)) {\n to = `<${tM}.${+tm + 1}.0-0`\n } else if (tpr) {\n to = `<=${tM}.${tm}.${tp}-${tpr}`\n } else if (incPr) {\n to = `<${tM}.${tm}.${+tp + 1}-0`\n } else {\n to = `<=${to}`\n }\n\n return `${from} ${to}`.trim()\n}\n\nconst testSet = (set, version, options) => {\n for (let i = 0; i < set.length; i++) {\n if (!set[i].test(version)) {\n return false\n }\n }\n\n if (version.prerelease.length && !options.includePrerelease) {\n // Find the set of versions that are allowed to have prereleases\n // For example, ^1.2.3-pr.1 desugars to >=1.2.3-pr.1 <2.0.0\n // That should allow `1.2.3-pr.2` to pass.\n // However, `1.2.4-alpha.notready` should NOT be allowed,\n // even though it's within the range set by the comparators.\n for (let i = 0; i < set.length; i++) {\n debug(set[i].semver)\n if (set[i].semver === Comparator.ANY) {\n continue\n }\n\n if (set[i].semver.prerelease.length > 0) {\n const allowed = set[i].semver\n if (allowed.major === version.major &&\n allowed.minor === version.minor &&\n allowed.patch === version.patch) {\n return true\n }\n }\n }\n\n // Version has a -pre, but it's not one of the ones we like.\n return false\n }\n\n return true\n}\n","const ANY = Symbol('SemVer ANY')\n// hoisted class for cyclic dependency\nclass Comparator {\n static get ANY () {\n return ANY\n }\n\n constructor (comp, options) {\n options = parseOptions(options)\n\n if (comp instanceof Comparator) {\n if (comp.loose === !!options.loose) {\n return comp\n } else {\n comp = comp.value\n }\n }\n\n comp = comp.trim().split(/\\s+/).join(' ')\n debug('comparator', comp, options)\n this.options = options\n this.loose = !!options.loose\n this.parse(comp)\n\n if (this.semver === ANY) {\n this.value = ''\n } else {\n this.value = this.operator + this.semver.version\n }\n\n debug('comp', this)\n }\n\n parse (comp) {\n const r = this.options.loose ? re[t.COMPARATORLOOSE] : re[t.COMPARATOR]\n const m = comp.match(r)\n\n if (!m) {\n throw new TypeError(`Invalid comparator: ${comp}`)\n }\n\n this.operator = m[1] !== undefined ? m[1] : ''\n if (this.operator === '=') {\n this.operator = ''\n }\n\n // if it literally is just '>' or '' then allow anything.\n if (!m[2]) {\n this.semver = ANY\n } else {\n this.semver = new SemVer(m[2], this.options.loose)\n }\n }\n\n toString () {\n return this.value\n }\n\n test (version) {\n debug('Comparator.test', version, this.options.loose)\n\n if (this.semver === ANY || version === ANY) {\n return true\n }\n\n if (typeof version === 'string') {\n try {\n version = new SemVer(version, this.options)\n } catch (er) {\n return false\n }\n }\n\n return cmp(version, this.operator, this.semver, this.options)\n }\n\n intersects (comp, options) {\n if (!(comp instanceof Comparator)) {\n throw new TypeError('a Comparator is required')\n }\n\n if (this.operator === '') {\n if (this.value === '') {\n return true\n }\n return new Range(comp.value, options).test(this.value)\n } else if (comp.operator === '') {\n if (comp.value === '') {\n return true\n }\n return new Range(this.value, options).test(comp.semver)\n }\n\n options = parseOptions(options)\n\n // Special cases where nothing can possibly be lower\n if (options.includePrerelease &&\n (this.value === '<0.0.0-0' || comp.value === '<0.0.0-0')) {\n return false\n }\n if (!options.includePrerelease &&\n (this.value.startsWith('<0.0.0') || comp.value.startsWith('<0.0.0'))) {\n return false\n }\n\n // Same direction increasing (> or >=)\n if (this.operator.startsWith('>') && comp.operator.startsWith('>')) {\n return true\n }\n // Same direction decreasing (< or <=)\n if (this.operator.startsWith('<') && comp.operator.startsWith('<')) {\n return true\n }\n // same SemVer and both sides are inclusive (<= or >=)\n if (\n (this.semver.version === comp.semver.version) &&\n this.operator.includes('=') && comp.operator.includes('=')) {\n return true\n }\n // opposite directions less than\n if (cmp(this.semver, '<', comp.semver, options) &&\n this.operator.startsWith('>') && comp.operator.startsWith('<')) {\n return true\n }\n // opposite directions greater than\n if (cmp(this.semver, '>', comp.semver, options) &&\n this.operator.startsWith('<') && comp.operator.startsWith('>')) {\n return true\n }\n return false\n }\n}\n\nmodule.exports = Comparator\n\nconst parseOptions = require('../internal/parse-options')\nconst { safeRe: re, t } = require('../internal/re')\nconst cmp = require('../functions/cmp')\nconst debug = require('../internal/debug')\nconst SemVer = require('./semver')\nconst Range = require('./range')\n","'use strict';\n\nvar process$1 = require('process');\nvar semver = require('semver');\nvar os = require('os');\nvar path = require('path');\nvar fs = require('fs');\nvar https = require('https');\n\n/******************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\n\r\nfunction __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nfunction __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (g && (g = 0, op[0] && (_ = 0)), _) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\n\nvar packageJson = process$1.env.npm_package_json;\nvar userAgent = process$1.env.npm_config_user_agent;\nvar isNpm6 = Boolean(userAgent && userAgent.startsWith('npm'));\nvar isNpm7 = Boolean(packageJson && packageJson.endsWith('package.json'));\nvar isNpm = isNpm6 || isNpm7;\nvar isYarn = Boolean(userAgent && userAgent.startsWith('yarn'));\nvar isNpmOrYarn = isNpm || isYarn;\n\nvar homeDirectory = os.homedir();\nvar configDir = process.env.XDG_CONFIG_HOME ||\n path.join(homeDirectory, '.config', 'simple-update-notifier');\nvar getConfigFile = function (packageName) {\n return path.join(configDir, \"\".concat(packageName.replace('@', '').replace('/', '__'), \".json\"));\n};\nvar createConfigDir = function () {\n if (!fs.existsSync(configDir)) {\n fs.mkdirSync(configDir, { recursive: true });\n }\n};\nvar getLastUpdate = function (packageName) {\n var configFile = getConfigFile(packageName);\n try {\n if (!fs.existsSync(configFile)) {\n return undefined;\n }\n var file = JSON.parse(fs.readFileSync(configFile, 'utf8'));\n return file.lastUpdateCheck;\n }\n catch (_a) {\n return undefined;\n }\n};\nvar saveLastUpdate = function (packageName) {\n var configFile = getConfigFile(packageName);\n fs.writeFileSync(configFile, JSON.stringify({ lastUpdateCheck: new Date().getTime() }));\n};\n\nvar getDistVersion = function (packageName, distTag) { return __awaiter(void 0, void 0, void 0, function () {\n var url;\n return __generator(this, function (_a) {\n url = \"https://registry.npmjs.org/-/package/\".concat(packageName, \"/dist-tags\");\n return [2 /*return*/, new Promise(function (resolve, reject) {\n https\n .get(url, function (res) {\n var body = '';\n res.on('data', function (chunk) { return (body += chunk); });\n res.on('end', function () {\n try {\n var json = JSON.parse(body);\n var version = json[distTag];\n if (!version) {\n reject(new Error('Error getting version'));\n }\n resolve(version);\n }\n catch (_a) {\n reject(new Error('Could not parse version response'));\n }\n });\n })\n .on('error', function (err) { return reject(err); });\n })];\n });\n}); };\n\nvar hasNewVersion = function (_a) {\n var pkg = _a.pkg, _b = _a.updateCheckInterval, updateCheckInterval = _b === void 0 ? 1000 * 60 * 60 * 24 : _b, _c = _a.distTag, distTag = _c === void 0 ? 'latest' : _c, alwaysRun = _a.alwaysRun, debug = _a.debug;\n return __awaiter(void 0, void 0, void 0, function () {\n var lastUpdateCheck, latestVersion;\n return __generator(this, function (_d) {\n switch (_d.label) {\n case 0:\n createConfigDir();\n lastUpdateCheck = getLastUpdate(pkg.name);\n if (!(alwaysRun ||\n !lastUpdateCheck ||\n lastUpdateCheck < new Date().getTime() - updateCheckInterval)) return [3 /*break*/, 2];\n return [4 /*yield*/, getDistVersion(pkg.name, distTag)];\n case 1:\n latestVersion = _d.sent();\n saveLastUpdate(pkg.name);\n if (semver.gt(latestVersion, pkg.version)) {\n return [2 /*return*/, latestVersion];\n }\n else if (debug) {\n console.error(\"Latest version (\".concat(latestVersion, \") not newer than current version (\").concat(pkg.version, \")\"));\n }\n return [3 /*break*/, 3];\n case 2:\n if (debug) {\n console.error(\"Too recent to check for a new update. simpleUpdateNotifier() interval set to \".concat(updateCheckInterval, \"ms but only \").concat(new Date().getTime() - lastUpdateCheck, \"ms since last check.\"));\n }\n _d.label = 3;\n case 3: return [2 /*return*/, false];\n }\n });\n });\n};\n\nvar borderedText = function (text) {\n var lines = text.split('\\n');\n var width = Math.max.apply(Math, lines.map(function (l) { return l.length; }));\n var res = [\"\\u250C\".concat('─'.repeat(width + 2), \"\\u2510\")];\n for (var _i = 0, lines_1 = lines; _i < lines_1.length; _i++) {\n var line = lines_1[_i];\n res.push(\"\\u2502 \".concat(line.padEnd(width), \" \\u2502\"));\n }\n res.push(\"\\u2514\".concat('─'.repeat(width + 2), \"\\u2518\"));\n return res.join('\\n');\n};\n\nvar simpleUpdateNotifier = function (args) { return __awaiter(void 0, void 0, void 0, function () {\n var latestVersion, err_1;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!args.alwaysRun &&\n (!process.stdout.isTTY || (isNpmOrYarn && !args.shouldNotifyInNpmScript))) {\n if (args.debug) {\n console.error('Opting out of running simpleUpdateNotifier()');\n }\n return [2 /*return*/];\n }\n _a.label = 1;\n case 1:\n _a.trys.push([1, 3, , 4]);\n return [4 /*yield*/, hasNewVersion(args)];\n case 2:\n latestVersion = _a.sent();\n if (latestVersion) {\n console.error(borderedText(\"New version of \".concat(args.pkg.name, \" available!\\nCurrent Version: \").concat(args.pkg.version, \"\\nLatest Version: \").concat(latestVersion)));\n }\n return [3 /*break*/, 4];\n case 3:\n err_1 = _a.sent();\n // Catch any network errors or cache writing errors so module doesn't cause a crash\n if (args.debug && err_1 instanceof Error) {\n console.error('Unexpected error in simpleUpdateNotifier():', err_1);\n }\n return [3 /*break*/, 4];\n case 4: return [2 /*return*/];\n }\n });\n}); };\n\nmodule.exports = simpleUpdateNotifier;\n","function toArr(any) {\n\treturn any == null ? [] : Array.isArray(any) ? any : [any];\n}\n\nfunction toVal(out, key, val, opts) {\n\tvar x, old=out[key], nxt=(\n\t\t!!~opts.string.indexOf(key) ? (val == null || val === true ? '' : String(val))\n\t\t: typeof val === 'boolean' ? val\n\t\t: !!~opts.boolean.indexOf(key) ? (val === 'false' ? false : val === 'true' || (out._.push((x = +val,x * 0 === 0) ? x : val),!!val))\n\t\t: (x = +val,x * 0 === 0) ? x : val\n\t);\n\tout[key] = old == null ? nxt : (Array.isArray(old) ? old.concat(nxt) : [old, nxt]);\n}\n\nexport default function (args, opts) {\n\targs = args || [];\n\topts = opts || {};\n\n\tvar k, arr, arg, name, val, out={ _:[] };\n\tvar i=0, j=0, idx=0, len=args.length;\n\n\tconst alibi = opts.alias !== void 0;\n\tconst strict = opts.unknown !== void 0;\n\tconst defaults = opts.default !== void 0;\n\n\topts.alias = opts.alias || {};\n\topts.string = toArr(opts.string);\n\topts.boolean = toArr(opts.boolean);\n\n\tif (alibi) {\n\t\tfor (k in opts.alias) {\n\t\t\tarr = opts.alias[k] = toArr(opts.alias[k]);\n\t\t\tfor (i=0; i < arr.length; i++) {\n\t\t\t\t(opts.alias[arr[i]] = arr.concat(k)).splice(i, 1);\n\t\t\t}\n\t\t}\n\t}\n\n\tfor (i=opts.boolean.length; i-- > 0;) {\n\t\tarr = opts.alias[opts.boolean[i]] || [];\n\t\tfor (j=arr.length; j-- > 0;) opts.boolean.push(arr[j]);\n\t}\n\n\tfor (i=opts.string.length; i-- > 0;) {\n\t\tarr = opts.alias[opts.string[i]] || [];\n\t\tfor (j=arr.length; j-- > 0;) opts.string.push(arr[j]);\n\t}\n\n\tif (defaults) {\n\t\tfor (k in opts.default) {\n\t\t\tname = typeof opts.default[k];\n\t\t\tarr = opts.alias[k] = opts.alias[k] || [];\n\t\t\tif (opts[name] !== void 0) {\n\t\t\t\topts[name].push(k);\n\t\t\t\tfor (i=0; i < arr.length; i++) {\n\t\t\t\t\topts[name].push(arr[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tconst keys = strict ? Object.keys(opts.alias) : [];\n\n\tfor (i=0; i < len; i++) {\n\t\targ = args[i];\n\n\t\tif (arg === '--') {\n\t\t\tout._ = out._.concat(args.slice(++i));\n\t\t\tbreak;\n\t\t}\n\n\t\tfor (j=0; j < arg.length; j++) {\n\t\t\tif (arg.charCodeAt(j) !== 45) break; // \"-\"\n\t\t}\n\n\t\tif (j === 0) {\n\t\t\tout._.push(arg);\n\t\t} else if (arg.substring(j, j + 3) === 'no-') {\n\t\t\tname = arg.substring(j + 3);\n\t\t\tif (strict && !~keys.indexOf(name)) {\n\t\t\t\treturn opts.unknown(arg);\n\t\t\t}\n\t\t\tout[name] = false;\n\t\t} else {\n\t\t\tfor (idx=j+1; idx < arg.length; idx++) {\n\t\t\t\tif (arg.charCodeAt(idx) === 61) break; // \"=\"\n\t\t\t}\n\n\t\t\tname = arg.substring(j, idx);\n\t\t\tval = arg.substring(++idx) || (i+1 === len || (''+args[i+1]).charCodeAt(0) === 45 || args[++i]);\n\t\t\tarr = (j === 2 ? [name] : name);\n\n\t\t\tfor (idx=0; idx < arr.length; idx++) {\n\t\t\t\tname = arr[idx];\n\t\t\t\tif (strict && !~keys.indexOf(name)) return opts.unknown('-'.repeat(j) + name);\n\t\t\t\ttoVal(out, name, (idx + 1 < arr.length) || val, opts);\n\t\t\t}\n\t\t}\n\t}\n\n\tif (defaults) {\n\t\tfor (k in opts.default) {\n\t\t\tif (out[k] === void 0) {\n\t\t\t\tout[k] = opts.default[k];\n\t\t\t}\n\t\t}\n\t}\n\n\tif (alibi) {\n\t\tfor (k in out) {\n\t\t\tarr = opts.alias[k] || [];\n\t\t\twhile (arr.length > 0) {\n\t\t\t\tout[arr.shift()] = out[k];\n\t\t\t}\n\t\t}\n\t}\n\n\treturn out;\n}\n","import { promises } from \"fs\";\nimport { execRoot } from \"admina\";\nimport ciInfo from \"ci-info\";\nconst { GITHUB_ACTIONS } = ciInfo;\nimport { sourceRC } from \"envosman\";\nconst { appendFile } = promises;\n/**\n * Update the alternatives for a package\n * @param name The name of the package\n * @param path The path to the binary\n * @param priority The priority of the alternative (Defaults to `40`)\n */\nexport async function updateAptAlternatives(name, path, priority = 40) {\n await execRoot(\"update-alternatives\", [\"--install\", `/usr/bin/${name}`, name, path, priority.toString()]);\n}\n/**\n * Add the update-alternatives command to the rc file\n * @param name The name of the package\n * @param path The path to the binary\n * @param rcOptions The options for the rc file to add the update-alternatives command to\n * @param priority The priority of the alternative (Defaults to `40`)\n */\nexport async function addUpdateAlternativesToRc(name, path, rcOptions, priority = 40) {\n if (GITHUB_ACTIONS) {\n await updateAptAlternatives(name, path, priority);\n }\n else {\n await sourceRC(rcOptions);\n await appendFile(rcOptions.rcPath, `\\nif [ $UID -eq 0 ]; then update-alternatives --install /usr/bin/${name} ${name} ${path} ${priority}; fi\\n`);\n }\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWx0ZXJuYXRpdmVzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vc3JjL2FsdGVybmF0aXZlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsUUFBUSxFQUFFLE1BQU0sSUFBSSxDQUFBO0FBQzdCLE9BQU8sRUFBRSxRQUFRLEVBQUUsTUFBTSxRQUFRLENBQUE7QUFDakMsT0FBTyxNQUFNLE1BQU0sU0FBUyxDQUFBO0FBQzVCLE1BQU0sRUFBRSxjQUFjLEVBQUUsR0FBRyxNQUFNLENBQUE7QUFDakMsT0FBTyxFQUFFLFFBQVEsRUFBRSxNQUFNLFVBQVUsQ0FBQTtBQUVuQyxNQUFNLEVBQUUsVUFBVSxFQUFFLEdBQUcsUUFBUSxDQUFBO0FBRS9COzs7OztHQUtHO0FBQ0gsTUFBTSxDQUFDLEtBQUssVUFBVSxxQkFBcUIsQ0FBQyxJQUFZLEVBQUUsSUFBWSxFQUFFLFdBQW1CLEVBQUU7SUFDM0YsTUFBTSxRQUFRLENBQUM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lvbnM6IFJjT3B0aW9ucyxcbiAgcHJpb3JpdHk6IG51bWJlciA9IDQwLFxuKSB7XG4gIGlmIChHSVRIVUJfQUNUSU9OUykge1xuICAgIGF3YWl0IHVwZGF0ZUFwdEFsdGVybmF0aXZlcyhuYW1lLCBwYXRoLCBwcmlvcml0eSlcbiAgfSBlbHNlIHtcbiAgICBhd2FpdCBzb3VyY2VSQyhyY09wdGlvbnMpXG4gICAgYXdhaXQgYXBwZW5kRmlsZShcbiAgICAgIHJjT3B0aW9ucy5yY1BhdGgsXG4gICAgICBgXFxuaWYgWyAkVUlEIC1lcSAwIF07IHRoZW4gdXBkYXRlLWFsdGVybmF0aXZlcyAtLWluc3RhbGwgL3Vzci9iaW4vJHtuYW1lfSAke25hbWV9ICR7cGF0aH0gJHtwcmlvcml0eX07IGZpXFxuYCxcbiAgICApXG4gIH1cbn1cbiJdfQ==","/**\n * Get the environment variables to use for the apt command\n * @param apt The apt command to use\n * @private Used internally\n */\nexport function getAptEnv(apt) {\n const env = { ...process.env, DEBIAN_FRONTEND: \"noninteractive\" };\n if (apt === \"nala\") {\n // if LANG/LC_ALL is not set, enable utf8 otherwise nala fails because of ASCII encoding\n if (env.LANG === undefined) {\n env.LANG = \"C.UTF-8\";\n }\n if (env.LC_ALL === undefined) {\n env.LC_ALL = \"C.UTF-8\";\n }\n }\n return env;\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXB0LWVudi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3NyYy9hcHQtZW52LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOzs7O0dBSUc7QUFFSCxNQUFNLFVBQVUsU0FBUyxDQUFDLEdBQVc7SUFDbkMsTUFBTSxHQUFHLEdBQXNCLEVBQUUsR0FBRyxPQUFPLENBQUMsR0FBRyxFQUFFLGVBQWUsRUFBRSxnQkFBZ0IsRUFBRSxDQUFBO0lBRXB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PSBcIkMuVVRGLThcIlxuICAgIH1cbiAgfVxuXG4gIHJldHVybiBlbnZcbn1cbiJdfQ==","import which from \"which\";\n/**\n * Check if nala is installed\n */\nexport function hasNala() {\n return which.sync(\"nala\", { nothrow: true }) !== null;\n}\n/**\n * Get the apt command to use\n * If nala is installed, use that, otherwise use apt-get\n */\nexport function getApt() {\n let apt;\n if (hasNala()) {\n apt = \"nala\";\n }\n else {\n apt = \"apt-get\";\n }\n return apt;\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2V0LWFwdC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3NyYy9nZXQtYXB0LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sS0FBSyxNQUFNLE9BQU8sQ0FBQTtBQUV6Qjs7R0FFRztBQUNILE1BQU0sVUFBVSxPQUFPO0lBQ3JCLE9BQU8sS0FBSyxDQUFDLElBQUksQ0FBQyxNQUFNLEVBQUUsRUFBRSxPQUFPLEVBQUUsSUFBSSxFQUFFLENBQUMsS0FBSyxJQUFJLENBQUE7QUFDdkQsQ0FBQztBQUVEOzs7R0FHRztBQUNILE1BQU0sVUFBVSxNQUFNO0lBQ3BCLElBQUksR0FBVyxDQUFBO0lBQ2YsSUFBSSxPQUFPLEVBQUUsRUFBRSxDQUFDO1FBQ2QsR0FBRyxHQUFHLE1BQU0sQ0FBQTtJQUNkLENBQUM7U0FBTSxDQUFDO1FBQ04sR0FBRyxHQUFHLFNBQVMsQ0FBQTtJQUNqQixDQUFDO0lBQ0QsT0FBTyxHQUFHLENBQUE7QUFDWixDQUFDIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHdoaWNoIGZyb20gXCJ3aGljaFwiXG5cbi8qKlxuICogQ2hlY2sgaWYgbmFsYSBpcyBpbnN0YWxsZWRcbiAqL1xuZXhwb3J0IGZ1bmN0aW9uIGhhc05hbGEoKSB7XG4gIHJldHVybiB3aGljaC5zeW5jKFwibmFsYVwiLCB7IG5vdGhyb3c6IHRydWUgfSkgIT09IG51bGxcbn1cblxuLyoqXG4gKiBHZXQgdGhlIGFwdCBjb21tYW5kIHRvIHVzZVxuICogSWYgbmFsYSBpcyBpbnN0YWxsZWQsIHVzZSB0aGF0LCBvdGhlcndpc2UgdXNlIGFwdC1nZXRcbiAqL1xuZXhwb3J0IGZ1bmN0aW9uIGdldEFwdCgpIHtcbiAgbGV0IGFwdDogc3RyaW5nXG4gIGlmIChoYXNOYWxhKCkpIHtcbiAgICBhcHQgPSBcIm5hbGFcIlxuICB9IGVsc2Uge1xuICAgIGFwdCA9IFwiYXB0LWdldFwiXG4gIH1cbiAgcmV0dXJuIGFwdFxufVxuIl19","export default function escapeStringRegexp(string) {\n\tif (typeof string !== 'string') {\n\t\tthrow new TypeError('Expected a string');\n\t}\n\n\t// Escape characters with special meaning either inside or outside character sets.\n\t// Use a simple backslash escape when its always valid, and a `\\xnn` escape when the simpler form would be disallowed by Unicode patterns stricter grammar.\n\treturn string\n\t\t.replace(/[|\\\\{}()[\\]^$+*?.]/g, '\\\\$&')\n\t\t.replace(/-/g, '\\\\x2d');\n}\n","import { execa } from \"execa\";\nimport { getAptEnv } from \"./apt-env.js\";\n/**\n * Check if a package is installed\n * @param pack The package to check\n * @returns `true` if the package is installed, `false` otherwise\n */\nexport async function isAptPackInstalled(pack) {\n try {\n // check if a package is installed\n const { stdout } = await execa(\"dpkg\", [\"-s\", pack], { env: getAptEnv(\"apt-get\"), stdio: \"pipe\" });\n if (typeof stdout !== \"string\") {\n return false;\n }\n const lines = stdout.split(\"\\n\");\n // check if the output contains a line that starts with \"Status: install ok installed\"\n return lines.some((line) => line.startsWith(\"Status: install ok installed\"));\n }\n catch {\n return false;\n }\n}\n/**\n * Check if a package matching a regexp is installed\n * @param regexp The regexp to check\n * @returns `true` if a package is installed, `false` otherwise\n */\nexport async function isAptPackRegexInstalled(regexp) {\n try {\n // check if a package matching the regexp is installed\n const { stdout } = await execa(\"dpkg\", [\"-l\", regexp], { env: getAptEnv(\"apt-get\"), stdio: \"pipe\" });\n if (typeof stdout !== \"string\") {\n return false;\n }\n const lines = stdout.split(\"\\n\");\n // check if the output contains any lines that start with \"ii\"\n return lines.some((line) => line.startsWith(\"ii\"));\n }\n catch {\n return false;\n }\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaXMtaW5zdGFsbGVkLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vc3JjL2lzLWluc3RhbGxlZC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsS0FBSyxFQUFFLE1BQU0sT0FBTyxDQUFBO0FBQzdCLE9BQU8sRUFBRSxTQUFTLEVBQUUsTUFBTSxjQUFjLENBQUE7QUFFeEM7Ozs7R0FJRztBQUNILE1BQU0sQ0FBQyxLQUFLLFVBQVUsa0JBQWtCLENBQUMsSUFBWTtJQUNuRCxJQUFJLENBQUM7UUFDSCxrQ0FBa0M7UUFDbEMsTUFBTSxFQUFFLE1BQU0sRUFBRSxHQUFHLE1BQU0sS0FBSyxDQUFDLE1BQU0sRUFBRSxDQUFDLElBQUksRUFBRSxJQUFJLENBQUMsRUFBRSxFQUFFLEdBQUcsRUFBRSxTQUFTLENBQUMsU0FBUyxDQUFDLEVBQUUsS0FBSyxFQUFFLE1BQU0sRUFBRSxDQUFDLENBQUE7UUFDbEcsSUFBSSxPQUFPLE1BQU0sS0FBSyxRQUFRLEVBQUUsQ0FBQztZQUMvQixPQUFPLEtBQUssQ0FBQTtRQUNkLENBQUM7UUFDRCxNQUFNLEtBQUssR0FBRyxNQUFNLENBQUMsS0FBSyxDQUFDLElBQUksQ0FBQyxDQUFBO1FBQ2hDLHNGQUFzRjtRQUN0RixPQUFPLEtBQUssQ0FBQyxJQUFJLENBQUMsQ0FBQyxJQUFJLEVBQUUsRUFBRSxDQUFD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VgIG90aGVyd2lzZVxuICovXG5leHBvcnQgYXN5bmMgZnVuY3Rpb24gaXNBcHRQYWNrUmVnZXhJbnN0YWxsZWQocmVnZXhwOiBzdHJpbmcpIHtcbiAgdHJ5IHtcbiAgICAvLyBjaGVjayBpZiBhIHBhY2thZ2UgbWF0Y2hpbmcgdGhlIHJlZ2V4cCBpcyBpbnN0YWxsZWRcbiAgICBjb25zdCB7IHN0ZG91dCB9ID0gYXdhaXQgZXhlY2EoXCJkcGtnXCIsIFtcIi1sXCIsIHJlZ2V4cF0sIHsgZW52OiBnZXRBcHRFbnYoXCJhcHQtZ2V0XCIpLCBzdGRpbzogXCJwaXBlXCIgfSlcbiAgICBpZiAodHlwZW9mIHN0ZG91dCAhPT0gXCJzdHJpbmdcIikge1xuICAgICAgcmV0dXJuIGZhbHNlXG4gICAgfVxuICAgIGNvbnN0IGxpbmVzID0gc3Rkb3V0LnNwbGl0KFwiXFxuXCIpXG4gICAgLy8gY2hlY2sgaWYgdGhlIG91dHB1dCBjb250YWlucyBhbnkgbGluZXMgdGhhdCBzdGFydCB3aXRoIFwiaWlcIlxuICAgIHJldHVybiBsaW5lcy5zb21lKChsaW5lKSA9PiBsaW5lLnN0YXJ0c1dpdGgoXCJpaVwiKSlcbiAgfSBjYXRjaCB7XG4gICAgcmV0dXJuIGZhbHNlXG4gIH1cbn1cbiJdfQ==","import { warning } from \"ci-log\";\nimport escapeRegex from \"escape-string-regexp\";\nimport { execa } from \"execa\";\nimport { getAptEnv } from \"./apt-env.js\";\nimport { getApt } from \"./get-apt.js\";\nimport { isAptPackInstalled } from \"./is-installed.js\";\nimport { updateAptReposMemoized, updatedRepos } from \"./update.js\";\n/**\n * The type of apt package to install\n */\nexport var AptPackageType;\n(function (AptPackageType) {\n AptPackageType[AptPackageType[\"NameDashVersion\"] = 0] = \"NameDashVersion\";\n AptPackageType[AptPackageType[\"NameEqualsVersion\"] = 1] = \"NameEqualsVersion\";\n AptPackageType[AptPackageType[\"Name\"] = 2] = \"Name\";\n AptPackageType[AptPackageType[\"None\"] = 3] = \"None\";\n})(AptPackageType || (AptPackageType = {}));\n/**\n * Filter out the packages that are already installed and qualify the packages into a full package name/version\n */\nexport async function filterAndQualifyAptPackages(packages, apt = getApt()) {\n return (await Promise.all(packages.map((pack) => qualifiedNeededAptPackage(pack, apt))))\n .filter((pack) => pack !== undefined);\n}\n/**\n * Qualify the package into full package name/version.\n * If the package is not installed, return the full package name/version.\n * If the package is already installed, return undefined\n */\nexport async function qualifiedNeededAptPackage(pack, apt = getApt()) {\n // Qualify the package into full package name/version\n const qualified = await getAptArg(apt, pack.name, pack.version);\n // filter out the package that are already installed\n return (await isAptPackInstalled(qualified)) ? undefined : qualified;\n}\nasync function aptPackageType(apt, name, version) {\n if (version !== undefined && version !== \"\") {\n const { stdout } = await execa(\"apt-cache\", [\n \"search\",\n \"--names-only\",\n `^${escapeRegex(name)}-${escapeRegex(version)}$`,\n ], { env: getAptEnv(apt), stdio: \"pipe\" });\n if (stdout.trim() !== \"\") {\n return AptPackageType.NameDashVersion;\n }\n try {\n // check if apt-get show can find the version\n // eslint-disable-next-line @typescript-eslint/no-shadow\n const { stdout } = await execa(\"apt-cache\", [\"show\", `${name}=${version}`], { env: getAptEnv(apt) });\n if (stdout.trim() === \"\") {\n return AptPackageType.NameEqualsVersion;\n }\n }\n catch {\n // ignore\n }\n }\n try {\n const { stdout: showStdout } = await execa(\"apt-cache\", [\"show\", name], { env: getAptEnv(apt), stdio: \"pipe\" });\n if (showStdout.trim() !== \"\") {\n return AptPackageType.Name;\n }\n }\n catch {\n // ignore\n }\n // If apt-cache fails, update the repos and try again\n if (!updatedRepos) {\n updateAptReposMemoized(apt);\n return aptPackageType(apt, name, version);\n }\n return AptPackageType.None;\n}\nasync function getAptArg(apt, name, version) {\n const package_type = await aptPackageType(apt, name, version);\n switch (package_type) {\n case AptPackageType.NameDashVersion:\n return `${name}-${version}`;\n case AptPackageType.NameEqualsVersion:\n return `${name}=${version}`;\n case AptPackageType.Name:\n if (version !== undefined && version !== \"\") {\n warning(`Could not find package ${name} with version ${version}. Installing the latest version.`);\n }\n return name;\n default:\n throw new Error(`Could not find package ${name} ${version ?? \"\"}`);\n }\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicXVhbGlmeS1pbnN0YWxsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vc3JjL3F1YWxpZnktaW5zdGFsbC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsT0FBTyxFQUFFLE1BQU0sUUFBUSxDQUFBO0FBQ2hDLE9BQU8sV0FBVyxNQUFNLHNCQUFzQixDQUFBO0FBQzlDLE9BQU8sRUFBRSxLQUFLLEVBQUUsTUFBTSxPQUFPLENBQUE7QUFDN0IsT0FBTyxFQUFFLFNBQVMsRUFBRSxNQUFNLGNBQWMsQ0FBQTtBQUN4QyxPQUFPLEVBQUUsTUFBTSxFQUFFLE1BQU0sY0FBYyxDQUFBO0FBRXJDLE9BQU8sRUFBRSxrQkFBa0IsRUFBRSxNQUFNLG1CQUFtQixDQUFBO0FBQ3RELE9BQU8sRUFBRSxzQkFBc0IsRUFBRSxZQUFZLEVBQUUsTUFBTSxhQUFhLENBQUE7QUFFbEU7O0dBRUc7QUFDSCxNQUFNLENBQU4sSUFBWSxjQUtYO0FBTEQsV0FBWSxjQUFjO0lBQ3hCLHlFQUFtQixDQUFBO0lBQ25CLDZFQUFxQixDQUFBO0lBQ3JCLG1EQUFRLENBQUE7SUFDUixtREFBUSxDQUFBO0FBQ1YsQ0FBQyxFQUxXLGNBQWMsS0FBZCxjQUFjLFFBS3pCO0FBRUQ7O0dBRUc7QUFDSCxNQUFNLENBQUMsS0FBSyxVQUFVLDJCQUEyQixDQUFDLFFBQXNCLEVBQUUsTUFBYyxNQUFNLEVBQUU7SUFDOUYsT0FBTyxDQUFDLE1BQU0sT0FBTyxDQUFDLEdBQUcsQ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W9ufS4gSW5zdGFsbGluZyB0aGUgbGF0ZXN0IHZlcnNpb24uYClcbiAgICAgIH1cbiAgICAgIHJldHVybiBuYW1lXG4gICAgZGVmYXVsdDpcbiAgICAgIHRocm93IG5ldyBFcnJvcihgQ291bGQgbm90IGZpbmQgcGFja2FnZSAke25hbWV9ICR7dmVyc2lvbiA/PyBcIlwifWApXG4gIH1cbn1cbiJdfQ==","import { defaultExecOptions, execRootSync } from \"admina\";\nimport { info, warning } from \"ci-log\";\nimport { getAptEnv } from \"./apt-env.js\";\nimport { addAptKey } from \"./apt-key.js\";\nimport { addAptRepository } from \"./apt-repository.js\";\nimport { aptTimeout } from \"./apt-timeout.js\";\nimport { getApt } from \"./get-apt.js\";\nimport { initAptMemoized } from \"./init-apt.js\";\nimport { filterAndQualifyAptPackages } from \"./qualify-install.js\";\nimport { updateAptReposMemoized } from \"./update.js\";\nconst retryErrors = [\n \"E: Could not get lock\",\n \"dpkg: error processing archive\",\n \"dpkg: error: dpkg status database is locked by another process\",\n];\n/**\n * Install a package using apt\n *\n * @param packages The packages to install (name, and optional info like version and repositories)\n * @param update Whether to update the package list before installing (Defaults to `false`)\n *\n * @returns The installation information\n *\n * @example\n * ```ts\n * await installAptPack([{ name: \"ca-certificates\" }, { name: \"gnupg\" }])\n * ```\n *\n * @example\n * ```ts\n await installAptPack([\n {\n name: \"gcc\",\n version,\n repository: \"ppa:ubuntu-toolchain-r/test\",\n key: { key: \"1E9377A2BA9EF27F\", fileName: \"ubuntu-toolchain-r-test.gpg\" },\n },\n ])\n * ```\n */\nexport async function installAptPack(packages, update = false) {\n try {\n const apt = getApt();\n for (const { name, version } of packages) {\n info(`Installing ${name} ${version ?? \"\"} via ${apt}`);\n }\n // Update the repos if needed\n if (update) {\n updateAptReposMemoized(apt);\n }\n // Add the repos if needed\n await addRepositories(apt, packages);\n const needToInstall = await filterAndQualifyAptPackages(packages, apt);\n if (needToInstall.length === 0) {\n info(\"All packages are already installed\");\n return { binDir: \"/usr/bin/\" };\n }\n // Initialize apt if needed\n await initAptMemoized(apt);\n try {\n // Add the keys if needed\n await addAptKeys(packages);\n // Install\n execRootSync(apt, [\"install\", \"--fix-broken\", \"-y\", ...needToInstall], {\n ...defaultExecOptions,\n env: getAptEnv(apt),\n });\n }\n catch (err) {\n if (isExecaError(err)) {\n if (retryErrors.some((error) => typeof err.stderr === \"string\" && err.stderr.includes(error))) {\n warning(`Failed to install packages ${needToInstall}. Retrying...`);\n execRootSync(apt, [\"install\", \"--fix-broken\", \"-y\", \"-o\", aptTimeout, ...needToInstall], { ...defaultExecOptions, env: getAptEnv(apt) });\n }\n }\n else {\n throw err;\n }\n }\n return { binDir: \"/usr/bin/\" };\n }\n catch (err) {\n const msg = err instanceof Error ? `${err.message}\\n${err.stack}` : String(err);\n throw new Error(`Failed to install apt packages: ${msg}`);\n }\n}\nasync function addRepositories(apt, packages) {\n const allRepositories = [...new Set(packages.flatMap((pack) => pack.repository ?? []))];\n await Promise.all(allRepositories.map((repo) => addAptRepository(repo, apt)));\n}\nasync function addAptKeys(packages) {\n await Promise.all(packages.map(async (pack) => {\n if (pack.key !== undefined) {\n await addAptKey(pack.key);\n }\n }));\n}\nfunction isExecaError(err) {\n return typeof err.stderr === \"string\";\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5zdGFsbC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3NyYy9pbnN0YWxsLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxrQkFBa0IsRUFBRSxZQUFZLEVBQUUsTUFBTSxRQUFRLENBQUE7QUFDekQsT0FBTyxFQUFFLElBQUksRUFBRSxPQUFPLEVBQUUsTUFBTSxRQUFRLENBQUE7QUFFdEMsT0FBTyxFQUFFLFNBQVMsRUFBRSxNQUFNLGNBQWMsQ0FBQTtBQUN4QyxPQUFPLEVBQXlCLFNBQVMsRUFBRSxNQ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VxuXG4gICAgcmV0dXJuIHsgYmluRGlyOiBcIi91c3IvYmluL1wiIH1cbiAgfSBjYXRjaCAoZXJyKSB7XG4gICAgY29uc3QgbXNnID0gZXJyIGluc3RhbmNlb2YgRXJyb3IgPyBgJHtlcnIubWVzc2FnZX1cXG4ke2Vyci5zdGFja31gIDogU3RyaW5nKGVycilcbiAgICB0aHJvdyBuZXcgRXJyb3IoYEZhaWxlZCB0byBpbnN0YWxsIGFwdCBwYWNrYWdlczogJHttc2d9YClcbiAgfVxufVxuXG5hc3luYyBmdW5jdGlvbiBhZGRSZXBvc2l0b3JpZXMoYXB0OiBzdHJpbmcsIHBhY2thZ2VzOiBBcHRQYWNrYWdlW10pIHtcbiAgY29uc3QgYWxsUmVwb3NpdG9yaWVzID0gWy4uLm5ldyBTZXQocGFja2FnZXMuZmxhdE1hcCgocGFjaykgPT4gcGFjay5yZXBvc2l0b3J5ID8/IFtdKSldXG4gIGF3YWl0IFByb21pc2UuYWxsKGFsbFJlcG9zaXRvcmllcy5tYXAoKHJlcG8pID0+IGFkZEFwdFJlcG9zaXRvcnkocmVwbywgYXB0KSkpXG59XG5cbmFzeW5jIGZ1bmN0aW9uIGFkZEFwdEtleXMocGFja2FnZXM6IEFwdFBhY2thZ2VbXSkge1xuICBhd2FpdCBQcm9taXNlLmFsbChwYWNrYWdlcy5tYXAoYXN5bmMgKHBhY2spID0+IHtcbiAgICBpZiAocGFjay5rZXkgIT09IHVuZGVmaW5lZCkge1xuICAgICAgYXdhaXQgYWRkQXB0S2V5KHBhY2sua2V5KVxuICAgIH1cbiAgfSkpXG59XG5cbmZ1bmN0aW9uIGlzRXhlY2FFcnJvcihlcnI6IHVua25vd24pOiBlcnIgaXMgRXhlY2FFcnJvciB7XG4gIHJldHVybiB0eXBlb2YgKGVyciBhcyBFeGVjYUVycm9yKS5zdGRlcnIgPT09IFwic3RyaW5nXCJcbn1cbiJdfQ==","import { defaultExecOptions, execRootSync } from \"admina\";\nimport { getAptEnv } from \"./apt-env.js\";\nimport { aptTimeout } from \"./apt-timeout.js\";\nimport { getApt } from \"./get-apt.js\";\nimport { initAptMemoized } from \"./init-apt.js\";\nimport { isAptPackInstalled } from \"./is-installed.js\";\nimport { updateAptReposMemoized } from \"./update.js\";\nexport async function addAptRepository(repo, apt = getApt()) {\n await initAptMemoized(apt);\n await installAddAptRepo(apt);\n execRootSync(\"add-apt-repository\", [\"-y\", \"--no-update\", repo], { ...defaultExecOptions, env: getAptEnv(apt) });\n // Update the repos\n updateAptReposMemoized.clear(); // ensure update is called\n updateAptReposMemoized(apt);\n}\nexport async function installAddAptRepo(apt) {\n if (await isAptPackInstalled(\"software-properties-common\")) {\n return;\n }\n execRootSync(apt, [\"install\", \"-y\", \"--fix-broken\", \"-o\", aptTimeout, \"software-properties-common\"], { ...defaultExecOptions, env: getAptEnv(apt) });\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXB0LXJlcG9zaXRvcnkuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvYXB0LXJlcG9zaXRvcnkudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLGtCQUFrQixFQUFFLFlBQVksRUFBRSxNQUFNLFFBQVEsQ0FBQTtBQUN6RCxPQUFPLEVBQUUsU0FBUyxFQUFFLE1BQU0sY0FBYyxDQUFBO0FBQ3hDLE9BQU8sRUFBRSxVQUFVLEVBQUUsTUFBTSxrQkFBa0IsQ0FBQTtBQUM3QyxPQUFPLEVBQUUsTUFBTSxFQUFFLE1BQU0sY0FBYyxDQUFBO0FBQ3JDLE9BQU8sRUFBRSxlQUFlLEVBQUUsTUFBTSxlQUFlLENBQUE7QUFDL0MsT0FBTyxFQUFFLGtCQUFrQixFQUFFLE1BQU0sbUJBQW1CLENBQUE7QUFDdEQsT0FBTyxFQUFFLHNCQUFzQixFQUFFLE1BQU0sYUFBYSxDQUFBO0FBRXBELE1BQU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AgICBhcHQsXG4gICAgW1wiaW5zdGFsbFwiLCBcIi15XCIsIFwiLS1maXgtYnJva2VuXCIsIFwiLW9cIiwgYXB0VGltZW91dCwgXCJzb2Z0d2FyZS1wcm9wZXJ0aWVzLWNvbW1vblwiXSxcbiAgICB7IC4uLmRlZmF1bHRFeGVjT3B0aW9ucywgZW52OiBnZXRBcHRFbnYoYXB0KSB9LFxuICApXG59XG4iXX0=","import { tmpdir } from \"os\";\nimport { join } from \"path\";\nimport { execRoot, execRootSync } from \"admina\";\nimport { warning } from \"ci-log\";\nimport { DownloaderHelper } from \"node-downloader-helper\";\nimport { pathExists } from \"path-exists\";\nimport { installAptPack } from \"./install.js\";\n/**\n * Add an apt key\n * @param options The options for adding the key\n * @returns The file name of the key that was added or `undefined` if it failed\n *\n * @example\n * ```ts\n * await addAptKey({ key: \"3B4FE6ACC0B21F32\" fileName: \"bazel-archive-keyring.gpg\"})\n * ```\n *\n * @example\n * ```ts\n * await addAptKey({ keyUrl: \"https://bazel.build/bazel-release.pub.gpg\", fileName: \"bazel-archive-keyring.gpg\"})\n * ```\n */\nexport function addAptKey(options) {\n if (\"keyUrl\" in options) {\n return addAptKeyViaURL(options);\n }\n else {\n return addAptKeyViaServer(options);\n }\n}\nexport const defaultKeyStorePath = \"/etc/apt/trusted.gpg.d\";\nexport const defaultKeyServer = \"keyserver.ubuntu.com\";\n/**\n * Add an apt key via a keyserver\n * @returns The file name of the key that was added or `undefined` if it failed\n */\nexport async function addAptKeyViaServer({ key, keyServer = defaultKeyServer, fileName, keyStorePath = defaultKeyServer }) {\n try {\n assertGpgFileName(fileName);\n const filePath = join(keyStorePath, fileName);\n if (!(await pathExists(filePath))) {\n initGpg();\n await execRoot(\"gpg\", [\n \"--no-default-keyring\",\n \"--keyring\",\n `gnupg-ring:${filePath}`,\n \"--keyserver\",\n keyServer,\n \"--recv-keys\",\n key,\n ]);\n await execRoot(\"chmod\", [\"644\", filePath]);\n }\n return filePath;\n }\n catch (err) {\n warning(`Failed to add apt key via server ${keyServer}: ${err}`);\n return undefined;\n }\n}\n/**\n * Add an apt key via a download\n * @param options The options for adding the key\n * @returns The file name of the key that was added\n */\nexport async function addAptKeyViaURL({ keyUrl, fileName, keyStorePath = defaultKeyStorePath }) {\n try {\n assertGpgFileName(fileName);\n const filePath = join(keyStorePath, fileName);\n if (!(await pathExists(filePath))) {\n initGpg();\n await installAptPack([{ name: \"ca-certificates\" }]);\n const dlPath = join(tmpdir(), fileName);\n const dl = new DownloaderHelper(keyUrl, tmpdir(), { fileName });\n dl.on(\"error\", (err) => {\n throw new Error(`Failed to download ${keyUrl}: ${err}`);\n });\n await dl.start();\n execRootSync(\"gpg\", [\n \"--no-default-keyring\",\n \"--keyring\",\n `gnupg-ring:${filePath}`,\n \"--import\",\n dlPath,\n ]);\n execRootSync(\"chmod\", [\"644\", filePath]);\n }\n return filePath;\n }\n catch (err) {\n warning(`Failed to add apt key via download ${keyUrl}: ${err}`);\n return undefined;\n }\n}\nfunction initGpg() {\n execRootSync(\"gpg\", [\"-k\"]);\n}\nfunction assertGpgFileName(fileName) {\n if (!fileName.endsWith(\".gpg\")) {\n throw new Error(`Key file name must end with .gpg: ${fileName}`);\n }\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXB0LWtleS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3NyYy9hcHQta2V5LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxNQUFNLEVBQUUsTUFBTSxJQUFJLENBQUE7QUFDM0IsT0FBTyxFQUFFLElBQUksRUFBRSxNQUFNLE1BQU0sQ0FBQTtBQUMzQixPQUFPLEVBQUUsUUFBUSxFQUFFLFlBQVksRUFBRSxNQUFNLFFBQVEsQ0FBQTtBQUMvQyxPQUFPLEVBQUUsT0FBTyxFQUFFLE1BQU0sUUFBUSxDQUFBO0FBQ2hDLE9BQU8sRUFBRS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H06ICR7ZXJyfWApXG4gICAgICB9KVxuICAgICAgYXdhaXQgZGwuc3RhcnQoKVxuXG4gICAgICBleGVjUm9vdFN5bmMoXCJncGdcIiwgW1xuICAgICAgICBcIi0tbm8tZGVmYXVsdC1rZXlyaW5nXCIsXG4gICAgICAgIFwiLS1rZXlyaW5nXCIsXG4gICAgICAgIGBnbnVwZy1yaW5nOiR7ZmlsZVBhdGh9YCxcbiAgICAgICAgXCItLWltcG9ydFwiLFxuICAgICAgICBkbFBhdGgsXG4gICAgICBdKVxuICAgICAgZXhlY1Jvb3RTeW5jKFwiY2htb2RcIiwgW1wiNjQ0XCIsIGZpbGVQYXRoXSlcbiAgICB9XG4gICAgcmV0dXJuIGZpbGVQYXRoXG4gIH0gY2F0Y2ggKGVycikge1xuICAgIHdhcm5pbmcoYEZhaWxlZCB0byBhZGQgYXB0IGtleSB2aWEgZG93bmxvYWQgJHtrZXlVcmx9OiAke2Vycn1gKVxuICAgIHJldHVybiB1bmRlZmluZWRcbiAgfVxufVxuXG5mdW5jdGlvbiBpbml0R3BnKCkge1xuICBleGVjUm9vdFN5bmMoXCJncGdcIiwgW1wiLWtcIl0pXG59XG5cbmZ1bmN0aW9uIGFzc2VydEdwZ0ZpbGVOYW1lKGZpbGVOYW1lOiBzdHJpbmcpIHtcbiAgaWYgKCFmaWxlTmFtZS5lbmRzV2l0aChcIi5ncGdcIikpIHtcbiAgICB0aHJvdyBuZXcgRXJyb3IoYEtleSBmaWxlIG5hbWUgbXVzdCBlbmQgd2l0aCAuZ3BnOiAke2ZpbGVOYW1lfWApXG4gIH1cbn1cbiJdfQ==","import { tmpdir } from \"os\";\nimport { dirname, join } from \"path\";\nimport { addPath } from \"envosman\";\nimport { execaSync } from \"execa\";\nimport { DownloaderHelper } from \"node-downloader-helper\";\nimport { installAptPack } from \"setup-apt\";\nimport which from \"which\";\n/* eslint-disable require-atomic-updates */\nlet binDir;\nexport async function setupBrew(options = {}) {\n // brew is only available on darwin and linux\n if (![\"darwin\", \"linux\"].includes(process.platform)) {\n return undefined;\n }\n // check if the function has already been called\n if (typeof binDir === \"string\") {\n return { binDir };\n }\n // check if brew is already installed\n const maybeBinDir = await which(\"brew\", { nothrow: true });\n if (maybeBinDir !== null) {\n binDir = dirname(maybeBinDir);\n return { binDir };\n }\n // download the installation script\n await installAptPack([{ name: \"ca-certificates\" }]);\n const dl = new DownloaderHelper(\"https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh\", tmpdir(), {\n fileName: \"install-brew.sh\",\n });\n dl.on(\"error\", (err) => {\n throw new Error(`Failed to download the brew installer script: ${err}`);\n });\n await dl.start();\n // brew installation is not thread-safe\n execaSync(\"/bin/bash\", [dl.getDownloadPath()], {\n stdio: \"inherit\",\n env: {\n NONINTERACTIVE: \"1\",\n },\n });\n // add the bin directory to the PATH\n binDir = getBrewBinDir();\n await addPath(binDir, options.rcOptions);\n return { binDir };\n}\n/**\n * Get the path to the bin directory of brew\n * @returns {string} The path where brew binary is installed\n *\n * Based on the installation script from https://brew.sh\n */\nexport function getBrewBinDir() {\n return join(getBrewDir(), \"bin\");\n}\n/**\n * Get the path where brew is installed\n * @returns {string} The path where brew is installed\n *\n * Based on the installation script from https://brew.sh\n */\nexport function getBrewDir() {\n if (process.platform === \"darwin\") {\n if (process.arch === \"arm64\") {\n return \"/opt/homebrew\";\n }\n else {\n return \"/usr/local\";\n }\n }\n if (process.platform === \"linux\") {\n return \"/home/linuxbrew/.linuxbrew\";\n }\n throw new Error(\"Unsupported platform for brew\");\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5zdGFsbC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3NyYy9pbnN0YWxsLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxNQUFNLEVBQUUsTUFBTSxJQUFJLENBQUE7QUFDM0IsT0FBTyxFQUFFLE9BQU8sRUFBRS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QgdGhlIHBhdGggdG8gdGhlIGJpbiBkaXJlY3Rvcnkgb2YgYnJld1xuICogQHJldHVybnMge3N0cmluZ30gVGhlIHBhdGggd2hlcmUgYnJldyBiaW5hcnkgaXMgaW5zdGFsbGVkXG4gKlxuICogQmFzZWQgb24gdGhlIGluc3RhbGxhdGlvbiBzY3JpcHQgZnJvbSBodHRwczovL2JyZXcuc2hcbiAqL1xuZXhwb3J0IGZ1bmN0aW9uIGdldEJyZXdCaW5EaXIoKSB7XG4gIHJldHVybiBqb2luKGdldEJyZXdEaXIoKSwgXCJiaW5cIilcbn1cblxuLyoqXG4gKiBHZXQgdGhlIHBhdGggd2hlcmUgYnJldyBpcyBpbnN0YWxsZWRcbiAqIEByZXR1cm5zIHtzdHJpbmd9IFRoZSBwYXRoIHdoZXJlIGJyZXcgaXMgaW5zdGFsbGVkXG4gKlxuICogQmFzZWQgb24gdGhlIGluc3RhbGxhdGlvbiBzY3JpcHQgZnJvbSBodHRwczovL2JyZXcuc2hcbiAqL1xuZXhwb3J0IGZ1bmN0aW9uIGdldEJyZXdEaXIoKSB7XG4gIGlmIChwcm9jZXNzLnBsYXRmb3JtID09PSBcImRhcndpblwiKSB7XG4gICAgaWYgKHByb2Nlc3MuYXJjaCA9PT0gXCJhcm02NFwiKSB7XG4gICAgICByZXR1cm4gXCIvb3B0L2hvbWVicmV3XCJcbiAgICB9IGVsc2Uge1xuICAgICAgcmV0dXJuIFwiL3Vzci9sb2NhbFwiXG4gICAgfVxuICB9XG5cbiAgaWYgKHByb2Nlc3MucGxhdGZvcm0gPT09IFwibGludXhcIikge1xuICAgIHJldHVybiBcIi9ob21lL2xpbnV4YnJldy8ubGludXhicmV3XCJcbiAgfVxuXG4gIHRocm93IG5ldyBFcnJvcihcIlVuc3VwcG9ydGVkIHBsYXRmb3JtIGZvciBicmV3XCIpXG59XG4iXX0=","import { join } from \"path\";\nimport { info } from \"ci-log\";\nimport { execaSync } from \"execa\";\nimport which from \"which\";\nimport { getBrewBinDir, setupBrew } from \"./install.js\";\n/* eslint-disable require-atomic-updates */\nlet hasBrew = false;\n/** A function that installs a package using brew\n *\n * @param name The name of the package\n * @param version The version of the package (optional)\n * @param options The options for installing the package\n *\n * @returns The installation information\n */\nexport async function installBrewPack(name, version, givenOptions = {}) {\n const options = {\n overwrite: true,\n cask: false,\n args: [],\n ...givenOptions,\n };\n info(`Installing ${name} ${version ?? \"\"} via brew`);\n if (!hasBrew || which.sync(\"brew\", { nothrow: true }) === null) {\n await setupBrew();\n hasBrew = true;\n }\n const binDir = getBrewBinDir();\n const brewPath = join(binDir, \"brew\");\n // Args\n const args = [\n \"install\",\n (version !== undefined && version !== \"\") ? `${name}@${version}` : name,\n ];\n if (options.overwrite) {\n args.push(\"--overwrite\");\n }\n if (options.cask) {\n args.push(\"--cask\");\n }\n // brew is not thread-safe\n execaSync(brewPath, args, { stdio: \"inherit\" });\n return { binDir };\n}\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5zdGFsbC1wYWNrLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vc3JjL2luc3RhbGwtcGFjay50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsSUFBSSxFQUFFLE1BQU0sTUFBTSxDQUFBO0FBQzNCLE9BQU8sRUFBRSxJQUFJLEVBQUUsTUFBTSxRQUFRLENBQUE7QUFDN0IsT0FBTyxFQUFFLFNBQVMsRUFBRSxNQUFNLE9BQU8sQ0FBQTtBQUNqQyxPQUFPLEtBQUssTUFBTSxPQUFPLENBQUE7QUFFekIsT0FBTyxFQUFFLGFBQWEsRUFBRSxTQUFTLEVBQUUsTUFBTSxjQUFjLENBQUE7QUFFdkQsMkNBQTJDO0FBQzNDLElBQUksT0FBTyxHQUFHLEtBQUssQ0FBQTtBQVduQjs7Ozs7OztHQU9HO0FBQ0gsTUFBTSxDQUFDLEtBQUssVUFBVSxlQUFlLENBQ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AgaWYgKG9wdGlvbnMub3ZlcndyaXRlKSB7XG4gICAgYXJncy5wdXNoKFwiLS1vdmVyd3JpdGVcIilcbiAgfVxuICBpZiAob3B0aW9ucy5jYXNrKSB7XG4gICAgYXJncy5wdXNoKFwiLS1jYXNrXCIpXG4gIH1cblxuICAvLyBicmV3IGlzIG5vdCB0aHJlYWQtc2FmZVxuICBleGVjYVN5bmMoYnJld1BhdGgsIGFyZ3MsIHsgc3RkaW86IFwiaW5oZXJpdFwiIH0pXG5cbiAgcmV0dXJuIHsgYmluRGlyIH1cbn1cbiJdfQ==","import which from \"which\"\n\nlet hasDnfCache: undefined | boolean = undefined\n\nexport function hasDnf(): boolean {\n if (process.platform !== \"linux\") {\n return false\n }\n if (hasDnfCache === undefined) {\n hasDnfCache = which.sync(\"dnf\", { nothrow: true }) !== null\n }\n\n return hasDnfCache\n}\n","import which from \"which\"\n\nlet isArchCache: undefined | boolean = undefined\n\nexport function isArch(): boolean {\n if (process.platform !== \"linux\") {\n return false\n }\n if (isArchCache === undefined) {\n // detect arch by checking if pacman exists\n isArchCache = which.sync(\"pacman\", { nothrow: true }) !== null\n }\n\n return isArchCache\n}\n","import which from \"which\"\n\nlet isUbuntuCache: undefined | boolean = undefined\n\nexport function isUbuntu(): boolean {\n if (process.platform !== \"linux\") {\n return false\n }\n if (isUbuntuCache === undefined) {\n const apt = \"apt-get\"\n isUbuntuCache = which.sync(apt, { nothrow: true }) !== null\n }\n\n return isUbuntuCache\n}\n","import { dirname } from \"path\"\nimport { addPath } from \"envosman\"\nimport { execaSync } from \"execa\"\nimport { pathExists } from \"path-exists\"\nimport which from \"which\"\nimport { rcOptions } from \"../cli-options.js\"\nimport type { InstallationInfo } from \"../utils/setup/setupBin.js\"\n\n/* eslint-disable require-atomic-updates */\nlet binDir: string | undefined\n\nexport async function setupChocolatey(\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n _version: string,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n _setupDir: string,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n _arch: string,\n): Promise<InstallationInfo | undefined> {\n if (process.platform !== \"win32\") {\n return undefined\n }\n\n if (typeof binDir === \"string\") {\n return { binDir }\n }\n\n const maybeBinDir = which.sync(\"choco\", { nothrow: true })\n if (maybeBinDir !== null) {\n binDir = dirname(maybeBinDir)\n return { binDir }\n }\n\n let powershell = \"powershell.exe\"\n const maybePowerShell = which.sync(`${process.env.SystemRoot}\\\\System32\\\\WindowsPowerShell\\\\v1.0\\\\powershell.exe`, {\n nothrow: true,\n })\n if (maybePowerShell !== null) {\n powershell = maybePowerShell\n }\n\n // https://docs.chocolatey.org/en-us/choco/setup#install-with-cmd.exe\n execaSync(\n powershell,\n [\n \"-NoProfile\",\n \"-InputFormat\",\n \"None\",\n \"-ExecutionPolicy\",\n \"Bypass\",\n \"-Command\",\n \"[System.Net.ServicePointManager]::SecurityProtocol = 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))\",\n ],\n { stdio: \"inherit\" },\n )\n\n const chocoPath = `${process.env.ALLUSERSPROFILE}\\\\chocolatey\\\\bin`\n await addPath(chocoPath, rcOptions)\n\n const maybeChoco = which.sync(\"choco\", { nothrow: true })\n if (maybeChoco !== null) {\n binDir = dirname(maybeChoco)\n } else {\n binDir = `${process.env.ChocolateyInstall ?? \"C:/ProgramData/chocolatey\"}/bin`\n }\n\n if (await pathExists(binDir)) {\n return { binDir }\n }\n return undefined\n}\n","/* eslint-disable require-atomic-updates */\nimport { info } from \"ci-log\"\nimport { addPath } from \"envosman\"\nimport { execaSync } from \"execa\"\nimport which from \"which\"\nimport { setupChocolatey } from \"../../chocolatey/chocolatey.js\"\nimport { rcOptions } from \"../../cli-options.js\"\nimport type { InstallationInfo } from \"./setupBin.js\"\n\nlet hasChoco = false\n\n/** A function that installs a package using choco */\nexport async function setupChocoPack(name: string, version?: string, args: string[] = []): Promise<InstallationInfo> {\n info(`Installing ${name} ${version ?? \"\"} via chocolatey`)\n\n if (!hasChoco || which.sync(\"choco\", { nothrow: true }) === null) {\n await setupChocolatey(\"\", \"\", process.arch)\n hasChoco = true\n }\n\n // https://github.com/jberezanski/ChocolateyPackages/issues/97#issuecomment-986825694\n const PATH = process.env.PATH\n const env = { ...process.env }\n env.TMP = undefined\n env.TEMP = undefined\n env.Path = undefined\n env.PATH = PATH\n\n if (version !== undefined && version !== \"\") {\n execaSync(\"choco\", [\"install\", \"-y\", name, `--version=${version}`, ...args], {\n env,\n extendEnv: false,\n stdio: \"inherit\",\n })\n } else {\n try {\n execaSync(\"choco\", [\"install\", \"-y\", name, ...args], { env, extendEnv: false, stdio: \"inherit\" })\n } catch (err) {\n // if the package requires a reboot, downgrade the error to a notice\n if ((err as Error).message.includes(\"exit code 3010\")) {\n info(`${name} might require a reboot for the completion of the installation.`)\n } else {\n throw err\n }\n }\n }\n\n const binDir = `${process.env.ChocolateyInstall ?? \"C:/ProgramData/chocolatey\"}/bin`\n await addPath(binDir, rcOptions)\n\n return { binDir }\n}\n","import { execRootSync } from \"admina\"\nimport { info, warning } from \"ci-log\"\nimport { execa } from \"execa\"\nimport type { InstallationInfo } from \"./setupBin.js\"\n\ntype DnfPackage = {\n name: string\n version?: string\n}\n\n/** A function that installs a package using dnf */\nexport async function setupDnfPack(packages: DnfPackage[]): Promise<InstallationInfo> {\n for (const { name, version } of packages) {\n info(`Installing ${name} ${version ?? \"\"} via dnf`)\n }\n\n const dnfArgs = await Promise.all(packages.map((pack) => getDnfArg(pack.name, pack.version)))\n execRootSync(\"dnf\", [\"-y\", \"install\", ...dnfArgs])\n\n return { binDir: \"/usr/bin/\" }\n}\n\nasync function getDnfArg(name: string, version: string | undefined) {\n if (version !== undefined && version !== \"\") {\n // check if name-version is available\n const { stdout } = await execa(\"dnf\", [\"search\", \"-q\", `${name}-${version}`])\n\n if (stdout.trim() !== \"\") {\n return `${name}-${version}`\n } else {\n // try with ${name}${version}\n // eslint-disable-next-line @typescript-eslint/no-shadow\n const { stdout } = await execa(\"dnf\", [\"search\", \"-q\", `${name}${version}`])\n if (stdout.trim() !== \"\") {\n return `${name}${version}`\n }\n\n warning(`Failed to install ${name} ${version} via dnf, trying without version`)\n }\n }\n return name\n}\n","import { tmpdir } from \"os\"\nimport { join } from \"path\"\nimport { execRootSync, isRoot } from \"admina\"\nimport { info, warning } from \"ci-log\"\nimport { execa, execaSync } from \"execa\"\nimport which from \"which\"\nimport type { InstallationInfo } from \"./setupBin.js\"\n\n/* eslint-disable require-atomic-updates */\nlet didUpdate: boolean = false\nlet didInit: boolean = false\n\n/** A function that installs a package using pacman */\nexport async function setupPacmanPack(name: string, version?: string, aur?: string): Promise<InstallationInfo> {\n info(`Installing ${name} ${version ?? \"\"} via pacman`)\n\n const pacman = \"pacman\"\n\n if (aur === \"yay\") {\n setupYay()\n }\n\n // yay can't run as root, so skip update\n if (!didUpdate && aur !== \"yay\") {\n execRootSync(pacman, [\"-Sy\", \"--noconfirm\"])\n didUpdate = true\n }\n\n // install base-devel\n if (!didInit && aur !== \"yay\") {\n execRootSync(pacman, [\"-S\", \"--noconfirm\", \"base-devel\"])\n didInit = true\n }\n\n const runInstall = (arg: string) => {\n if (aur === \"yay\") {\n // run yay as non-root to fix ERROR: Running makepkg as root is not allowed as it can cause permanent, catastrophic damage to your system.\n if (isRoot() && createdBuilderUser) {\n // Run yay as builder user\n return execRootSync(\"su\", [\"-\", \"builder\", \"-c\", `yay -S --noconfirm ${arg}`])\n } else {\n return execaSync(aur, [\"-S\", \"--noconfirm\", arg])\n }\n }\n return execRootSync(aur ?? pacman, [\"-S\", \"--noconfirm\", arg])\n }\n\n if (version !== undefined && version !== \"\") {\n // check if version is available\n const availableVersions = await availablePacmanVersions(pacman, name)\n if (availableVersions.includes(version)) {\n // try different version formats\n try {\n runInstall(`${name}=${version}`)\n } catch {\n runInstall(`${name}${version}`)\n }\n } else {\n // try without version\n info(`Failed to install ${name} ${version} via pacman, trying without version`)\n runInstall(name)\n }\n } else {\n // version not specified, install latest\n runInstall(name)\n }\n\n return { binDir: \"/usr/bin/\" }\n}\n\nconst pacmanSiVersionRegex = /Version\\s*:\\s*(.*)/g\n\n/** Query pacman for available versions */\nasync function availablePacmanVersions(pacman: string, name: string) {\n const availableVersions = []\n try {\n const { stdout } = await execa(pacman, [\"-Si\", name])\n\n for (const match of stdout.matchAll(pacmanSiVersionRegex)) {\n availableVersions.push(match[1])\n }\n } catch (err) {\n warning(`Failed to get available versions for ${name}: ${err}`)\n }\n return availableVersions\n}\n\nlet createdBuilderUser = false\n\nfunction setupYay() {\n if (which.sync(\"yay\", { nothrow: true }) === null) {\n try {\n // Install prerequisites\n execRootSync(\"pacman\", [\"-S\", \"--noconfirm\", \"base-devel\", \"git\"])\n\n const yayBuildDir = join(tmpdir(), \"yay\")\n\n execRootSync(\"mkdir\", [\"-p\", yayBuildDir])\n\n if (isRoot()) {\n // Create a non-root user to build yay\n warning(\"Creating a non-root user to build yay\")\n execRootSync(\"useradd\", [\"-m\", \"-G\", \"wheel\", \"builder\"])\n execRootSync(\"passwd\", [\"-d\", \"builder\"])\n execRootSync(\"chown\", [\"-R\", \"builder:builder\", yayBuildDir])\n execRootSync(\"bash\", [\"-c\", `echo \"builder ALL=(ALL) NOPASSWD: ALL\" >> /etc/sudoers`])\n createdBuilderUser = true\n\n // Clone the yay repository into a temporary directory\n execaSync(\"su\", [\"-\", \"builder\", \"-c\", `git clone https://aur.archlinux.org/yay.git ${yayBuildDir}`], {\n stdio: \"inherit\",\n })\n\n execaSync(\"su\", [\"-\", \"builder\", \"-c\", `cd ${yayBuildDir} && makepkg -si --noconfirm`], {\n stdio: \"inherit\",\n })\n } else {\n // Clone the yay repository into a temporary directory\n execaSync(\"git\", [\"clone\", \"https://aur.archlinux.org/yay.git\", yayBuildDir], {\n stdio: \"inherit\",\n cwd: tmpdir(),\n })\n\n // Build and install yay\n execaSync(\"makepkg\", [\"-si\", \"--noconfirm\"], {\n stdio: \"inherit\",\n cwd: yayBuildDir,\n })\n }\n\n // clean-up\n execaSync(\"rm\", [\"-rf\", yayBuildDir], { stdio: \"inherit\" })\n } catch (error) {\n throw new Error(`Failed to install yay: ${error}. Install yay manually and re-run the script.`)\n }\n }\n}\n","function e(e,a){return Object.keys(a).forEach((r=>{\"default\"===r||\"__esModule\"===r||e.hasOwnProperty(r)||Object.defineProperty(e,r,{enumerable:!0,get(){return a[r]}})})),e}function a(e,a,r,s){Object.defineProperty(e,a,{get:r,set:s,enumerable:!0,configurable:!0})}function r(e,a=!0){return a?u(e):u(e,x(e))}function s(e){return E(e).replace(RegExp(y(N)+\"$\"),\"\")}function t(e,a=\".exe\",r=\"\"){return\"win32\"===process.platform?`${e}${a}`:`${e}${r}`}function n(e,a){const r=x(e),s=`${a}${u(e,r)}${r}`;return h(l(e),s)}function i(e,a){const r=x(e),s=`${u(e,r)}${a}${r}`;return h(l(e),s)}function o(e,a=\".cmd\",r=\".sh\"){return\"win32\"===process.platform?`${e}${a}`:`${e}${r}`}function m(e){return\"win32\"===process.platform?e:\"./\"+e}function c(e){const a=x(e).length;return e.slice(0,-a)}function d(e,a){return z(e,a)}function f(e,a){const r=g(a,e);return!(!r||\"..\"===r||r.startsWith(\"..\"+N)||r===w(e))}import{basename as u,delimiter as p,dirname as l,extname as x,format as v,isAbsolute as $,join as h,normalize as E,parse as P,posix as b,relative as g,resolve as w,sep as N,toNamespacedPath as S,win32 as j}from\"path\";import y from\"escape-string-regexp\";import z from\"replace-ext\";var O={},R={};a(R,\"name\",(()=>r));var A={};a(A,\"normalizeTrim\",(()=>s));var I={};a(I,\"addExeExt\",(()=>t));var T={};a(T,\"addNamePrefix\",(()=>n));var _={};a(_,\"addNameSuffix\",(()=>i));var k={};a(k,\"addShExt\",(()=>o));var M={};a(M,\"addShRelativePrefix\",(()=>m));var W={};a(W,\"removeExt\",(()=>c));var q={};a(q,\"replaceExt\",(()=>d));var B={};a(B,\"isPathInside\",(()=>f)),e(O,R),e(O,A),e(O,I),e(O,T),e(O,_),e(O,k),e(O,M),e(O,W),e(O,q),e(O,B);export{u as basename,p as delimiter,l as dirname,x as extname,v as format,$ as isAbsolute,h as join,E as normalize,P as parse,b as posix,g as relative,w as resolve,N as sep,S as toNamespacedPath,j as win32,r as name,s as normalizeTrim,t as addExeExt,n as addNamePrefix,i as addNameSuffix,o as addShExt,m as addShRelativePrefix,c as removeExt,d as replaceExt,f as isPathInside};\n//# sourceMappingURL=index.node.mjs.map\n","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __importDefault = (this && this.__importDefault) || function (mod) {\n return (mod && mod.__esModule) ? mod : { \"default\": mod };\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.evaluateVersions = exports.isExplicitVersion = exports.findFromManifest = exports.getManifestFromRepo = exports.findAllVersions = exports.find = exports.cacheFile = exports.cacheDir = exports.extractZip = exports.extractXar = exports.extractTar = exports.extract7z = exports.downloadTool = exports.HTTPError = void 0;\nconst core = __importStar(require(\"@actions/core\"));\nconst io = __importStar(require(\"@actions/io\"));\nconst fs = __importStar(require(\"fs\"));\nconst mm = __importStar(require(\"./manifest\"));\nconst os = __importStar(require(\"os\"));\nconst path = __importStar(require(\"path\"));\nconst httpm = __importStar(require(\"@actions/http-client\"));\nconst semver = __importStar(require(\"semver\"));\nconst stream = __importStar(require(\"stream\"));\nconst util = __importStar(require(\"util\"));\nconst assert_1 = require(\"assert\");\nconst v4_1 = __importDefault(require(\"uuid/v4\"));\nconst exec_1 = require(\"@actions/exec/lib/exec\");\nconst retry_helper_1 = require(\"./retry-helper\");\nclass HTTPError extends Error {\n constructor(httpStatusCode) {\n super(`Unexpected HTTP response: ${httpStatusCode}`);\n this.httpStatusCode = httpStatusCode;\n Object.setPrototypeOf(this, new.target.prototype);\n }\n}\nexports.HTTPError = HTTPError;\nconst IS_WINDOWS = process.platform === 'win32';\nconst IS_MAC = process.platform === 'darwin';\nconst userAgent = 'actions/tool-cache';\n/**\n * Download a tool from an url and stream it into a file\n *\n * @param url url of tool to download\n * @param dest path to download tool\n * @param auth authorization header\n * @param headers other headers\n * @returns path to downloaded tool\n */\nfunction downloadTool(url, dest, auth, headers) {\n return __awaiter(this, void 0, void 0, function* () {\n dest = dest || path.join(_getTempDirectory(), v4_1.default());\n yield io.mkdirP(path.dirname(dest));\n core.debug(`Downloading ${url}`);\n core.debug(`Destination ${dest}`);\n const maxAttempts = 3;\n const minSeconds = _getGlobal('TEST_DOWNLOAD_TOOL_RETRY_MIN_SECONDS', 10);\n const maxSeconds = _getGlobal('TEST_DOWNLOAD_TOOL_RETRY_MAX_SECONDS', 20);\n const retryHelper = new retry_helper_1.RetryHelper(maxAttempts, minSeconds, maxSeconds);\n return yield retryHelper.execute(() => __awaiter(this, void 0, void 0, function* () {\n return yield downloadToolAttempt(url, dest || '', auth, headers);\n }), (err) => {\n if (err instanceof HTTPError && err.httpStatusCode) {\n // Don't retry anything less than 500, except 408 Request Timeout and 429 Too Many Requests\n if (err.httpStatusCode < 500 &&\n err.httpStatusCode !== 408 &&\n err.httpStatusCode !== 429) {\n return false;\n }\n }\n // Otherwise retry\n return true;\n });\n });\n}\nexports.downloadTool = downloadTool;\nfunction downloadToolAttempt(url, dest, auth, headers) {\n return __awaiter(this, void 0, void 0, function* () {\n if (fs.existsSync(dest)) {\n throw new Error(`Destination file path ${dest} already exists`);\n }\n // Get the response headers\n const http = new httpm.HttpClient(userAgent, [], {\n allowRetries: false\n });\n if (auth) {\n core.debug('set auth');\n if (headers === undefined) {\n headers = {};\n }\n headers.authorization = auth;\n }\n const response = yield http.get(url, headers);\n if (response.message.statusCode !== 200) {\n const err = new HTTPError(response.message.statusCode);\n core.debug(`Failed to download from \"${url}\". Code(${response.message.statusCode}) Message(${response.message.statusMessage})`);\n throw err;\n }\n // Download the response body\n const pipeline = util.promisify(stream.pipeline);\n const responseMessageFactory = _getGlobal('TEST_DOWNLOAD_TOOL_RESPONSE_MESSAGE_FACTORY', () => response.message);\n const readStream = responseMessageFactory();\n let succeeded = false;\n try {\n yield pipeline(readStream, fs.createWriteStream(dest));\n core.debug('download complete');\n succeeded = true;\n return dest;\n }\n finally {\n // Error, delete dest before retry\n if (!succeeded) {\n core.debug('download failed');\n try {\n yield io.rmRF(dest);\n }\n catch (err) {\n core.debug(`Failed to delete '${dest}'. ${err.message}`);\n }\n }\n }\n });\n}\n/**\n * Extract a .7z file\n *\n * @param file path to the .7z file\n * @param dest destination directory. Optional.\n * @param _7zPath path to 7zr.exe. Optional, for long path support. Most .7z archives do not have this\n * problem. If your .7z archive contains very long paths, you can pass the path to 7zr.exe which will\n * gracefully handle long paths. By default 7zdec.exe is used because it is a very small program and is\n * bundled with the tool lib. However it does not support long paths. 7zr.exe is the reduced command line\n * interface, it is smaller than the full command line interface, and it does support long paths. At the\n * time of this writing, it is freely available from the LZMA SDK that is available on the 7zip website.\n * Be sure to check the current license agreement. If 7zr.exe is bundled with your action, then the path\n * to 7zr.exe can be pass to this function.\n * @returns path to the destination directory\n */\nfunction extract7z(file, dest, _7zPath) {\n return __awaiter(this, void 0, void 0, function* () {\n assert_1.ok(IS_WINDOWS, 'extract7z() not supported on current OS');\n assert_1.ok(file, 'parameter \"file\" is required');\n dest = yield _createExtractFolder(dest);\n const originalCwd = process.cwd();\n process.chdir(dest);\n if (_7zPath) {\n try {\n const logLevel = core.isDebug() ? '-bb1' : '-bb0';\n const args = [\n 'x',\n logLevel,\n '-bd',\n '-sccUTF-8',\n file\n ];\n const options = {\n silent: true\n };\n yield exec_1.exec(`\"${_7zPath}\"`, args, options);\n }\n finally {\n process.chdir(originalCwd);\n }\n }\n else {\n const escapedScript = path\n .join(__dirname, '..', 'scripts', 'Invoke-7zdec.ps1')\n .replace(/'/g, \"''\")\n .replace(/\"|\\n|\\r/g, ''); // double-up single quotes, remove double quotes and newlines\n const escapedFile = file.replace(/'/g, \"''\").replace(/\"|\\n|\\r/g, '');\n const escapedTarget = dest.replace(/'/g, \"''\").replace(/\"|\\n|\\r/g, '');\n const command = `& '${escapedScript}' -Source '${escapedFile}' -Target '${escapedTarget}'`;\n const args = [\n '-NoLogo',\n '-Sta',\n '-NoProfile',\n '-NonInteractive',\n '-ExecutionPolicy',\n 'Unrestricted',\n '-Command',\n command\n ];\n const options = {\n silent: true\n };\n try {\n const powershellPath = yield io.which('powershell', true);\n yield exec_1.exec(`\"${powershellPath}\"`, args, options);\n }\n finally {\n process.chdir(originalCwd);\n }\n }\n return dest;\n });\n}\nexports.extract7z = extract7z;\n/**\n * Extract a compressed tar archive\n *\n * @param file path to the tar\n * @param dest destination directory. Optional.\n * @param flags flags for the tar command to use for extraction. Defaults to 'xz' (extracting gzipped tars). Optional.\n * @returns path to the destination directory\n */\nfunction extractTar(file, dest, flags = 'xz') {\n return __awaiter(this, void 0, void 0, function* () {\n if (!file) {\n throw new Error(\"parameter 'file' is required\");\n }\n // Create dest\n dest = yield _createExtractFolder(dest);\n // Determine whether GNU tar\n core.debug('Checking tar --version');\n let versionOutput = '';\n yield exec_1.exec('tar --version', [], {\n ignoreReturnCode: true,\n silent: true,\n listeners: {\n stdout: (data) => (versionOutput += data.toString()),\n stderr: (data) => (versionOutput += data.toString())\n }\n });\n core.debug(versionOutput.trim());\n const isGnuTar = versionOutput.toUpperCase().includes('GNU TAR');\n // Initialize args\n let args;\n if (flags instanceof Array) {\n args = flags;\n }\n else {\n args = [flags];\n }\n if (core.isDebug() && !flags.includes('v')) {\n args.push('-v');\n }\n let destArg = dest;\n let fileArg = file;\n if (IS_WINDOWS && isGnuTar) {\n args.push('--force-local');\n destArg = dest.replace(/\\\\/g, '/');\n // Technically only the dest needs to have `/` but for aesthetic consistency\n // convert slashes in the file arg too.\n fileArg = file.replace(/\\\\/g, '/');\n }\n if (isGnuTar) {\n // Suppress warnings when using GNU tar to extract archives created by BSD tar\n args.push('--warning=no-unknown-keyword');\n args.push('--overwrite');\n }\n args.push('-C', destArg, '-f', fileArg);\n yield exec_1.exec(`tar`, args);\n return dest;\n });\n}\nexports.extractTar = extractTar;\n/**\n * Extract a xar compatible archive\n *\n * @param file path to the archive\n * @param dest destination directory. Optional.\n * @param flags flags for the xar. Optional.\n * @returns path to the destination directory\n */\nfunction extractXar(file, dest, flags = []) {\n return __awaiter(this, void 0, void 0, function* () {\n assert_1.ok(IS_MAC, 'extractXar() not supported on current OS');\n assert_1.ok(file, 'parameter \"file\" is required');\n dest = yield _createExtractFolder(dest);\n let args;\n if (flags instanceof Array) {\n args = flags;\n }\n else {\n args = [flags];\n }\n args.push('-x', '-C', dest, '-f', file);\n if (core.isDebug()) {\n args.push('-v');\n }\n const xarPath = yield io.which('xar', true);\n yield exec_1.exec(`\"${xarPath}\"`, _unique(args));\n return dest;\n });\n}\nexports.extractXar = extractXar;\n/**\n * Extract a zip\n *\n * @param file path to the zip\n * @param dest destination directory. Optional.\n * @returns path to the destination directory\n */\nfunction extractZip(file, dest) {\n return __awaiter(this, void 0, void 0, function* () {\n if (!file) {\n throw new Error(\"parameter 'file' is required\");\n }\n dest = yield _createExtractFolder(dest);\n if (IS_WINDOWS) {\n yield extractZipWin(file, dest);\n }\n else {\n yield extractZipNix(file, dest);\n }\n return dest;\n });\n}\nexports.extractZip = extractZip;\nfunction extractZipWin(file, dest) {\n return __awaiter(this, void 0, void 0, function* () {\n // build the powershell command\n const escapedFile = file.replace(/'/g, \"''\").replace(/\"|\\n|\\r/g, ''); // double-up single quotes, remove double quotes and newlines\n const escapedDest = dest.replace(/'/g, \"''\").replace(/\"|\\n|\\r/g, '');\n const pwshPath = yield io.which('pwsh', false);\n //To match the file overwrite behavior on nix systems, we use the overwrite = true flag for ExtractToDirectory\n //and the -Force flag for Expand-Archive as a fallback\n if (pwshPath) {\n //attempt to use pwsh with ExtractToDirectory, if this fails attempt Expand-Archive\n const pwshCommand = [\n `$ErrorActionPreference = 'Stop' ;`,\n `try { Add-Type -AssemblyName System.IO.Compression.ZipFile } catch { } ;`,\n `try { [System.IO.Compression.ZipFile]::ExtractToDirectory('${escapedFile}', '${escapedDest}', $true) }`,\n `catch { if (($_.Exception.GetType().FullName -eq 'System.Management.Automation.MethodException') -or ($_.Exception.GetType().FullName -eq 'System.Management.Automation.RuntimeException') ){ Expand-Archive -LiteralPath '${escapedFile}' -DestinationPath '${escapedDest}' -Force } else { throw $_ } } ;`\n ].join(' ');\n const args = [\n '-NoLogo',\n '-NoProfile',\n '-NonInteractive',\n '-ExecutionPolicy',\n 'Unrestricted',\n '-Command',\n pwshCommand\n ];\n core.debug(`Using pwsh at path: ${pwshPath}`);\n yield exec_1.exec(`\"${pwshPath}\"`, args);\n }\n else {\n const powershellCommand = [\n `$ErrorActionPreference = 'Stop' ;`,\n `try { Add-Type -AssemblyName System.IO.Compression.FileSystem } catch { } ;`,\n `if ((Get-Command -Name Expand-Archive -Module Microsoft.PowerShell.Archive -ErrorAction Ignore)) { Expand-Archive -LiteralPath '${escapedFile}' -DestinationPath '${escapedDest}' -Force }`,\n `else {[System.IO.Compression.ZipFile]::ExtractToDirectory('${escapedFile}', '${escapedDest}', $true) }`\n ].join(' ');\n const args = [\n '-NoLogo',\n '-Sta',\n '-NoProfile',\n '-NonInteractive',\n '-ExecutionPolicy',\n 'Unrestricted',\n '-Command',\n powershellCommand\n ];\n const powershellPath = yield io.which('powershell', true);\n core.debug(`Using powershell at path: ${powershellPath}`);\n yield exec_1.exec(`\"${powershellPath}\"`, args);\n }\n });\n}\nfunction extractZipNix(file, dest) {\n return __awaiter(this, void 0, void 0, function* () {\n const unzipPath = yield io.which('unzip', true);\n const args = [file];\n if (!core.isDebug()) {\n args.unshift('-q');\n }\n args.unshift('-o'); //overwrite with -o, otherwise a prompt is shown which freezes the run\n yield exec_1.exec(`\"${unzipPath}\"`, args, { cwd: dest });\n });\n}\n/**\n * Caches a directory and installs it into the tool cacheDir\n *\n * @param sourceDir the directory to cache into tools\n * @param tool tool name\n * @param version version of the tool. semver format\n * @param arch architecture of the tool. Optional. Defaults to machine architecture\n */\nfunction cacheDir(sourceDir, tool, version, arch) {\n return __awaiter(this, void 0, void 0, function* () {\n version = semver.clean(version) || version;\n arch = arch || os.arch();\n core.debug(`Caching tool ${tool} ${version} ${arch}`);\n core.debug(`source dir: ${sourceDir}`);\n if (!fs.statSync(sourceDir).isDirectory()) {\n throw new Error('sourceDir is not a directory');\n }\n // Create the tool dir\n const destPath = yield _createToolPath(tool, version, arch);\n // copy each child item. do not move. move can fail on Windows\n // due to anti-virus software having an open handle on a file.\n for (const itemName of fs.readdirSync(sourceDir)) {\n const s = path.join(sourceDir, itemName);\n yield io.cp(s, destPath, { recursive: true });\n }\n // write .complete\n _completeToolPath(tool, version, arch);\n return destPath;\n });\n}\nexports.cacheDir = cacheDir;\n/**\n * Caches a downloaded file (GUID) and installs it\n * into the tool cache with a given targetName\n *\n * @param sourceFile the file to cache into tools. Typically a result of downloadTool which is a guid.\n * @param targetFile the name of the file name in the tools directory\n * @param tool tool name\n * @param version version of the tool. semver format\n * @param arch architecture of the tool. Optional. Defaults to machine architecture\n */\nfunction cacheFile(sourceFile, targetFile, tool, version, arch) {\n return __awaiter(this, void 0, void 0, function* () {\n version = semver.clean(version) || version;\n arch = arch || os.arch();\n core.debug(`Caching tool ${tool} ${version} ${arch}`);\n core.debug(`source file: ${sourceFile}`);\n if (!fs.statSync(sourceFile).isFile()) {\n throw new Error('sourceFile is not a file');\n }\n // create the tool dir\n const destFolder = yield _createToolPath(tool, version, arch);\n // copy instead of move. move can fail on Windows due to\n // anti-virus software having an open handle on a file.\n const destPath = path.join(destFolder, targetFile);\n core.debug(`destination file ${destPath}`);\n yield io.cp(sourceFile, destPath);\n // write .complete\n _completeToolPath(tool, version, arch);\n return destFolder;\n });\n}\nexports.cacheFile = cacheFile;\n/**\n * Finds the path to a tool version in the local installed tool cache\n *\n * @param toolName name of the tool\n * @param versionSpec version of the tool\n * @param arch optional arch. defaults to arch of computer\n */\nfunction find(toolName, versionSpec, arch) {\n if (!toolName) {\n throw new Error('toolName parameter is required');\n }\n if (!versionSpec) {\n throw new Error('versionSpec parameter is required');\n }\n arch = arch || os.arch();\n // attempt to resolve an explicit version\n if (!isExplicitVersion(versionSpec)) {\n const localVersions = findAllVersions(toolName, arch);\n const match = evaluateVersions(localVersions, versionSpec);\n versionSpec = match;\n }\n // check for the explicit version in the cache\n let toolPath = '';\n if (versionSpec) {\n versionSpec = semver.clean(versionSpec) || '';\n const cachePath = path.join(_getCacheDirectory(), toolName, versionSpec, arch);\n core.debug(`checking cache: ${cachePath}`);\n if (fs.existsSync(cachePath) && fs.existsSync(`${cachePath}.complete`)) {\n core.debug(`Found tool in cache ${toolName} ${versionSpec} ${arch}`);\n toolPath = cachePath;\n }\n else {\n core.debug('not found');\n }\n }\n return toolPath;\n}\nexports.find = find;\n/**\n * Finds the paths to all versions of a tool that are installed in the local tool cache\n *\n * @param toolName name of the tool\n * @param arch optional arch. defaults to arch of computer\n */\nfunction findAllVersions(toolName, arch) {\n const versions = [];\n arch = arch || os.arch();\n const toolPath = path.join(_getCacheDirectory(), toolName);\n if (fs.existsSync(toolPath)) {\n const children = fs.readdirSync(toolPath);\n for (const child of children) {\n if (isExplicitVersion(child)) {\n const fullPath = path.join(toolPath, child, arch || '');\n if (fs.existsSync(fullPath) && fs.existsSync(`${fullPath}.complete`)) {\n versions.push(child);\n }\n }\n }\n }\n return versions;\n}\nexports.findAllVersions = findAllVersions;\nfunction getManifestFromRepo(owner, repo, auth, branch = 'master') {\n return __awaiter(this, void 0, void 0, function* () {\n let releases = [];\n const treeUrl = `https://api.github.com/repos/${owner}/${repo}/git/trees/${branch}`;\n const http = new httpm.HttpClient('tool-cache');\n const headers = {};\n if (auth) {\n core.debug('set auth');\n headers.authorization = auth;\n }\n const response = yield http.getJson(treeUrl, headers);\n if (!response.result) {\n return releases;\n }\n let manifestUrl = '';\n for (const item of response.result.tree) {\n if (item.path === 'versions-manifest.json') {\n manifestUrl = item.url;\n break;\n }\n }\n headers['accept'] = 'application/vnd.github.VERSION.raw';\n let versionsRaw = yield (yield http.get(manifestUrl, headers)).readBody();\n if (versionsRaw) {\n // shouldn't be needed but protects against invalid json saved with BOM\n versionsRaw = versionsRaw.replace(/^\\uFEFF/, '');\n try {\n releases = JSON.parse(versionsRaw);\n }\n catch (_a) {\n core.debug('Invalid json');\n }\n }\n return releases;\n });\n}\nexports.getManifestFromRepo = getManifestFromRepo;\nfunction findFromManifest(versionSpec, stable, manifest, archFilter = os.arch()) {\n return __awaiter(this, void 0, void 0, function* () {\n // wrap the internal impl\n const match = yield mm._findMatch(versionSpec, stable, manifest, archFilter);\n return match;\n });\n}\nexports.findFromManifest = findFromManifest;\nfunction _createExtractFolder(dest) {\n return __awaiter(this, void 0, void 0, function* () {\n if (!dest) {\n // create a temp dir\n dest = path.join(_getTempDirectory(), v4_1.default());\n }\n yield io.mkdirP(dest);\n return dest;\n });\n}\nfunction _createToolPath(tool, version, arch) {\n return __awaiter(this, void 0, void 0, function* () {\n const folderPath = path.join(_getCacheDirectory(), tool, semver.clean(version) || version, arch || '');\n core.debug(`destination ${folderPath}`);\n const markerPath = `${folderPath}.complete`;\n yield io.rmRF(folderPath);\n yield io.rmRF(markerPath);\n yield io.mkdirP(folderPath);\n return folderPath;\n });\n}\nfunction _completeToolPath(tool, version, arch) {\n const folderPath = path.join(_getCacheDirectory(), tool, semver.clean(version) || version, arch || '');\n const markerPath = `${folderPath}.complete`;\n fs.writeFileSync(markerPath, '');\n core.debug('finished caching tool');\n}\n/**\n * Check if version string is explicit\n *\n * @param versionSpec version string to check\n */\nfunction isExplicitVersion(versionSpec) {\n const c = semver.clean(versionSpec) || '';\n core.debug(`isExplicit: ${c}`);\n const valid = semver.valid(c) != null;\n core.debug(`explicit? ${valid}`);\n return valid;\n}\nexports.isExplicitVersion = isExplicitVersion;\n/**\n * Get the highest satisfiying semantic version in `versions` which satisfies `versionSpec`\n *\n * @param versions array of versions to evaluate\n * @param versionSpec semantic version spec to satisfy\n */\nfunction evaluateVersions(versions, versionSpec) {\n let version = '';\n core.debug(`evaluating ${versions.length} versions`);\n versions = versions.sort((a, b) => {\n if (semver.gt(a, b)) {\n return 1;\n }\n return -1;\n });\n for (let i = versions.length - 1; i >= 0; i--) {\n const potential = versions[i];\n const satisfied = semver.satisfies(potential, versionSpec);\n if (satisfied) {\n version = potential;\n break;\n }\n }\n if (version) {\n core.debug(`matched: ${version}`);\n }\n else {\n core.debug('match not found');\n }\n return version;\n}\nexports.evaluateVersions = evaluateVersions;\n/**\n * Gets RUNNER_TOOL_CACHE\n */\nfunction _getCacheDirectory() {\n const cacheDirectory = process.env['RUNNER_TOOL_CACHE'] || '';\n assert_1.ok(cacheDirectory, 'Expected RUNNER_TOOL_CACHE to be defined');\n return cacheDirectory;\n}\n/**\n * Gets RUNNER_TEMP\n */\nfunction _getTempDirectory() {\n const tempDirectory = process.env['RUNNER_TEMP'] || '';\n assert_1.ok(tempDirectory, 'Expected RUNNER_TEMP to be defined');\n return tempDirectory;\n}\n/**\n * Gets a global variable\n */\nfunction _getGlobal(key, defaultValue) {\n /* eslint-disable @typescript-eslint/no-explicit-any */\n const value = global[key];\n /* eslint-enable @typescript-eslint/no-explicit-any */\n return value !== undefined ? value : defaultValue;\n}\n/**\n * Returns an array of unique values.\n * @param values Values to make unique.\n */\nfunction _unique(values) {\n return Array.from(new Set(values));\n}\n//# sourceMappingURL=tool-cache.js.map","'use strict';\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.retryAsPromised = exports.TimeoutError = void 0;\nclass TimeoutError extends Error {\n constructor(message, previousError) {\n super(message);\n this.name = \"TimeoutError\";\n this.previous = previousError;\n }\n}\nexports.TimeoutError = TimeoutError;\nfunction matches(match, err) {\n if (typeof match === 'function') {\n try {\n if (err instanceof match)\n return true;\n }\n catch (_) {\n return !!match(err);\n }\n }\n if (match === err.toString())\n return true;\n if (match === err.message)\n return true;\n return match instanceof RegExp\n && (match.test(err.message) || match.test(err.toString()));\n}\nfunction retryAsPromised(callback, optionsInput) {\n if (!callback || !optionsInput) {\n throw new Error('retry-as-promised must be passed a callback and a options set');\n }\n optionsInput = (typeof optionsInput === \"number\" ? { max: optionsInput } : optionsInput);\n const options = {\n $current: \"$current\" in optionsInput ? optionsInput.$current : 1,\n max: optionsInput.max,\n timeout: optionsInput.timeout || undefined,\n match: optionsInput.match ? Array.isArray(optionsInput.match) ? optionsInput.match : [optionsInput.match] : [],\n backoffBase: optionsInput.backoffBase === undefined ? 100 : optionsInput.backoffBase,\n backoffExponent: optionsInput.backoffExponent || 1.1,\n report: optionsInput.report,\n name: optionsInput.name || callback.name || 'unknown'\n };\n if (options.match && !Array.isArray(options.match))\n options.match = [options.match];\n if (options.report)\n options.report('Trying ' + options.name + ' #' + options.$current + ' at ' + new Date().toLocaleTimeString(), options);\n return new Promise(function (resolve, reject) {\n let timeout;\n let backoffTimeout;\n let lastError;\n if (options.timeout) {\n timeout = setTimeout(function () {\n if (backoffTimeout)\n clearTimeout(backoffTimeout);\n reject(new TimeoutError(options.name + ' timed out', lastError));\n }, options.timeout);\n }\n Promise.resolve(callback({ current: options.$current }))\n .then(resolve)\n .then(function () {\n if (timeout)\n clearTimeout(timeout);\n if (backoffTimeout)\n clearTimeout(backoffTimeout);\n })\n .catch(function (err) {\n if (timeout)\n clearTimeout(timeout);\n if (backoffTimeout)\n clearTimeout(backoffTimeout);\n lastError = err;\n if (options.report)\n options.report((err && err.toString()) || err, options, err);\n // Should not retry if max has been reached\n var shouldRetry = options.$current < options.max;\n if (!shouldRetry)\n return reject(err);\n shouldRetry = options.match.length === 0 || options.match.some(function (match) {\n return matches(match, err);\n });\n if (!shouldRetry)\n return reject(err);\n var retryDelay = options.backoffBase * Math.pow(options.backoffExponent, options.$current - 1);\n // Do some accounting\n options.$current++;\n if (options.report)\n options.report(`Retrying ${options.name} (${options.$current})`, options);\n if (retryDelay) {\n // Use backoff function to ease retry rate\n if (options.report)\n options.report(`Delaying retry of ${options.name} by ${retryDelay}`, options);\n backoffTimeout = setTimeout(function () {\n retryAsPromised(callback, options)\n .then(resolve)\n .catch(reject);\n }, retryDelay);\n }\n else {\n retryAsPromised(callback, options)\n .then(resolve)\n .catch(reject);\n }\n });\n });\n}\nexports.retryAsPromised = retryAsPromised;\n;\nexports.default = retryAsPromised;\n","import { installAptPack } from \"setup-apt\"\nimport { installBrewPack } from \"setup-brew\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport function setupSevenZip(version: string, _setupDir: string, _arch: string) {\n switch (process.platform) {\n case \"win32\": {\n return setupChocoPack(\"7zip\", version)\n }\n case \"darwin\": {\n return installBrewPack(\"p7zip\", version)\n }\n case \"linux\": {\n if (isArch()) {\n return setupPacmanPack(\"p7zip\", version)\n } else if (hasDnf()) {\n return setupDnfPack([\n { name: \"p7zip\", version },\n { name: \"p7zip-plugins\", version },\n ])\n } else if (isUbuntu()) {\n return installAptPack([{ name: \"p7zip-full\", version }])\n }\n throw new Error(\"Unsupported linux distribution\")\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n}\n","import { mkdirP } from \"@actions/io\"\nimport { grantUserWriteAccess } from \"admina\"\nimport { info, warning } from \"ci-log\"\nimport { execa } from \"execa\"\nimport { installAptPack } from \"setup-apt\"\nimport which from \"which\"\nimport { setupSevenZip } from \"../../sevenzip/sevenzip.js\"\nimport { hasDnf } from \"../env/hasDnf.js\"\nimport { isArch } from \"../env/isArch.js\"\nimport { isUbuntu } from \"../env/isUbuntu.js\"\nimport { setupDnfPack } from \"./setupDnfPack.js\"\nimport { setupPacmanPack } from \"./setupPacmanPack.js\"\nexport { extractTar, extractXar } from \"@actions/tool-cache\"\n\nexport enum ArchiveType {\n Tar = 0,\n TarGz = 1,\n TarXz = 2,\n Zip = 3,\n SevenZip = 4,\n}\n\nexport function getArchiveType(file: string): ArchiveType {\n const ext = file.split(\".\").pop()\n\n if (ext === \"tar\") {\n return ArchiveType.Tar\n }\n\n if (ext === \"gz\" || ext === \"tgz\") {\n return ArchiveType.TarGz\n }\n\n if (ext === \"xz\" || ext === \"txz\") {\n return ArchiveType.TarXz\n }\n\n if (ext === \"zip\") {\n return ArchiveType.Zip\n }\n\n if (ext === \"7z\" || ext === \"exe\") {\n return ArchiveType.SevenZip\n }\n\n // default to 7z\n warning(`Unknown archive type: ${ext}. Defaulting to 7z`)\n return ArchiveType.SevenZip\n}\n\nexport function getExtractFunction(archiveType: ArchiveType) {\n switch (archiveType) {\n case ArchiveType.Tar:\n case ArchiveType.TarGz:\n return extractTarByExe\n case ArchiveType.TarXz:\n return extractTarByExe\n case ArchiveType.Zip:\n return extractZip\n default:\n return extract7Zip\n }\n}\n\nlet sevenZip: string | undefined\n\n/// Extract 7z using 7z\nexport async function extract7Zip(file: string, dest: string) {\n await execa(await getSevenZip(), [\"x\", file, `-o${dest}`, \"-y\"], { stdio: \"inherit\" })\n await grantUserWriteAccess(dest)\n return dest\n}\n\n/// install 7z if needed\nasync function getSevenZip() {\n if (sevenZip === undefined) {\n if (which.sync(\"7z\", { nothrow: true }) === null) {\n await setupSevenZip(\"\", \"\", process.arch)\n }\n // eslint-disable-next-line require-atomic-updates\n sevenZip = \"7z\"\n }\n return sevenZip\n}\n\n/// Extract Exe using 7z\nexport function extractExe(file: string, dest: string) {\n return extract7Zip(file, dest)\n}\n\n/// Extract Zip using unzip or 7z\nexport async function extractZip(file: string, dest: string) {\n // prefer 7z if available (faster especially on Windows)\n if (which.sync(\"7z\", { nothrow: true }) !== null) {\n return extract7Zip(file, dest)\n }\n\n // if unzip is available use it (usually available on posix systems)\n if (which.sync(\"unzip\", { nothrow: true }) !== null) {\n await execa(\"unzip\", [\"-q\", file, \"-d\", dest], { stdio: \"inherit\" })\n await grantUserWriteAccess(dest)\n return dest\n }\n\n // fallback to 7z (will install 7z if needed)\n return extract7Zip(file, dest)\n}\n\nexport async function extractTarByExe(file: string, dest: string, stripComponents: number = 0, flags: string[] = []) {\n await installTarDependencies(getArchiveType(file))\n\n try {\n await mkdirP(dest)\n } catch {\n // ignore\n }\n\n // TODO windows fails to create symlinks\n // https://github.com/heroku/heroku-slugs/issues/3\n\n try {\n await execa(\"tar\", [\"xf\", file, \"-C\", dest, `--strip-components=${stripComponents}`, ...flags], {\n stdio: \"inherit\",\n })\n } catch (e) {\n if (process.platform === \"win32\" && (e as Error).message.includes(\"Can't create '\\\\\\\\?\\\\C:\")) {\n warning(`Failed to extract symlink ${file} to ${dest}. Ignoring this symlink.`)\n }\n }\n\n await grantUserWriteAccess(dest)\n return dest\n}\n\nasync function installTarDependencies(archiveType: ArchiveType) {\n info(\"Installing tar extraction dependencies\")\n\n switch (archiveType) {\n case ArchiveType.TarGz: {\n if (process.platform === \"linux\") {\n if (isArch()) {\n await setupPacmanPack(\"gzip\")\n await setupPacmanPack(\"tar\")\n } else if (hasDnf()) {\n await setupDnfPack([{ name: \"gzip\" }, { name: \"tar\" }])\n } else if (isUbuntu()) {\n await installAptPack([{ name: \"gzip\" }, { name: \"tar\" }])\n }\n }\n break\n }\n case ArchiveType.TarXz: {\n if (process.platform === \"linux\") {\n if (isArch()) {\n await setupPacmanPack(\"xz\")\n await setupPacmanPack(\"tar\")\n } else if (hasDnf()) {\n await setupDnfPack([{ name: \"xz\" }, { name: \"tar\" }])\n } else if (isUbuntu()) {\n await installAptPack([{ name: \"xz-utils\" }, { name: \"tar\" }])\n }\n }\n break\n }\n default:\n throw new Error(`Unsupported archive type: ${archiveType} for tar extraction`)\n }\n}\n","import { tmpdir } from \"os\"\nimport { basename, join } from \"path\"\nimport { cacheDir, downloadTool, find } from \"@actions/tool-cache\"\nimport ciInfo from \"ci-info\"\nconst { GITHUB_ACTIONS } = ciInfo\nimport { info, warning } from \"ci-log\"\nimport { addPath } from \"envosman\"\nimport { chmod } from \"fs/promises\"\nimport { pathExists } from \"path-exists\"\nimport retry from \"retry-as-promised\"\nimport { maybeGetInput, rcOptions } from \"../../cli-options.js\"\nimport { getArchiveType, getExtractFunction } from \"./extract.js\"\n\n/** A type that describes a package */\nexport type PackageInfo = {\n /** Url to download the package */\n url: string\n /** The top folder name once it is extracted. It can be `\"\"` if there is no top folder */\n extractedFolderName: string\n /** The relative directory in which the binary is located. It can be `\"\"` if the exe is in the top folder */\n binRelativeDir: string\n /** The main binary file. */\n binFileName: string\n /** The function to extract the downloaded archive. It can be `undefined`, if the binary itself is downloaded directly. */\n extractFunction?: (file: string, dest: string) => Promise<unknown>\n}\n\nexport type InstallationInfo = {\n /** The top install dir */\n installDir?: string\n binDir: string\n bin?: string\n}\n\n/**\n * A function that:\n *\n * - Downloads and extracts a package\n * - Adds the bin path of the package to PATH\n * - Caches the downloaded directory into tool cache for usage from other sessions\n *\n * @returns The installation directory\n */\nexport async function setupBin(\n name: string,\n version: string,\n getPackageInfo: (version: string, platform: NodeJS.Platform, arch: string) => PackageInfo | Promise<PackageInfo>,\n setupDir: string,\n arch: string,\n): Promise<InstallationInfo> {\n info(`Installing ${name} ${version} ${arch} via direct downloading`)\n\n process.env.RUNNER_TEMP = process.env.RUNNER_TEMP ?? tmpdir()\n process.env.RUNNER_TOOL_CACHE = process.env.RUNNER_TOOL_CACHE ?? join(tmpdir(), \"setup-cpp\", \"hostedtoolcache\")\n\n const { url, binRelativeDir, binFileName, extractedFolderName, extractFunction } = await getPackageInfo(\n version,\n process.platform,\n arch,\n )\n\n // Restore from cache (if found).\n if (GITHUB_ACTIONS) {\n try {\n const dir = find(name, version)\n if (dir) {\n const installDir = join(dir, extractedFolderName)\n const binDir = join(installDir, binRelativeDir)\n if (await pathExists(join(binDir, binFileName))) {\n info(`${name} ${version} was found in the cache at ${binDir}.`)\n await addPath(binDir, rcOptions)\n\n return { installDir, binDir }\n }\n }\n } catch {\n // fails on a local machine?\n }\n }\n\n const installDir = join(setupDir, extractedFolderName)\n const binDir = join(installDir, binRelativeDir)\n const binFile = join(binDir, binFileName)\n\n await downloadExtractInstall(binDir, binFile, name, version, url, setupDir, extractFunction, arch)\n\n await cacheInstallation(setupDir, name, version)\n\n return { installDir, binDir }\n}\n\nasync function downloadExtractInstall(\n binDir: string,\n binFile: string,\n name: string,\n version: string,\n url: string,\n setupDir: string,\n givenExtractFunction: PackageInfo[\"extractFunction\"],\n arch: string,\n) {\n // download ane extract the package into the installation directory.\n if ((await Promise.all([pathExists(binDir), pathExists(binFile)])).includes(false)) {\n try {\n const downloaded = await tryDownload(name, version, url)\n\n info(`Extracting ${downloaded} to ${setupDir}`)\n\n const extractFunction = givenExtractFunction ?? getExtractFunction(getArchiveType(url))\n await extractFunction(downloaded, setupDir)\n } catch (err) {\n throw new Error(`Failed to download ${name} ${version} ${arch} from ${url}: ${err}`)\n }\n }\n\n // Adding the bin dir to the path\n /** The directory which the tool is installed to */\n info(`Add ${binDir} to PATH`)\n await addPath(binDir, rcOptions)\n\n // Check if the binary exists after extraction\n if (!(await pathExists(binFile))) {\n throw new Error(`Failed to find the binary ${binFile} after extracting ${name} ${version} ${arch}`)\n }\n\n // make the binary executable on non-windows platforms\n if (process.platform !== \"win32\") {\n try {\n await chmod(binFile, \"755\")\n } catch (err) {\n warning(`Failed to make ${binFile} executable: ${err}`)\n }\n }\n}\n\nasync function tryDownload(name: string, version: string, url: string) {\n info(`Download ${name} ${version}`)\n // try to download the package 4 times with 2 seconds delay\n const downloaded = await retry(\n () => {\n const downloadedFilePath = join(process.env.RUNNER_TEMP ?? tmpdir(), `${Date.now()}-${basename(url)}`)\n\n return downloadTool(url, downloadedFilePath)\n },\n { name: url, max: 4, backoffBase: 2000, report: (err) => info(err) },\n )\n return downloaded\n}\n\nasync function cacheInstallation(setupDir: string, name: string, version: string) {\n // check if inside Github Actions. If so, cache the installation\n if (GITHUB_ACTIONS && typeof process.env.RUNNER_TOOL_CACHE === \"string\") {\n if (maybeGetInput(\"cache-tools\") === \"true\" || process.env.CACHE_TOOLS === \"true\") {\n await cacheDir(setupDir, name, version)\n }\n }\n}\n","import { info } from \"ci-log\"\nimport { addExeExt } from \"patha\"\nimport semverCoerce from \"semver/functions/coerce\"\nimport semverLte from \"semver/functions/lte\"\nimport { arm64, x86, x86_64 } from \"../utils/env/arch.js\"\nimport { type InstallationInfo, type PackageInfo, setupBin } from \"../utils/setup/setupBin.js\"\n\n/** Get the platform data for cmake */\nfunction getCmakePackageInfo(version: string, platform: NodeJS.Platform, arch: string): PackageInfo {\n const semVersion = semverCoerce(version) ?? version\n switch (platform) {\n case \"win32\": {\n const isOld = semverLte(semVersion, \"v3.19.6\")\n let osArchStr: string\n if (x86_64.includes(arch)) {\n osArchStr = isOld ? \"win64-x64\" : \"windows-x86_64\"\n } else if (x86.includes(arch)) {\n osArchStr = isOld ? \"win32-x86\" : \"windows-i386\"\n } else if (arm64.includes(arch)) {\n osArchStr = \"windows-arm64\"\n } else {\n info(`Trying unsupported arch '${arch}' for cmake on Windows`)\n osArchStr = `windows-${arch}`\n }\n const folderName = `cmake-${version}-${osArchStr}`\n return {\n binRelativeDir: \"bin/\",\n binFileName: addExeExt(\"cmake\"),\n extractedFolderName: folderName,\n url: `https://github.com/Kitware/CMake/releases/download/v${version}/${folderName}.zip`,\n }\n }\n case \"darwin\": {\n const isOld = semverLte(semVersion, \"v3.19.1\")\n const osArchStr = isOld ? \"Darwin-x86_64\" : \"macos-universal\"\n const folderName = `cmake-${version}-${osArchStr}`\n return {\n binRelativeDir: \"CMake.app/Contents/bin/\",\n binFileName: addExeExt(\"cmake\"),\n extractedFolderName: folderName,\n url: `https://github.com/Kitware/CMake/releases/download/v${version}/${folderName}.tar.gz`,\n }\n }\n case \"linux\": {\n const isOld = semverLte(semVersion, \"v3.19.8\")\n let osArchStr: string\n if (arm64.includes(arch)) {\n osArchStr = isOld ? \"Linux-aarch64\" : \"linux-aarch64\"\n } else if (x86_64.includes(arch)) {\n osArchStr = isOld ? \"Linux-x86_64\" : \"linux-x86_64\"\n } else {\n info(`Trying unsupported arch '${arch}' for cmake on Linux`)\n osArchStr = `linux-${arch}`\n }\n const folderName = `cmake-${version}-${osArchStr}`\n return {\n binRelativeDir: \"bin/\",\n binFileName: addExeExt(\"cmake\"),\n extractedFolderName: folderName,\n url: `https://github.com/Kitware/CMake/releases/download/v${version}/${folderName}.tar.gz`,\n }\n }\n default:\n throw new Error(`Unsupported platform '${platform}'`)\n }\n}\n\n/** Setup cmake */\nexport function setupCmake(version: string, setupDir: string, arch: string): Promise<InstallationInfo> {\n return setupBin(\"cmake\", version, getCmakePackageInfo, setupDir, arch)\n}\n","import { getExecOutput } from \"@actions/exec\"\nimport { info } from \"ci-log\"\nimport { isUrlOnline } from \"is-url-online\"\nimport semverCoerce from \"semver/functions/coerce\"\nimport semverCompare from \"semver/functions/compare\"\nimport semverValid from \"semver/functions/valid\"\n\n/**\n * Gets the specific versions supported by this action compatible with the supplied (specific or minimum) version in\n * descending order of release (e.g., `5.0.2`, `5.0.1`, and `5.0.0` for `5`).\n */\nexport function getSpecificVersions(versions: Set<string>, semversion: string): string[] {\n return Array.from(versions)\n .filter((v) => /^\\d+\\.\\d+\\.\\d+$/.test(v) && v.startsWith(semversion))\n .sort((a, b) => {\n try {\n return semverCompare(a, b)\n } catch (err) {\n return a.localeCompare(b)\n }\n })\n .reverse()\n}\n\n/**\n * Gets the specific and minimum versions that can be used to refer to the supplied specific versions (e.g., `3`, `3.5`,\n * `3.5.2` for `3.5.2`).\n */\nexport function getVersions(specific: string[]): Set<string> {\n const versions = new Set(specific)\n\n for (const version of specific) {\n versions.add(/^\\d+/.exec(version)![0])\n versions.add(/^\\d+\\.\\d+/.exec(version)![0])\n }\n\n return versions\n}\n\n/** Gets the most recent specific version for which there is a valid download URL. */\nexport async function getSpecificVersionAndUrl(\n versions: Set<string>,\n platform: string,\n version: string,\n getUrl: (platform: string, version: string) => string | null | Promise<string | null>,\n): Promise<[string, string]> {\n // specific ubuntu version\n if (platform === \"linux\" && version.includes(\"ubuntu\")) {\n const url = await getUrl(platform, version)\n // eslint-disable-next-line no-await-in-loop\n if (url !== null && (await isUrlOnline(url))) {\n return [version, url]\n }\n }\n\n // if the given set doesn't include the version, throw an error\n if (!versions.has(version)) {\n throw new Error(\n `Unsupported target! (platform='${platform}', version='${version}'). Try one of the following: ${\n JSON.stringify(\n versions,\n )\n }`,\n )\n }\n\n const offlineUrls: string[] = []\n\n // TODO use Promise.any\n for (const specificVersion of getSpecificVersions(versions, version)) {\n // eslint-disable-next-line no-await-in-loop\n const url = await getUrl(platform, specificVersion)\n if (url !== null) {\n // eslint-disable-next-line no-await-in-loop\n if (await isUrlOnline(url)) {\n return [specificVersion, url]\n } else {\n offlineUrls.push(url)\n }\n }\n }\n\n throw new Error(\n `Unsupported target! (platform='${platform}', version='${version}'). Try one of the following: ${\n JSON.stringify(\n versions,\n )\n }`,\n )\n}\n\nexport const defaultVersionRegex = /v?(\\d\\S*)/\n\n/** Get the version of a binary */\nexport async function getBinVersion(file: string, versionRegex: RegExp = defaultVersionRegex) {\n try {\n const execout = await getExecOutput(file, [\"--version\"])\n const version_output = execout.stdout || execout.stderr || \"\"\n const version = version_output.trim().match(versionRegex)?.[1]\n return semverCoerce(version) ?? undefined\n } catch (e) {\n console.error(e)\n return undefined\n }\n}\n\n/** Check if the given bin is up to date against the target version */\nexport async function isBinUptoDate(\n givenFile: string,\n targetVersion: string,\n versionRegex: RegExp = defaultVersionRegex,\n) {\n const givenVersion = await getBinVersion(givenFile, versionRegex)\n if (givenVersion !== undefined && targetVersion !== \"\") {\n return semverCompare(givenVersion, targetVersion) !== -1\n } else {\n // assume given version is old\n return false\n }\n}\n\n/** Coerce the given version if it is invalid */\nexport function semverCoerceIfInvalid(version: string) {\n if (semverValid(version) === null) {\n // version coercion\n try {\n // find the semver version of an integer\n const coercedVersion = semverCoerce(version)\n if (coercedVersion !== null) {\n info(`Coerced version '${version}' to '${coercedVersion}'`)\n return coercedVersion.version\n }\n } catch (err) {\n // handled below\n }\n }\n return version\n}\n\n/**\n * Coerce the given version to a semver range if it is invalid\n */\nexport function semverCoercedRangeIfInvalid(version: string) {\n if (semverValid(version) === null) {\n // version coercion\n try {\n // find the semver version of an integer\n const coercedVersion = semverCoerce(version)\n if (coercedVersion !== null) {\n // if the versions doesn't specify a range specifier (e.g. ^, ~, >, <, etc.), add a ^ to the version\n const versionRange = /^[<=>^~]/.test(coercedVersion.version)\n ? coercedVersion.version\n : `^${coercedVersion.version}`\n\n info(`Coerced version '${version}' to '${versionRange}'`)\n return versionRange\n }\n } catch (err) {\n // handled below\n }\n }\n return version\n}\n\nexport function removeVPrefix(version: string) {\n return Number.parseInt(version.replace(/^v/, \"\"), 10)\n}\n\nexport function addVPrefix(version: string) {\n if (!version.match(/^v/)) {\n return `v${version}`\n }\n return version\n}\n\nexport function compareVersion(tag1: string, tag2: string) {\n const v1 = semverCoerce(tag1)\n const v2 = semverCoerce(tag2)\n if (v1 !== null && v2 !== null) {\n // put the latest version first\n return v2.compare(v1)\n }\n\n // if the tags are not semver, compare them as strings, putting the latest tag first\n return tag2.localeCompare(tag1)\n}\n","export function unique(dirs: string[]) {\n return [...new Set(dirs)]\n}\n\nexport function quoteIfHasSpace(str: string, quoteChar = \"\\\"\") {\n return str.includes(\" \") ? `${quoteChar}${str}${quoteChar}` : str\n}\n","import assert from \"assert\"\nimport { homedir } from \"os\"\nimport { dirname, join, parse as pathParse } from \"path\"\nimport { getExecOutput } from \"@actions/exec\"\nimport ciInfo from \"ci-info\"\nconst { GITHUB_ACTIONS } = ciInfo\nimport { info, warning } from \"ci-log\"\nimport { addPath } from \"envosman\"\nimport { execa } from \"execa\"\nimport { readdir } from \"fs/promises\"\nimport memoize from \"memoizee\"\nimport { pathExists } from \"path-exists\"\nimport { addExeExt } from \"patha\"\nimport { installAptPack } from \"setup-apt\"\nimport { installBrewPack } from \"setup-brew\"\nimport which from \"which\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport type { InstallationInfo } from \"../utils/setup/setupBin.js\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\nimport { hasPipx, setupPipPackSystem, setupPipPackWithPython } from \"../utils/setup/setupPipPack.js\"\nimport { isBinUptoDate } from \"../utils/setup/version.js\"\nimport { unique } from \"../utils/std/index.js\"\nimport { MinVersions } from \"../versions/default_versions.js\"\n\nexport async function setupPython(\n version: string,\n setupDir: string,\n arch: string,\n): Promise<InstallationInfo & { bin: string }> {\n const installInfo = await findOrSetupPython(version, setupDir, arch)\n assert(installInfo.bin !== undefined)\n const foundPython = installInfo.bin\n\n // setup pip\n const foundPip = await findOrSetupPip(foundPython)\n if (foundPip === undefined) {\n throw new Error(\"pip was not installed correctly\")\n }\n\n await setupPipx(foundPython)\n\n await setupWheel(foundPython)\n\n return installInfo as InstallationInfo & { bin: string }\n}\n\nasync function setupPipx(foundPython: string) {\n try {\n if (!(await hasPipx(foundPython))) {\n try {\n await setupPipPackWithPython(foundPython, \"pipx\", undefined, { upgrade: true, usePipx: false })\n } catch (err) {\n if (setupPipPackSystem(\"pipx\", false) === null) {\n throw new Error(`pipx was not installed correctly ${err}`)\n }\n }\n }\n await execa(foundPython, [\"-m\", \"pipx\", \"ensurepath\"], { stdio: \"inherit\" })\n await setupVenv(foundPython)\n } catch (err) {\n warning(`Failed to install pipx: ${(err as Error).toString()}. Ignoring...`)\n }\n}\n\nasync function setupVenv(foundPython: string) {\n try {\n await setupPipPackWithPython(foundPython, \"venv\", undefined, { upgrade: false, usePipx: false })\n } catch (err) {\n warning(`Failed to install venv: ${(err as Error).toString()}. Ignoring...`)\n }\n}\n\n/** Setup wheel and setuptools */\nasync function setupWheel(foundPython: string) {\n try {\n await setupPipPackWithPython(foundPython, \"setuptools\", undefined, {\n upgrade: true,\n isLibrary: true,\n usePipx: false,\n })\n await setupPipPackWithPython(foundPython, \"wheel\", undefined, { upgrade: false, isLibrary: true, usePipx: false })\n } catch (err) {\n warning(`Failed to install setuptools/wheel: ${(err as Error).toString()}. Ignoring...`)\n }\n}\n\nasync function findOrSetupPython(version: string, setupDir: string, arch: string): Promise<InstallationInfo> {\n let installInfo: InstallationInfo | undefined\n let foundPython = await findPython(setupDir)\n\n if (foundPython !== undefined) {\n const binDir = dirname(foundPython)\n installInfo = { bin: foundPython, installDir: binDir, binDir }\n } else {\n // if python is not found, try to install it\n if (GITHUB_ACTIONS) {\n // install python in GitHub Actions\n try {\n info(\"Installing python in GitHub Actions\")\n const { setupActionsPython } = await import(\"./actions_python.js\")\n await setupActionsPython(version, setupDir, arch)\n\n foundPython = await findPython(setupDir)\n if (foundPython === undefined) {\n throw new Error(\"Python binary could not be found\")\n }\n const binDir = dirname(foundPython)\n installInfo = { bin: foundPython, installDir: binDir, binDir }\n } catch (err) {\n warning((err as Error).toString())\n }\n }\n if (installInfo === undefined) {\n // install python via system package manager\n installInfo = await setupPythonSystem(setupDir, version)\n }\n }\n\n if (foundPython === undefined || installInfo.bin === undefined) {\n foundPython = await findPython(setupDir)\n if (foundPython === undefined) {\n throw new Error(\"Python binary could not be found\")\n }\n installInfo = { bin: foundPython, installDir: dirname(foundPython), binDir: dirname(foundPython) }\n }\n\n return installInfo\n}\n\nasync function setupPythonSystem(setupDir: string, version: string) {\n let installInfo: InstallationInfo | undefined\n switch (process.platform) {\n case \"win32\": {\n if (setupDir) {\n await setupChocoPack(\"python3\", version, [`--params=/InstallDir:${setupDir}`])\n } else {\n await setupChocoPack(\"python3\", version)\n }\n // Adding the bin dir to the path\n const bin = await findPython(setupDir)\n if (bin === undefined) {\n throw new Error(\"Python binary could not be found\")\n }\n const binDir = dirname(bin)\n /** The directory which the tool is installed to */\n await addPath(binDir, rcOptions)\n installInfo = { installDir: binDir, binDir, bin }\n break\n }\n case \"darwin\": {\n installInfo = await installBrewPack(\"python3\", version)\n // add the python and pip binaries to the path\n const brewPythonPrefix: {\n stdout: string\n stderr: string\n } = await execa(\"brew\", [\"--prefix\", \"python\"], { stdio: \"pipe\" })\n const brewPythonBin = join(brewPythonPrefix.stdout, \"libexec\", \"bin\")\n await addPath(brewPythonBin, rcOptions)\n\n break\n }\n case \"linux\": {\n if (isArch()) {\n installInfo = await setupPacmanPack(\"python\", version)\n } else if (hasDnf()) {\n installInfo = await setupDnfPack([{ name: \"python3\", version }])\n } else if (isUbuntu()) {\n installInfo = await installAptPack([{ name: \"python3\", version }, { name: \"python-is-python3\" }])\n } else {\n throw new Error(\"Unsupported linux distributions\")\n }\n break\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n return installInfo\n}\n\nasync function findPython(binDir?: string) {\n for (const pythonBin of [\"python\", \"python3\"]) {\n // eslint-disable-next-line no-await-in-loop\n const foundPython = await isPythonUpToDate(pythonBin, binDir)\n if (foundPython !== undefined) {\n return foundPython\n }\n }\n\n // On Windows, search in C:\\PythonXX\n if (process.platform === \"win32\") {\n const rootDir = pathParse(homedir()).root\n // find all directories in rootDir using readdir\n const pythonDirs = (await readdir(rootDir)).filter((dir) => dir.startsWith(\"Python\"))\n\n for (const pythonDir of pythonDirs) {\n for (const pythonBin of [\"python3\", \"python\"]) {\n // eslint-disable-next-line no-await-in-loop\n const foundPython = await isPythonUpToDate(pythonBin, join(rootDir, pythonDir))\n if (foundPython !== undefined) {\n return foundPython\n }\n }\n }\n }\n\n return undefined\n}\n\nasync function isPythonUpToDate(candidate: string, binDir?: string) {\n try {\n if (binDir !== undefined) {\n const pythonBinPath = join(binDir, addExeExt(candidate))\n if (await pathExists(pythonBinPath) && await isBinUptoDate(pythonBinPath, MinVersions.python!)) {\n return pythonBinPath\n }\n }\n // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition\n const pythonBinPaths = (await which(candidate, { nothrow: true, all: true })) ?? []\n for (const pythonBinPath of pythonBinPaths) {\n // eslint-disable-next-line no-await-in-loop\n if (await isBinUptoDate(pythonBinPath, MinVersions.python!)) {\n return pythonBinPath\n }\n }\n } catch {\n // fall through\n }\n return undefined\n}\n\nasync function findOrSetupPip(foundPython: string) {\n const maybePip = await findPip()\n\n if (maybePip === undefined) {\n // install pip if not installed\n info(\"pip was not found. Installing pip\")\n await setupPip(foundPython)\n return findPip() // recurse to check if pip is on PATH and up-to-date\n }\n\n return maybePip\n}\n\nasync function findPip() {\n for (const pipCandidate of [\"pip3\", \"pip\"]) {\n // eslint-disable-next-line no-await-in-loop\n const maybePip = await isPipUptoDate(pipCandidate)\n if (maybePip !== undefined) {\n return maybePip\n }\n }\n return undefined\n}\n\nasync function isPipUptoDate(pip: string) {\n try {\n // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition\n const pipPaths = (await which(pip, { nothrow: true, all: true })) ?? []\n for (const pipPath of pipPaths) {\n // eslint-disable-next-line no-await-in-loop\n if (await isBinUptoDate(pipPath, MinVersions.pip!)) {\n return pipPath\n }\n }\n } catch {\n // fall through\n }\n return undefined\n}\n\nasync function setupPip(foundPython: string) {\n const upgraded = await ensurePipUpgrade(foundPython)\n if (!upgraded) {\n // ensure that pip is installed on Linux (happens when python is found but pip not installed)\n await setupPipPackSystem(\"pip\")\n\n // upgrade pip\n await ensurePipUpgrade(foundPython)\n }\n}\n\nasync function ensurePipUpgrade(foundPython: string) {\n try {\n await execa(foundPython, [\"-m\", \"ensurepip\", \"-U\", \"--upgrade\"], { stdio: \"inherit\" })\n return true\n } catch (err1) {\n info((err1 as Error).toString())\n try {\n // ensure pip is disabled on Ubuntu\n await execa(foundPython, [\"-m\", \"pip\", \"install\", \"--upgrade\", \"pip\"], { stdio: \"inherit\" })\n return true\n } catch (err2) {\n info((err2 as Error).toString())\n // pip module not found\n }\n }\n // all methods failed\n return false\n}\n\nasync function addPythonBaseExecPrefix_(python: string) {\n const dirs: string[] = []\n\n // detection based on the platform\n if (process.platform === \"linux\") {\n dirs.push(\"/home/runner/.local/bin/\")\n } else if (process.platform === \"darwin\") {\n dirs.push(\"/usr/local/bin/\")\n }\n\n // detection using python.sys\n const base_exec_prefix = (await getExecOutput(`${python} -c \"import sys;print(sys.base_exec_prefix);\"`)).stdout.trim()\n // any of these are possible depending on the operating system!\n dirs.push(join(base_exec_prefix, \"Scripts\"), join(base_exec_prefix, \"Scripts\", \"bin\"), join(base_exec_prefix, \"bin\"))\n\n // remove duplicates\n return unique(dirs)\n}\n\n/**\n * Add the base exec prefix to the PATH. This is required for Conan, Meson, etc. to work properly.\n *\n * The answer is cached for subsequent calls\n */\nexport const addPythonBaseExecPrefix = memoize(addPythonBaseExecPrefix_, { promise: true })\n","import type { Opts } from \"../cli-options.js\"\nimport type { CompilerInfo } from \"../compilers.js\"\nimport type { Inputs } from \"../tool.js\"\nimport { DefaultUbuntuVersion, DefaultVersions } from \"./default_versions.js\"\n\n/** Get the default version if passed true or undefined, otherwise return the version itself */\nexport function getVersion(name: string, version: string | undefined, osVersion: number[] | null = null) {\n if (isVersionDefault(version) && process.platform === \"linux\" && osVersion !== null && name in DefaultUbuntuVersion) {\n return getDefaultLinuxVersion(osVersion, DefaultUbuntuVersion[name]!)\n } else if (isVersionDefault(version) && name in DefaultVersions) {\n return DefaultVersions[name] ?? \"\"\n } else if (version === \"true\") {\n return \"\"\n }\n return version ?? \"\"\n}\n\nfunction isVersionDefault(version: string | undefined) {\n return version === \"true\" || version === undefined\n}\n\n/// choose the default linux version based on ubuntu version\nfunction getDefaultLinuxVersion(osVersion: number[], toolLinuxVersions: Record<number, string>) {\n const osVersionMaj = osVersion[0]\n\n // find which version block the os version is in\n const satisfyingVersion = Object.keys(toolLinuxVersions)\n .map((v) => Number.parseInt(v, 10))\n .sort((a, b) => b - a) // sort in descending order\n .find((v) => osVersionMaj >= v)\n\n return satisfyingVersion === undefined ? \"\" : toolLinuxVersions[satisfyingVersion]\n}\n\n/**\n * Sync the versions for the given inputs\n *\n * It modifies the opts object to have the same version for all the tools\n * If the return is false, it means that versions don't match the target version\n * @param opts - The options object (modified in place)\n * @param tools - The tools to sync the versions for (it can include `compiler`)\n * @param compilerInfo - The compiler info to sync the versions for (if any)\n */\nexport function syncVersions(\n opts: Opts,\n toolsGiven: Inputs[],\n compilerInfo: CompilerInfo | undefined = undefined,\n): boolean {\n // check if compiler version should be synced\n const syncCompiler = compilerInfo === undefined ? false : toolsGiven.includes(compilerInfo.compiler as Inputs)\n\n // remove the compiler from the tools if it should not be synced\n const tools = syncCompiler ? toolsGiven : toolsGiven.filter((tool) => tool !== \"compiler\")\n\n // filter out the tools that are in use in the options\n const toolsInUse = tools.filter((tool) => opts[tool] !== undefined)\n\n // filter out the tools that are not default\n const toolsNonDefaultVersion = toolsInUse.filter((tool) => {\n const version = (syncCompiler && tool === \"compiler\" && compilerInfo !== undefined)\n ? compilerInfo.version\n : opts[tool]\n return !isVersionDefault(version)\n })\n\n // find the target version to sync to\n const targetVersion: string = (toolsNonDefaultVersion.length !== 0)\n ? (syncCompiler && toolsNonDefaultVersion[0] === \"compiler\" && compilerInfo !== undefined)\n ? compilerInfo.version ?? \"true\"\n : opts[toolsNonDefaultVersion[0]] ?? \"true\"\n : \"true\"\n\n // error if any explicit versions don't match the target version\n if (\n toolsNonDefaultVersion.some((tool) => {\n if (syncCompiler && tool === \"compiler\" && compilerInfo !== undefined) {\n return opts.compiler !== `${compilerInfo.compiler}-${targetVersion}`\n }\n\n return opts[tool] !== targetVersion\n })\n ) {\n return false\n }\n\n // update the version of all the tools to the target version\n for (const tool of toolsInUse) {\n opts[tool] = (syncCompiler && tool === \"compiler\" && compilerInfo !== undefined)\n ? `${compilerInfo.compiler}-${targetVersion}`\n : targetVersion\n }\n\n return true\n}\n","import os from \"os\"\nimport { warning } from \"ci-log\"\nimport memoize from \"memoizee\"\nimport { installAptPack } from \"setup-apt\"\nimport { getUbuntuVersion } from \"ubuntu-version\"\nimport which from \"which\"\nimport { isUbuntu } from \"./isUbuntu.js\"\n\nasync function ubuntuVersion_(): Promise<number[] | null> {\n try {\n if (isUbuntu()) {\n try {\n if (which.sync(\"lsb_release\", { nothrow: true }) === null) {\n await installAptPack([{ name: \"lsb-release\" }])\n }\n } catch {\n return detectUsingOsVersion()\n }\n\n const versionSplitted = await getUbuntuVersion()\n\n if (versionSplitted.length === 0) {\n return detectUsingOsVersion()\n }\n\n return versionSplitted\n } else {\n return null\n }\n } catch (err) {\n warning((err as Error).toString())\n return null\n }\n}\n\n/** Detect Ubuntu version */\nexport const ubuntuVersion = memoize(ubuntuVersion_, { promise: true })\n\n/** Detect Ubuntu version using os.version() for Ubuntu based distros */\nfunction detectUsingOsVersion() {\n if (!(\"version\" in os && typeof os.version === \"function\")) {\n return null\n }\n\n // #40~22.04.3-Ubuntu SMP PREEMPT_DYNAMIC Tue Jul 30 17:30:19 UTC 2\n const osVersion: string = os.version()\n // parse the version\n const versionMatch = osVersion.match(/(\\d+)\\.(\\d+)\\.(\\d+)/)\n if (versionMatch === null) {\n return null\n }\n\n const majorVersion = Number.parseInt(versionMatch[1], 10)\n const minorVersion = Number.parseInt(versionMatch[2], 10)\n const patchVersion = Number.parseInt(versionMatch[3], 10)\n\n return [majorVersion, minorVersion, patchVersion]\n}\n","import { dirname, join } from \"path\"\nimport { info } from \"@actions/core\"\nimport { addPath } from \"envosman\"\nimport { execa, execaSync } from \"execa\"\nimport memoize from \"memoizee\"\nimport { mkdirp } from \"mkdirp\"\nimport { pathExists } from \"path-exists\"\nimport { addExeExt } from \"patha\"\nimport { installAptPack } from \"setup-apt\"\nimport { installBrewPack } from \"setup-brew\"\nimport { untildifyUser } from \"untildify-user\"\nimport which from \"which\"\nimport { rcOptions } from \"../../cli-options.js\"\nimport { addPythonBaseExecPrefix, setupPython } from \"../../python/python.js\"\nimport { getVersion } from \"../../versions/versions.js\"\nimport { hasDnf } from \"../env/hasDnf.js\"\nimport { isArch } from \"../env/isArch.js\"\nimport { isUbuntu } from \"../env/isUbuntu.js\"\nimport { ubuntuVersion } from \"../env/ubuntu_version.js\"\nimport type { InstallationInfo } from \"./setupBin.js\"\nimport { setupDnfPack } from \"./setupDnfPack.js\"\nimport { setupPacmanPack } from \"./setupPacmanPack.js\"\n\nexport type SetupPipPackOptions = {\n /** Whether to use pipx instead of pip */\n usePipx?: boolean\n /** Whether to install the package as a user */\n user?: boolean\n /** Whether to upgrade the package */\n upgrade?: boolean\n /** Whether the package is a library */\n isLibrary?: boolean\n}\n\n/** A function that installs a package using pip */\nexport async function setupPipPack(\n name: string,\n version?: string,\n options: SetupPipPackOptions = {},\n): Promise<InstallationInfo> {\n return setupPipPackWithPython(await getPython(), name, version, options)\n}\n\nexport async function setupPipPackWithPython(\n givenPython: string,\n name: string,\n version?: string,\n options: SetupPipPackOptions = {},\n): Promise<InstallationInfo> {\n const { usePipx = true, user = true, upgrade = false, isLibrary = false } = options\n\n const isPipx = usePipx && !isLibrary && (await hasPipx(givenPython))\n\n const pip = isPipx ? \"pipx\" : \"pip\"\n\n // remove `[]` extensions\n const nameOnly = getPackageName(name)\n\n // if upgrade is not requested, check if the package is already installed, and return if it is\n if (!upgrade) {\n const installed = isPipx\n ? await pipxPackageInstalled(givenPython, nameOnly)\n : await pipPackageIsInstalled(givenPython, nameOnly)\n if (installed) {\n const binDir = isPipx\n ? await finishPipxPackageInstall()\n : await finishPipPackageInstall(givenPython, nameOnly)\n return { binDir }\n }\n }\n\n const hasPackage = await pipHasPackage(givenPython, nameOnly)\n if (hasPackage) {\n try {\n info(`Installing ${name} ${version ?? \"\"} via ${pip}`)\n\n const nameAndVersion = version !== undefined && version !== \"\" ? `${name}==${version}` : name\n const upgradeFlag = upgrade ? (isPipx ? [\"upgrade\"] : [\"install\", \"--upgrade\"]) : [\"install\"]\n const userFlag = !isPipx && user ? [\"--user\"] : []\n\n const env = process.env\n\n if (isPipx && user) {\n // install to user home\n env.PIPX_HOME = await getPipxHome()\n env.PIPX_BIN_DIR = await getPipxBinDir()\n }\n\n execaSync(givenPython, [\"-m\", pip, ...upgradeFlag, ...userFlag, nameAndVersion], {\n stdio: \"inherit\",\n env,\n })\n } catch (err) {\n const msg = err instanceof Error ? `${err.message}\\n${err.stack}` : String(err)\n info(`Failed to install ${name} via ${pip}: ${msg}`)\n if ((await setupPipPackSystem(name)) === null) {\n throw new Error(`Failed to install ${name} via ${pip}: ${err}.`)\n }\n }\n } else if ((await setupPipPackSystem(name)) === null) {\n throw new Error(`Failed to install ${name} as it was not found via ${pip} or the system package manager`)\n }\n\n const binDir = isPipx\n ? await finishPipxPackageInstall()\n : await finishPipPackageInstall(givenPython, nameOnly)\n return { binDir }\n}\n\nfunction finishPipxPackageInstall() {\n return getPipxBinDir()\n}\n\nasync function finishPipPackageInstall(givenPython: string, name: string) {\n const pythonBaseExecPrefix = await addPythonBaseExecPrefix(givenPython)\n const binDir = await findBinDir(pythonBaseExecPrefix, name)\n await addPath(binDir, rcOptions)\n return binDir\n}\n\nexport async function hasPipx(givenPython: string) {\n const res = await execa(givenPython, [\"-m\", \"pipx\", \"--help\"], { stdio: \"ignore\", reject: false })\n return res.exitCode === 0\n}\n\nasync function getPipxHome_() {\n let pipxHome = process.env.PIPX_HOME\n if (pipxHome !== undefined) {\n return pipxHome\n }\n\n // Based on https://pipx.pypa.io/stable/installation/\n const compatHome = untildifyUser(\"~/.local/pipx\")\n if (await pathExists(compatHome)) {\n return compatHome\n }\n\n switch (process.platform) {\n case \"win32\": {\n pipxHome = untildifyUser(\"~/AppData/Local/pipx\")\n break\n }\n case \"darwin\": {\n pipxHome = untildifyUser(\"~/Library/Application Support/pipx\")\n break\n }\n default: {\n pipxHome = untildifyUser(\"~/.local/share/pipx\")\n break\n }\n }\n\n await mkdirp(pipxHome)\n await mkdirp(join(pipxHome, \"trash\"))\n await mkdirp(join(pipxHome, \"shared\"))\n await mkdirp(join(pipxHome, \"venv\"))\n return pipxHome\n}\nconst getPipxHome = memoize(getPipxHome_, { promise: true })\n\nasync function getPipxBinDir_() {\n if (process.env.PIPX_BIN_DIR !== undefined) {\n return process.env.PIPX_BIN_DIR\n }\n\n const pipxBinDir = untildifyUser(\"~/.local/bin\")\n await addPath(pipxBinDir, rcOptions)\n await mkdirp(pipxBinDir)\n return pipxBinDir\n}\nconst getPipxBinDir = memoize(getPipxBinDir_, { promise: true })\n\n/* eslint-disable require-atomic-updates */\nlet pythonBin: string | undefined\n\nasync function getPython(): Promise<string> {\n if (pythonBin !== undefined) {\n return pythonBin\n }\n\n pythonBin = (await setupPython(getVersion(\"python\", undefined, await ubuntuVersion()), \"\", process.arch)).bin\n return pythonBin\n}\n\n/**\n * Get the actual name of a pip package from the given string\n * @param pkg the given name that might contain extensions in `[]`.\n * @returns stirped down name of the package\n */\nfunction getPackageName(pkg: string) {\n return pkg.replace(/\\[.*]/g, \"\").trim()\n}\n\nasync function pipPackageIsInstalled(python: string, name: string) {\n try {\n const result = await execa(python, [\"-m\", \"pip\", \"-qq\", \"show\", name], {\n stdio: \"ignore\",\n reject: false,\n })\n return result.exitCode === 0\n } catch {\n return false\n }\n}\n\ntype PipxShowType = {\n venvs: Record<string, {\n metadata: {\n main_package: {\n package: string\n package_or_url: string\n apps: string[]\n }\n }\n }>\n}\n\nasync function pipxPackageInstalled(python: string, name: string) {\n try {\n const result = await execa(python, [\"-m\", \"pipx\", \"list\", \"--json\"], {\n stdio: \"ignore\",\n reject: false,\n })\n if (result.exitCode !== 0 || typeof result.stdout !== \"string\") {\n return false\n }\n\n const pipxOut = JSON.parse(result.stdout) as PipxShowType\n // search among the venvs\n if (name in pipxOut.venvs) {\n return true\n }\n // search among the urls\n for (const venv of Object.values(pipxOut.venvs)) {\n if (venv.metadata.main_package.package_or_url === name || venv.metadata.main_package.package === name) {\n return true\n }\n }\n } catch {\n // ignore\n }\n return false\n}\n\nasync function pipHasPackage(python: string, name: string) {\n const result = await execa(python, [\"-m\", \"pip\", \"-qq\", \"index\", \"versions\", name], {\n stdio: \"ignore\",\n reject: false,\n })\n return result.exitCode === 0\n}\n\nasync function findBinDir(dirs: string[], name: string) {\n const exists = await Promise.all(dirs.map((dir) => pathExists(join(dir, addExeExt(name)))))\n const dirIndex = exists.findIndex((exist) => exist)\n if (dirIndex !== -1) {\n const foundDir = dirs[dirIndex]\n return foundDir\n }\n\n const whichDir = which.sync(addExeExt(name), { nothrow: true })\n if (whichDir !== null) {\n return dirname(whichDir)\n }\n\n return dirs[dirs.length - 1]\n}\n\nexport function setupPipPackSystem(name: string, addPythonPrefix = true) {\n if (process.platform === \"linux\") {\n info(`Installing ${name} via the system package manager`)\n if (isArch()) {\n return setupPacmanPack(addPythonPrefix ? `python-${name}` : name)\n } else if (hasDnf()) {\n return setupDnfPack([{ name: addPythonPrefix ? `python3-${name}` : name }])\n } else if (isUbuntu()) {\n return installAptPack([{ name: addPythonPrefix ? `python3-${name}` : name }])\n }\n } else if (process.platform === \"darwin\") {\n return installBrewPack(name)\n }\n return null\n}\n","import { setupPipPack } from \"../utils/setup/setupPipPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport function setupCmakelang(version: string | undefined, _setupDir: string, _arch: string) {\n return setupPipPack(\"cmakelang[YAML]\", version)\n}\n","import { addPath } from \"envosman\"\nimport { installAptPack } from \"setup-apt\"\nimport { installBrewPack } from \"setup-brew\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport type { InstallationInfo } from \"../utils/setup/setupBin.js\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport async function setupGraphviz(version: string, _setupDir: string, _arch: string) {\n switch (process.platform) {\n case \"win32\": {\n await setupChocoPack(\"graphviz\", version)\n return activateGraphviz()\n }\n case \"darwin\": {\n return installBrewPack(\"graphviz\", version)\n }\n case \"linux\": {\n if (isArch()) {\n return setupPacmanPack(\"graphviz\", version)\n } else if (hasDnf()) {\n return setupDnfPack([{ name: \"graphviz\", version }])\n } else if (isUbuntu()) {\n return installAptPack([{ name: \"graphviz\", version }])\n }\n throw new Error(\"Unsupported linux distribution\")\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n}\n\nasync function activateGraphviz(): Promise<InstallationInfo> {\n switch (process.platform) {\n case \"win32\": {\n const binDir = \"C:/Program Files/Graphviz/bin\"\n await addPath(binDir, rcOptions)\n return { binDir }\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n}\n","import { join } from \"path\"\n\nexport async function setupDmg(path: string, destDir: string) {\n const { ArchiveHdi } = await import(\"@shockpkg/archive-files/esm/archive/hdi.mjs\")\n\n const dmg = new ArchiveHdi(path)\n await dmg.read(async (entry) => {\n await entry.extract(join(destDir, entry.path))\n })\n}\n","import { join } from \"path\"\nimport { info, notice } from \"ci-log\"\nimport { addPath } from \"envosman\"\nimport { addExeExt } from \"patha\"\nimport { installAptPack } from \"setup-apt\"\nimport { installBrewPack } from \"setup-brew\"\nimport { setupGraphviz } from \"../graphviz/graphviz.js\"\nimport { type InstallationInfo, type PackageInfo, setupBin } from \"../utils/setup/setupBin.js\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\nimport { getVersion } from \"../versions/versions.js\"\n\nimport { pathExists } from \"path-exists\"\nimport retry from \"retry-as-promised\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport { macosVersion } from \"../utils/env/macos_version.js\"\nimport { ubuntuVersion } from \"../utils/env/ubuntu_version.js\"\nimport { setupDmg } from \"../utils/setup/setupDmg.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\n\n/** Get the platform data for cmake */\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nfunction getDoxygenPackageInfo(version: string, platform: NodeJS.Platform, _arch: string): PackageInfo {\n switch (platform) {\n case \"linux\": {\n const folderName = `doxygen-${version}`\n return {\n binRelativeDir: \"bin/\",\n binFileName: addExeExt(\"doxygen\"),\n extractedFolderName: folderName,\n url: `https://www.doxygen.nl/files/${folderName}.linux.bin.tar.gz`,\n }\n }\n case \"win32\": {\n const folderName = `doxygen-${version}`\n return {\n binRelativeDir: \"\",\n binFileName: addExeExt(\"doxygen\"),\n extractedFolderName: folderName,\n url: `https://www.doxygen.nl/files/${folderName}.windows.x64.bin.zip`,\n }\n }\n case \"darwin\": {\n const folderName = `Doxygen-${version}`\n return {\n binRelativeDir: \"Doxygen/Doxygen.app/Contents/Resources/\",\n binFileName: addExeExt(\"doxygen\"),\n extractedFolderName: folderName,\n extractFunction: setupDmg,\n url: `https://doxygen.nl/files/${folderName}.dmg`,\n }\n }\n default:\n throw new Error(`Unsupported platform '${platform}'`)\n }\n}\n\nexport async function setupDoxygen(version: string, setupDir: string, arch: string) {\n switch (process.platform) {\n case \"win32\": {\n // try to download the package 4 times with 2 seconds delay\n await retry(\n () => {\n return setupChocoPack(\"doxygen.install\", version)\n },\n { name: \"doxygen.install\", max: 4, backoffBase: 2000, report: (err) => info(err) },\n )\n const binDir = await activateWinDoxygen()\n const installationInfo = { binDir }\n await setupGraphviz(getVersion(\"graphviz\", undefined), \"\", arch)\n return installationInfo\n }\n case \"darwin\": {\n // let installationInfo: InstallationInfo\n // try {\n // installationInfo = await setupBin(\"doxygen\", version, getDoxygenPackageInfo, setupDir, arch)\n // } catch {\n const installationInfo = await installBrewPack(\"doxygen\", undefined)\n // }\n\n // only install graphviz if the macOS version is greater than 11\n if (macosVersion()[0] > 11) {\n await setupGraphviz(getVersion(\"graphviz\", undefined), \"\", arch)\n }\n return installationInfo\n }\n case \"linux\": {\n let installationInfo: InstallationInfo\n if (version === \"\" || isArch() || hasDnf()) {\n if (isArch()) {\n installationInfo = await setupPacmanPack(\"doxygen\", version)\n } else if (hasDnf()) {\n return setupDnfPack([{ name: \"doxygen\", version }])\n } else if (isUbuntu()) {\n installationInfo = await installAptPack([{ name: \"doxygen\", version }])\n } else {\n throw new Error(\"Unsupported linux distributions\")\n }\n } else if (isUbuntu()) {\n try {\n // doxygen on stable Ubuntu repositories is very old. So, we use get the binary from the website itself\n installationInfo = await setupBin(\"doxygen\", version, getDoxygenPackageInfo, setupDir, arch)\n try {\n await installAptPack([{ name: \"libclang-cpp9\" }])\n } catch (err) {\n info(`Failed to download libclang-cpp9 that might be needed for running doxygen. ${err}`)\n }\n } catch (err) {\n notice(`Failed to download doxygen binary. ${err}. Falling back to apt-get.`)\n installationInfo = await installAptPack([{ name: \"doxygen\" }])\n }\n } else {\n throw new Error(\"Unsupported linux distributions\")\n }\n await setupGraphviz(getVersion(\"graphviz\", undefined, await ubuntuVersion()), \"\", arch)\n return installationInfo\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n}\n\nasync function activateWinDoxygen() {\n switch (process.platform) {\n case \"win32\": {\n for (\n const binDir of [\n \"C:/ProgramData/chocolatey/bin\",\n \"C:/Program Files/doxygen/bin\",\n \"C:/Program Files (x86)/doxygen\",\n ]\n ) {\n // eslint-disable-next-line no-await-in-loop\n if (await pathExists(join(binDir, \"doxygen.exe\"))) {\n // eslint-disable-next-line no-await-in-loop\n await addPath(binDir, rcOptions)\n return binDir\n }\n }\n throw new Error(\"Failed to find doxygen binary\")\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n}\n","import { getExecOutput } from \"@actions/exec\"\nimport { error } from \"ci-log\"\nimport { addEnv } from \"envosman\"\nimport { rcOptions } from \"../cli-options.js\"\n\nexport async function setupMacOSSDK() {\n if (process.platform === \"darwin\") {\n try {\n const xcrun = await getExecOutput(\"xcrun --sdk macosx --show-sdk-path\")\n const sdkroot = xcrun.stdout || xcrun.stderr\n if (sdkroot) {\n await addEnv(\"SDKROOT\", sdkroot.trim(), rcOptions)\n } else {\n error(\"SDKROOT not set\")\n }\n } catch (e) {\n error(e as Error | string)\n }\n }\n}\n","import { join } from \"path\"\nimport { info, warning } from \"ci-log\"\nimport { pathExists } from \"path-exists\"\nimport { dirname } from \"./gcc.ts\"\n\nexport async function addGccLoggingMatcher() {\n const matcherPath = join(dirname, \"gcc_matcher.json\")\n if (!(await pathExists(matcherPath))) {\n return warning(\"the gcc_matcher.json file does not exist in the same folder as setup-cpp.js\")\n }\n info(`::add-matcher::${matcherPath}`)\n}\n","import { readFile } from \"fs/promises\"\nimport semverSatisfies from \"semver/functions/satisfies.js\"\nimport { semverCoercedRangeIfInvalid } from \"../setup/version.ts\"\n\n/**\n * The list of assets\n * @key tag The tag of the release\n * @value assets The names of the assets of the release\n */\nexport type Assets = Record<string, string[] | undefined>\n\n/**\n * Load the list of assets from a json file\n */\nexport async function loadAssetList(path: string): Promise<Assets> {\n const data = await readFile(path, \"utf-8\")\n return JSON.parse(data)\n}\n\n/**\n * The options to match the asset\n */\nexport type MatchAssetOpts = {\n /**\n * The version to match\n */\n version: string\n /**\n * The keywords that must be in the asset name\n * @default []\n */\n keywords?: string[]\n /**\n * Optional keywords that are not required to be in the asset name\n * but increase the score of the asset if they are present\n * @default []\n */\n optionalKeywords?: string[]\n /**\n * Custom version compare function\n * @param candidate The candidate version\n * @param coeredVersion The coerced version to compare against\n * @returns true if the candidate version satisfies the version\n *\n * @default semverSatisfies\n */\n versionSatisfies?: (candidate: string, coeredVersion: string) => boolean\n /**\n * Custom tag filter and map function\n * @param tag The tag to filter and map\n * @returns The mapped tag or undefined if the tag should be\n * excluded from the search\n * @default undefined\n */\n filterMapTag?: (tag: string) => string | undefined\n /**\n * Custom asset name filter function\n * @param asset The asset name to filter\n * @returns true if the asset should be included in the search\n * @default undefined\n */\n filterName?: (asset: string) => boolean\n}\n\n/**\n * Match the asset that matches the version and given keywords\n * @param assets The list of assets\n * @param opts The options to match the asset\n * @returns The tag and name of the asset that matches the version and keywords\n */\nexport function matchAsset(\n assets: Assets,\n opts: MatchAssetOpts,\n): { tag: string; name: string } | undefined {\n // get the list of versions\n const origTags = Object.keys(assets)\n\n // filter/map the tags\n const versionMap: Map<string, string> = new Map()\n if (opts.filterMapTag === undefined) {\n for (const origTag of origTags) {\n versionMap.set(origTag, origTag)\n }\n } else {\n for (const origTag of origTags) {\n const mappedTag = opts.filterMapTag(origTag)\n if (mappedTag !== undefined) {\n versionMap.set(mappedTag, origTag)\n }\n }\n }\n\n if (versionMap.size === 0) {\n return undefined\n }\n\n // Assume the version is a semver version if a custom version compare function is not given\n const versionSatisfies: (c: string, v: string) => boolean = opts.versionSatisfies ?? semverSatisfies\n\n // If not a valid semver version, coerce it to a semver version range\n const versionRange = semverCoercedRangeIfInvalid(opts.version)\n\n // find the first tag that starts with the version\n // loop over the versions starting with the latest\n const candidateTags: string[] = []\n for (const [version, origTag] of versionMap.entries()) {\n if (versionSatisfies(version, versionRange)) {\n candidateTags.push(origTag)\n }\n }\n\n if (candidateTags.length === 0) {\n return undefined\n }\n\n // Loop over the candidate tags and return the first one that has assets\n for (const candidateTag of candidateTags) {\n // get the list of assets\n let assetNames = assets[candidateTag]\n if (assetNames === undefined) {\n continue\n }\n\n // filter the assets\n if (opts.filterName !== undefined) {\n assetNames = assetNames.filter(opts.filterName)\n }\n\n if (assetNames.length === 0) {\n continue\n }\n\n // check if this version contains the keywords and optional keywords in the asset name\n const match = matchAssetName(candidateTag, assetNames, opts)\n if (match !== undefined) {\n return match\n }\n }\n\n return undefined\n}\n\nfunction matchAssetName(tag: string, assetNames: string[], opts: MatchAssetOpts) {\n // if no keywords are given, return the first asset\n if (\n (opts.keywords === undefined\n || opts.keywords.length === 0)\n && (opts.optionalKeywords === undefined\n || opts.optionalKeywords.length === 0)\n ) {\n return { tag, name: assetNames[0] }\n }\n\n // check if the asset contains all the keywords\n let candidates: string[] = []\n if (\n opts.keywords !== undefined\n && opts.keywords.length !== 0\n ) {\n for (const name of assetNames) {\n if (opts.keywords!.every((keyword) => name.includes(keyword))) {\n candidates.push(name)\n }\n }\n } else {\n candidates = assetNames\n }\n\n if (candidates.length === 0) {\n return undefined\n }\n\n // prefer the candidates that contain more optional keywords\n if (\n opts.optionalKeywords !== undefined\n && opts.optionalKeywords.length !== 0\n ) {\n // rate the candidates based on the number of optional keywords they contain\n const candidateScores = candidates.map((name) => {\n let score = 0\n for (const keyword of opts.optionalKeywords!) {\n if (name.includes(keyword)) {\n score++\n }\n }\n return score\n })\n\n // find the candidate with the highest score\n const maxScore = Math.max(...candidateScores)\n const maxIndex = candidateScores.indexOf(maxScore)\n return { tag, name: candidates[maxIndex] }\n }\n\n // return the first candidate if no optional keywords are given\n return { tag, name: candidates[0] }\n}\n","import path, { join } from \"path\"\nimport { fileURLToPath } from \"url\"\nimport ciInfo from \"ci-info\"\nconst { GITHUB_ACTIONS } = ciInfo\nimport { info } from \"ci-log\"\nimport { addEnv, addPath } from \"envosman\"\nimport { pathExists } from \"path-exists\"\nimport { addExeExt } from \"patha\"\nimport semverCoerce from \"semver/functions/coerce.js\"\nimport semverSatisfies from \"semver/functions/satisfies.js\"\nimport { installAptPack } from \"setup-apt\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { loadAssetList, matchAsset } from \"../utils/asset/load-assets.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport { extract7Zip } from \"../utils/setup/extract.js\"\nimport { type InstallationInfo, type PackageInfo, setupBin } from \"../utils/setup/setupBin.js\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\nimport { addGccLoggingMatcher } from \"./gccMatcher.js\"\n\nconst dirname = typeof __dirname === \"string\" ? __dirname : path.dirname(fileURLToPath(import.meta.url))\n\nexport async function setupMingw(version: string, setupDir: string, arch: string) {\n let installationInfo: InstallationInfo | undefined\n switch (process.platform) {\n case \"win32\": {\n if (arch === \"arm\" || arch === \"arm64\") {\n installationInfo = await setupChocoPack(\"gcc-arm-embedded\", version)\n }\n try {\n installationInfo = await setupBin(\"g++\", version, getMinGWPackageInfo, setupDir, arch)\n } catch (err) {\n info(`Failed to download g++ binary. ${err}. Falling back to chocolatey.`)\n installationInfo = await setupChocoMingw(version, arch)\n }\n break\n }\n case \"linux\": {\n if (isArch()) {\n installationInfo = await setupPacmanPack(\"mingw-w64-gcc\", version)\n } else if (hasDnf()) {\n installationInfo = await setupDnfPack([{ name: \"mingw64-gcc\", version }])\n } else if (isUbuntu()) {\n installationInfo = await installAptPack([\n {\n name: \"mingw-w64\",\n version,\n repository: \"ppa:ubuntu-toolchain-r/test\",\n key: { key: \"1E9377A2BA9EF27F\", fileName: \"ubuntu-toolchain-r-test.gpg\" },\n },\n ])\n } else {\n throw new Error(`Unsupported Linux distro for ${arch}`)\n }\n break\n }\n default: {\n throw new Error(`Unsupported platform for ${arch}`)\n }\n }\n\n if (installationInfo !== undefined) {\n await activateMinGW(installationInfo.binDir)\n }\n\n return installationInfo\n}\n\nasync function setupChocoMingw(version: string, arch: string): Promise<InstallationInfo | undefined> {\n await setupChocoPack(\"mingw\", version)\n let binDir: string | undefined\n if (arch === \"x64\" && (await pathExists(\"C:/tools/mingw64/bin\"))) {\n binDir = \"C:/tools/mingw64/bin\"\n await addPath(binDir, rcOptions)\n } else if (arch === \"ia32\" && (await pathExists(\"C:/tools/mingw32/bin\"))) {\n binDir = \"C:/tools/mingw32/bin\"\n await addPath(binDir, rcOptions)\n } else if (await pathExists(`${process.env.ChocolateyInstall ?? \"C:/ProgramData/chocolatey\"}/bin/g++.exe`)) {\n binDir = `${process.env.ChocolateyInstall ?? \"C:/ProgramData/chocolatey\"}/bin`\n }\n if (binDir !== undefined) {\n return { binDir }\n }\n return undefined\n}\n\nexport async function getMinGWPackageInfo(\n version: string,\n platform: NodeJS.Platform,\n arch: string,\n): Promise<PackageInfo> {\n if (platform !== \"win32\") {\n throw new Error(`Unsupported platform '${platform}'`)\n }\n\n const mingwAssets = await loadAssetList(\n join(dirname, \"github_brechtsanders_winlibs_mingw.json\"),\n )\n\n const mingwArchMap = {\n x64: \"x86_64\",\n ia32: \"i386\",\n } as Record<string, string | undefined>\n\n const runtime = extractMinGWRuntime(version)\n const threadModel = extractMinGWThreadModel(version)\n const exceptionModel = extractMingwExceptionModel(version)\n\n const asset = matchAsset(\n mingwAssets,\n {\n version,\n keywords: [\n mingwArchMap[arch] ?? arch,\n ],\n filterName: (assetName) => {\n return (runtime === undefined || runtime === extractMinGWRuntime(assetName))\n && (threadModel === undefined || threadModel === extractMinGWThreadModel(assetName))\n && (exceptionModel === undefined || exceptionModel === extractMingwExceptionModel(assetName))\n },\n versionSatisfies: (assetVersion, versionRange) => {\n // extract the base version by coercing the version\n const assetCoerce = semverCoerce(assetVersion)\n if (assetCoerce === null) {\n throw new Error(`Invalid MinGW asset version: '${assetVersion}'`)\n }\n\n // if the asset version is satisfied by the version\n // and the runtime and thread model match or not specified\n return semverSatisfies(assetCoerce, versionRange)\n && (runtime === undefined || runtime === extractMinGWRuntime(assetVersion))\n && (threadModel === undefined || threadModel === extractMinGWThreadModel(assetVersion))\n },\n },\n )\n\n if (asset === undefined) {\n throw new Error(`No asset found for version ${version} and arch ${arch}`)\n }\n\n return {\n binRelativeDir: \"bin/\",\n binFileName: addExeExt(\"g++\"),\n extractedFolderName: \"mingw64\",\n extractFunction: extract7Zip,\n url: `https://github.com/brechtsanders/winlibs_mingw/releases/download/${asset.tag}/${asset.name}`,\n }\n}\n\n/**\n * Extract the runtime used by the MinGW asset/version\n * @param input The input to extract the runtime from\n *\n * @example\n * extractMinGWRuntime(\"14.2.0posix-18.1.8-12.0.0-ucrt-r1\") // \"ucrt\"\n * extractMinGWRuntime(\"10.5.0-11.0.1-msvcrt-r2\") // \"msvcrt\"\n * extractMinGWRuntime(\"11.1.0-12.0.0-9.0.0-r1\") // undefined\n */\nfunction extractMinGWRuntime(input: string) {\n const match = input.match(/(ucrt|msvcrt)/)\n return match !== null ? match[1] : undefined\n}\n\n/**\n * Extract the thread model used by the MinGW asset/version\n * @param input The input to extract the thread model from\n *\n * @example\n * extractMinGWThreadModel(\"14.2.0posix-18.1.8-12.0.0-ucrt-r1\") // \"posix\"\n * extractMinGWThreadModel(\"14.2.0mcf-12.0.0-ucrt-r1\") // \"mcf\"\n * extractMinGWThreadModel(\"10.5.0-11.0.1-msvcrt-r2\") // undefined\n * extractMinGWThreadModel(\"11.1.0-12.0.0-9.0.0-r1\") // undefined\n */\nfunction extractMinGWThreadModel(input: string) {\n const match = input.match(/(posix|mcf)/)\n return match !== null ? match[1] : undefined\n}\n\n/**\n * Extract the exception model used by the MinGW asset/version\n *\n * @param input The input to extract the exception model from\n *\n * @example\n * extractMingwExceptionModel(\"14.2.0posix-18.1.8-12.0.0-ucrt-r1\") // \"seh\"\n * extractMingwExceptionModel(\"14.2.0mcf-12.0.0-ucrt-r1\") // undefined\n * extractMingwExceptionModel(\"10.5.0-11.0.1-msvcrt-r2\") // \"dwarf\"\n */\nfunction extractMingwExceptionModel(input: string) {\n const match = input.match(/(seh|dwarf)/)\n return match !== null ? match[1] : undefined\n}\n\nasync function activateMinGW(binDir: string) {\n const promises: Promise<void>[] = []\n\n if (process.platform === \"win32\") {\n promises.push(\n addEnv(\"CC\", addExeExt(`${binDir}/gcc`), rcOptions),\n addEnv(\"CXX\", addExeExt(`${binDir}/g++`), rcOptions),\n )\n }\n\n // TODO add update-alternatives for Ubuntu\n // Setting up g++-mingw-w64-i686-win32 (10.3.0-14ubuntu1+24.3) ...\n // update-alternatives: using /usr/bin/i686-w64-mingw32-g++-win32 to provide /usr/bin/i686-w64-mingw32-g++ (i686-w64-mingw32-g++) in auto mode\n // Setting up g++-mingw-w64-x86-64-win32 (10.3.0-14ubuntu1+24.3) ...\n // update-alternatives: using /usr/bin/x86_64-w64-mingw32-g++-win32 to provide /usr/bin/x86_64-w64-mingw32-g++ (x86_64-w64-mingw32-g++) in auto mode\n\n if (GITHUB_ACTIONS) {\n await addGccLoggingMatcher()\n }\n\n await Promise.all(promises)\n}\n","import path from \"path\"\nimport { fileURLToPath } from \"url\"\nimport ciInfo from \"ci-info\"\nconst { GITHUB_ACTIONS } = ciInfo\nimport { error, info, warning } from \"ci-log\"\nimport { addEnv } from \"envosman\"\nimport { execa } from \"execa\"\nimport { readdir } from \"fs/promises\"\nimport { pathExists } from \"path-exists\"\nimport semverCoerce from \"semver/functions/coerce\"\nimport semverMajor from \"semver/functions/major\"\nimport { addUpdateAlternativesToRc, installAptPack } from \"setup-apt\"\nimport { installBrewPack } from \"setup-brew\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { setupMacOSSDK } from \"../macos-sdk/macos-sdk.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport type { InstallationInfo } from \"../utils/setup/setupBin.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\nimport { compareVersion } from \"../utils/setup/version.js\"\nimport { addGccLoggingMatcher } from \"./gccMatcher.js\"\nimport { setupMingw } from \"./mingw.js\"\n\nexport const dirname = typeof __dirname === \"string\" ? __dirname : path.dirname(fileURLToPath(import.meta.url))\n\nexport async function setupGcc(version: string, setupDir: string, arch: string, priority: number = 40) {\n let installationInfo: InstallationInfo | undefined\n switch (process.platform) {\n case \"win32\": {\n installationInfo = await setupMingw(version, setupDir, arch)\n break\n }\n case \"darwin\": {\n installationInfo = await installBrewPack(\"gcc\", version)\n break\n }\n case \"linux\": {\n if (arch === \"x64\") {\n if (isArch()) {\n installationInfo = await setupPacmanPack(\"gcc\", version)\n } else if (hasDnf()) {\n installationInfo = await setupDnfPack([\n { name: \"gcc\", version },\n { name: \"gcc-c++\", version },\n { name: \"libstdc++-devel\" },\n ])\n } else if (isUbuntu()) {\n if (version === \"\") {\n // the default version\n installationInfo = await installAptPack([{ name: \"gcc\" }, { name: \"g++\" }])\n } else {\n // add the PPA for access to more versions\n installationInfo = await installAptPack([\n {\n name: \"gcc\",\n version,\n repository: \"ppa:ubuntu-toolchain-r/test\",\n key: { key: \"1E9377A2BA9EF27F\", fileName: \"ubuntu-toolchain-r-test.gpg\" },\n },\n {\n name: \"g++\",\n version,\n repository: \"ppa:ubuntu-toolchain-r/test\",\n key: { key: \"1E9377A2BA9EF27F\", fileName: \"ubuntu-toolchain-r-test.gpg\" },\n },\n ])\n }\n }\n } else {\n info(`Install g++-multilib because gcc for ${arch} was requested`)\n if (isArch()) {\n installationInfo = await setupPacmanPack(\"gcc-multilib\", version)\n } else if (isUbuntu()) {\n if (version === \"\") {\n // the default version\n installationInfo = await installAptPack([{ name: \"gcc-multilib\" }])\n } else {\n // add the PPA for access to more versions\n installationInfo = await installAptPack([{\n name: \"gcc-multilib\",\n version,\n repository: \"ppa:ubuntu-toolchain-r/test\",\n key: { key: \"1E9377A2BA9EF27F\", fileName: \"ubuntu-toolchain-r-test.gpg\" },\n }])\n }\n }\n }\n break\n }\n // TODO support bare-metal (need to support passing it as the input)\n // TODO support abi\n // case \"none\": {\n // if (arch === \"arm\" || arch === \"arm64\") {\n // return installAptPack(\"gcc-arm-none-eabi\", version, [\n // \"ppa:ubuntu-toolchain-r/test\",\n // ])\n // } else {\n // throw new Error(`Unsupported platform for ${arch}`)\n // }\n // }\n default: {\n throw new Error(`Unsupported platform for ${arch}`)\n }\n }\n if (installationInfo !== undefined) {\n await activateGcc(version, installationInfo.binDir, priority)\n return installationInfo\n }\n return undefined\n}\n\n/**\n * Setup gcc as the compiler on Linux and macOS\n */\nasync function activateGcc(givenVersion: string, binDir: string, priority: number = 40) {\n if (process.platform === \"win32\") {\n // already done in setupMingw\n return\n }\n\n const promises: Promise<void>[] = []\n\n {\n // if version is empty, get the version from the gcc command\n let version = givenVersion\n if (givenVersion === \"\") {\n version = await getGccCmdVersion(binDir, version)\n info(`Using gcc version ${version}`)\n }\n\n const majorVersion = semverMajor(semverCoerce(version) ?? version)\n if (majorVersion >= 5) {\n promises.push(\n addEnv(\"CC\", `${binDir}/gcc-${majorVersion}`, rcOptions),\n addEnv(\"CXX\", `${binDir}/g++-${majorVersion}`, rcOptions),\n )\n\n if (isUbuntu()) {\n promises.push(\n addUpdateAlternativesToRc(\"cc\", `${binDir}/gcc-${majorVersion}`, rcOptions, priority),\n addUpdateAlternativesToRc(\"cxx\", `${binDir}/g++-${majorVersion}`, rcOptions, priority),\n addUpdateAlternativesToRc(\"gcc\", `${binDir}/gcc-${majorVersion}`, rcOptions, priority),\n addUpdateAlternativesToRc(\"g++\", `${binDir}/g++-${majorVersion}`, rcOptions, priority),\n )\n }\n } else {\n promises.push(\n addEnv(\"CC\", `${binDir}/gcc-${version}`, rcOptions),\n addEnv(\"CXX\", `${binDir}/g++-${version}`, rcOptions),\n )\n\n if (isUbuntu()) {\n promises.push(\n addUpdateAlternativesToRc(\"cc\", `${binDir}/gcc-${version}`, rcOptions, priority),\n addUpdateAlternativesToRc(\"cxx\", `${binDir}/g++-${version}`, rcOptions, priority),\n addUpdateAlternativesToRc(\"gcc\", `${binDir}/gcc-${version}`, rcOptions, priority),\n addUpdateAlternativesToRc(\"g++\", `${binDir}/g++-${version}`, rcOptions, priority),\n )\n }\n }\n }\n\n promises.push(setupMacOSSDK())\n\n // TODO\n // const ld = process.env.LD_LIBRARY_PATH ?? \"\"\n // const dyld = process.env.DYLD_LIBRARY_PATH ?? \"\"\n // promises.push(\n // addEnv(\"LD_LIBRARY_PATH\", `${installDir}/lib${path.delimiter}${ld}`, rcOptions),\n // addEnv(\"DYLD_LIBRARY_PATH\", `${installDir}/lib${path.delimiter}${dyld}`, rcOptions),\n // addEnv(\"CPATH\", `${installDir}/lib/gcc/${majorVersion}/include`, rcOptions),\n // addEnv(\"LDFLAGS\", `-L${installDir}/lib`, rcOptions),\n // addEnv(\"CPPFLAGS\", `-I${installDir}/include`, rcOptions),\n // )\n\n if (GITHUB_ACTIONS) {\n await addGccLoggingMatcher()\n }\n\n await Promise.all(promises)\n}\n\nasync function getGccCmdVersion(binDir: string, givenVersion: string) {\n // TODO get the version from the package manager\n try {\n let gccExe = \"gcc\"\n if (await pathExists(`${binDir}/gcc`)) {\n gccExe = `${binDir}/gcc`\n } else {\n // try to find the gcc exe in the bin dir\n const files = (await readdir(binDir)).sort(\n (exe1, exe2) => {\n const version1 = exe1.match(/^gcc-?(.*)(\\.exe)?$/)?.[1] ?? \"\"\n const version2 = exe2.match(/^gcc-?(.*)(\\.exe)?$/)?.[1] ?? \"\"\n return compareVersion(version1, version2)\n },\n )\n for (const file of files) {\n if (file.startsWith(\"gcc\")) {\n gccExe = `${binDir}/${file}`\n break\n }\n }\n }\n\n const { stdout: versionStdout } = await execa(gccExe, [\"--version\"], { stdio: \"pipe\" })\n\n // gcc-11 (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0\n // gcc-12 (Homebrew GCC 12.4.0) 12.4.0\n // gcc (Ubuntu 13.1.0-8ubuntu1~22.04) 13.1.0\n\n const versionMatch = (versionStdout as string).match(/gcc.* \\(.*\\) ([\\d.]+)/)\n\n if (versionMatch !== null) {\n return versionMatch[1]\n }\n\n warning(`Failed to parse gcc version from: ${versionStdout}`)\n return givenVersion\n } catch (err) {\n error(`Failed to get gcc version: ${err}`)\n return givenVersion\n }\n}\n","import { addEnv } from \"envosman\"\nimport semverMajor from \"semver/functions/major\"\nimport semverValid from \"semver/functions/valid\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { setupPipPack } from \"../utils/setup/setupPipPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport function setupGcovr(version: string | undefined, _setupDir: string, _arch: string) {\n return setupPipPack(\"gcovr\", version)\n}\n\nexport function activateGcovLLVM() {\n return addEnv(\"GCOV\", \"llvm-cov gcov\", rcOptions)\n}\n\nexport function activateGcovGCC(gccVersion: string) {\n const gccSemver = semverValid(gccVersion)\n const gccMajor = gccSemver !== null ? semverMajor(gccSemver) : gccVersion\n const gcov = gccMajor !== \"\" ? `gcov-${gccMajor}` : \"gcov\"\n\n return addEnv(\"GCOV\", gcov, rcOptions)\n}\n","import path, { basename, join } from \"path\"\nimport { fileURLToPath } from \"url\"\nimport { info } from \"ci-log\"\nimport { addExeExt } from \"patha\"\nimport { loadAssetList, matchAsset } from \"../utils/asset/load-assets.js\"\nimport { arm64, x86_64 } from \"../utils/env/arch.js\"\nimport { type InstallationInfo, type PackageInfo, setupBin } from \"../utils/setup/setupBin.js\"\n\nconst dirname = typeof __dirname === \"string\" ? __dirname : path.dirname(fileURLToPath(import.meta.url))\n\n/** Get the platform data for infer */\nasync function getInferPackageInfo(version: string, platform: NodeJS.Platform, arch: string): Promise<PackageInfo> {\n const { keywords, optionalKeywords } = getAssetKeywords(platform, arch)\n\n // first check the github releases\n const inferGitHubAssets = await loadAssetList(\n join(dirname, \"github_facebook_infer.json\"),\n )\n const ghAsset = matchAsset(\n inferGitHubAssets,\n {\n version,\n keywords,\n optionalKeywords,\n filterMapTag(tag) {\n return tag.replace(/^v/, \"\")\n },\n },\n )\n\n if (ghAsset !== undefined) {\n return {\n url: `https://github.com/facebook/infer/releases/download/${ghAsset.tag}/${ghAsset.name}`,\n extractedFolderName: `${basename(ghAsset.name, \".tar.xz\")}`,\n binRelativeDir: \"bin\",\n binFileName: addExeExt(\"infer\"),\n }\n }\n\n throw new Error(`No asset found for version ${version} matching ${keywords} and ${optionalKeywords}`)\n}\n\n/** Setup infer */\nexport function setupInfer(version: string, setupDir: string, arch: string): Promise<InstallationInfo> {\n return setupBin(\"infer\", version, getInferPackageInfo, setupDir, arch)\n}\n\nfunction getAssetKeywords(platform: string, arch: string) {\n const keywords: string[] = []\n const optionalKeywords: string[] = []\n\n switch (platform) {\n case \"linux\": {\n keywords.push(\"linux\")\n\n if (x86_64.includes(arch)) {\n optionalKeywords.push(\"64\")\n optionalKeywords.push(\"x86_64\")\n } else {\n info(`Using arch ${arch} for infer`)\n keywords.push(arch)\n }\n break\n }\n case \"darwin\": {\n keywords.push(\"osx\")\n\n if (x86_64.includes(arch)) {\n optionalKeywords.push(\"x86_64\")\n } else if (arm64.includes(arch)) {\n // allow falling back to x86_64 if arm64 is not available\n optionalKeywords.push(\"arm64\")\n } else {\n info(`Using arch ${arch} for infer`)\n keywords.push(arch)\n }\n break\n }\n default:\n info(`Using ${platform} ${arch} for infer`)\n keywords.push(platform, arch)\n break\n }\n return { keywords, optionalKeywords }\n}\n","import { addExeExt } from \"patha\"\nimport { arm64, x86, x86_64 } from \"../utils/env/arch.js\"\nimport { type InstallationInfo, type PackageInfo, setupBin } from \"../utils/setup/setupBin.js\"\n\n/** Get the platform name Ninja uses in their download links */\nfunction getNinjaPlatformArch(platform: NodeJS.Platform, arch: string) {\n switch (platform) {\n case \"win32\":\n return x86_64.includes(arch)\n || x86.includes(arch)\n ? \"win\"\n : arm64.includes(arch)\n ? \"winarm64\"\n : \"win\"\n case \"darwin\":\n return \"mac\"\n case \"linux\":\n return x86_64.includes(arch)\n || x86.includes(arch)\n ? \"linux\"\n : arm64.includes(arch)\n ? \"linux-aarch64\"\n : \"linux\"\n default:\n throw new Error(`Unsupported platform '${platform}'`)\n }\n}\n\n/** Get the platform data for ninja */\nfunction getNinjaPackageInfo(version: string, platform: NodeJS.Platform, arch: string): PackageInfo {\n const ninjaPlatform = getNinjaPlatformArch(platform, arch)\n return {\n binRelativeDir: \"\",\n binFileName: addExeExt(\"ninja\"),\n extractedFolderName: \"\",\n url: `https://github.com/ninja-build/ninja/releases/download/v${version}/ninja-${ninjaPlatform}.zip`,\n }\n}\n\nexport function setupNinja(version: string, setupDir: string, arch: string): Promise<InstallationInfo> {\n return setupBin(\"ninja\", version, getNinjaPackageInfo, setupDir, arch)\n}\n","import path, { join } from \"path\"\nimport { fileURLToPath } from \"url\"\nimport { info } from \"ci-log\"\nimport { execa } from \"execa\"\nimport { addExeExt } from \"patha\"\nimport { installAptPack } from \"setup-apt\"\nimport { untildifyUser } from \"untildify-user\"\nimport which from \"which\"\nimport { setupCmake } from \"../cmake/cmake.js\"\nimport { setupNinja } from \"../ninja/ninja.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport { ubuntuVersion } from \"../utils/env/ubuntu_version.js\"\nimport { extractTarByExe } from \"../utils/setup/extract.js\"\nimport { type InstallationInfo, type PackageInfo, setupBin } from \"../utils/setup/setupBin.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\nimport { addVPrefix, removeVPrefix } from \"../utils/setup/version.js\"\nimport { getVersion } from \"../versions/versions.js\"\n\nconst dirname = typeof __dirname === \"string\" ? __dirname : path.dirname(fileURLToPath(import.meta.url))\n\nfunction getDownloadKcovPackageInfo(version: string): PackageInfo {\n return {\n url: `https://github.com/SimonKagstrom/kcov/releases/download/${version}/kcov-amd64.tar.gz`,\n extractedFolderName: \"\",\n binRelativeDir: \"usr/local/bin\",\n binFileName: addExeExt(\"kcov\"),\n }\n}\n\nfunction getBuildKcovPackageInfo(version: string): PackageInfo {\n return {\n url: `https://github.com/SimonKagstrom/kcov/archive/refs/tags/${version}.tar.gz`,\n extractedFolderName: \"\",\n binRelativeDir: \"build/src\",\n binFileName: addExeExt(\"kcov\"),\n extractFunction: buildKcov,\n }\n}\n\nasync function buildKcov(file: string, dest: string) {\n const out = await extractTarByExe(file, dest, 1)\n\n // build after extraction using CMake\n const cmake = await getCmake()\n\n if (process.platform === \"linux\") {\n if (isArch()) {\n await Promise.all([setupPacmanPack(\"libdwarf\"), setupPacmanPack(\"libcurl-openssl\")])\n } else if (hasDnf()) {\n await setupDnfPack([{ name: \"libdwarf-devel\" }, { name: \"libcurl-devel\" }])\n } else if (isUbuntu()) {\n await installAptPack([{ name: \"libdw-dev\" }, { name: \"libcurl4-openssl-dev\" }])\n }\n }\n\n // apply gcc13.patch\n try {\n if (which.sync(\"patch\", { nothrow: true }) !== null) {\n const patch = join(dirname, \"gcc13.patch\")\n await execa(\"patch\", [\"-N\", \"-p1\", \"-i\", patch], { cwd: out, stdio: \"inherit\" })\n } else {\n info(\"`patch` not found, skipping gcc13.patch, kcov may not build on gcc 13\")\n }\n } catch {\n // ignore\n }\n\n const buildDir = join(out, \"build\")\n await execa(cmake, [\"-S\", out, \"-B\", buildDir, \"-DCMAKE_BUILD_TYPE=Release\", \"-G\", \"Ninja\"], {\n cwd: out,\n stdio: \"inherit\",\n })\n await execa(cmake, [\"--build\", buildDir, \"--config\", \"Release\"], { cwd: out, stdio: \"inherit\" })\n // execRootSync(cmake, [\"--install\", buildDir], out)\n // return \"user/local/bin\" // the cmake install prefix\n return out\n}\n\nasync function getCmake() {\n let cmake = which.sync(\"cmake\", { nothrow: true })\n if (cmake === null) {\n const { binDir } = await setupCmake(\n getVersion(\"cmake\", undefined, await ubuntuVersion()),\n join(untildifyUser(\"~\"), \"cmake\"),\n \"\",\n )\n cmake = join(binDir, \"cmake\")\n }\n const ninja = which.sync(\"ninja\", { nothrow: true })\n if (ninja === null) {\n await setupNinja(getVersion(\"ninja\", undefined, await ubuntuVersion()), join(untildifyUser(\"~\"), \"ninja\"), \"\")\n }\n return cmake\n}\n\nexport async function setupKcov(versionGiven: string, setupDir: string, arch: string) {\n if (process.platform !== \"linux\") {\n info(\"Kcov is not supported on non-linux\")\n return\n }\n\n // parse version\n const versionSplit = versionGiven.split(\"-\")\n let version = addVPrefix(versionSplit[0])\n const installMethod = versionSplit[1] as \"binary\" | undefined\n const version_number = removeVPrefix(version)\n // fix inconsistency in tagging\n if (version_number === 38) {\n version = \"v38\"\n }\n\n let installationInfo: InstallationInfo\n if (installMethod === \"binary\" && version_number >= 39) {\n installationInfo = await setupBin(\"kcov\", version, getDownloadKcovPackageInfo, setupDir, arch)\n if (isArch()) {\n await setupPacmanPack(\"binutils\")\n } else if (hasDnf()) {\n await setupDnfPack([{ name: \"binutils\" }])\n } else if (isUbuntu()) {\n await installAptPack([{ name: \"libbinutils\" }])\n }\n return installationInfo\n } else {\n installationInfo = await setupBin(\"kcov\", version, getBuildKcovPackageInfo, setupDir, arch)\n }\n return installationInfo\n}\n","import { error } from \"console\"\nimport { notice } from \"ci-log\"\nimport { addEnv } from \"envosman\"\nimport which from \"which\"\nimport { rcOptions } from \"../cli-options.js\"\n\nexport async function setupAppleClang() {\n if (process.platform !== \"darwin\") {\n return\n }\n\n if (await which(\"clang\", { nothrow: true }) !== null && await which(\"clang++\", { nothrow: true }) !== null) {\n notice(\"Assuming clang is an Apple Clang compiler\")\n await Promise.all([addEnv(\"CC\", \"clang\", rcOptions), addEnv(\"CXX\", \"clang++\", rcOptions)])\n }\n\n // TODO install Apple Clang automatically\n error(\"Apple Clang automatic installation is not supported yet\")\n}\n","const core = require('@actions/core')\nconst child_process = require('child_process')\nconst fs = require('fs')\nconst path = require('path')\nconst process = require('process')\n\nconst PROGRAM_FILES_X86 = process.env['ProgramFiles(x86)']\nconst PROGRAM_FILES = [process.env['ProgramFiles(x86)'], process.env['ProgramFiles']]\n\n\nconst EDITIONS = ['Enterprise', 'Professional', 'Community', 'BuildTools']\nconst YEARS = ['2022', '2019', '2017']\n\nconst VsYearVersion = {\n '2022': '17.0',\n '2019': '16.0',\n '2017': '15.0',\n '2015': '14.0',\n '2013': '12.0',\n}\n\n/**\n * Convert the vs version (e.g. 2022) or year (e.g. 17.0) to the version number (e.g. 17.0)\n * @param {string | undefined} vsversion the year (e.g. 2022) or version number (e.g. 17.0)\n * @returns {string | undefined} the version number (e.g. 17.0)\n */\nfunction vsversion_to_versionnumber(vsversion) {\n if (Object.values(VsYearVersion).includes(vsversion)) {\n return vsversion\n } else {\n if (vsversion in VsYearVersion) {\n return VsYearVersion[vsversion]\n }\n }\n return vsversion\n}\nexports.vsversion_to_versionnumber = vsversion_to_versionnumber\n\n/**\n * Convert the vs version (e.g. 17.0) or year (e.g. 2022) to the year (e.g. 2022)\n * @param {string} vsversion the version number (e.g. 17.0) or year (e.g. 2022)\n * @returns {string} the year (e.g. 2022)\n */\nfunction vsversion_to_year(vsversion) {\n if (Object.keys(VsYearVersion).includes(vsversion)) {\n return vsversion\n } else {\n for (const [year, ver] of Object.entries(VsYearVersion)) {\n if (ver === vsversion) {\n return year\n }\n }\n }\n return vsversion\n}\nexports.vsversion_to_year = vsversion_to_year\n\nconst VSWHERE_PATH = `${PROGRAM_FILES_X86}\\\\Microsoft Visual Studio\\\\Installer`\n\n/**\n * Find MSVC tools with vswhere\n * @param {string} pattern the pattern to search for\n * @param {string} version_pattern the version pattern to search for\n * @returns {string | null} the path to the found MSVC tools\n */\nfunction findWithVswhere(pattern, version_pattern) {\n try {\n let installationPath = child_process.execSync(`vswhere -products * ${version_pattern} -prerelease -property installationPath`).toString().trim()\n return installationPath + '\\\\' + pattern\n } catch (e) {\n core.warning(`vswhere failed: ${e}`)\n }\n return null\n}\nexports.findWithVswhere = findWithVswhere\n\n/**\n * Find the vcvarsall.bat file for the given Visual Studio version\n * @param {string | undefined} vsversion the version of Visual Studio to find (year or version number)\n * @returns {string} the path to the vcvarsall.bat file\n */\nfunction findVcvarsall(vsversion) {\n const vsversion_number = vsversion_to_versionnumber(vsversion)\n let version_pattern\n if (vsversion_number) {\n const upper_bound = vsversion_number.split('.')[0] + '.9'\n version_pattern = `-version \"${vsversion_number},${upper_bound}\"`\n } else {\n version_pattern = \"-latest\"\n }\n\n // If vswhere is available, ask it about the location of the latest Visual Studio.\n let path = findWithVswhere('VC\\\\Auxiliary\\\\Build\\\\vcvarsall.bat', version_pattern)\n if (path && fs.existsSync(path)) {\n core.info(`Found with vswhere: ${path}`)\n return path\n }\n core.info(\"Not found with vswhere\")\n\n // If that does not work, try the standard installation locations,\n // starting with the latest and moving to the oldest.\n const years = vsversion ? [vsversion_to_year(vsversion)] : YEARS\n for (const prog_files of PROGRAM_FILES) {\n for (const ver of years) {\n for (const ed of EDITIONS) {\n path = `${prog_files}\\\\Microsoft Visual Studio\\\\${ver}\\\\${ed}\\\\VC\\\\Auxiliary\\\\Build\\\\vcvarsall.bat`\n core.info(`Trying standard location: ${path}`)\n if (fs.existsSync(path)) {\n core.info(`Found standard location: ${path}`)\n return path\n }\n }\n }\n }\n core.info(\"Not found in standard locations\")\n\n // Special case for Visual Studio 2015 (and maybe earlier), try it out too.\n path = `${PROGRAM_FILES_X86}\\\\Microsoft Visual C++ Build Tools\\\\vcbuildtools.bat`\n if (fs.existsSync(path)) {\n core.info(`Found VS 2015: ${path}`)\n return path\n }\n core.info(`Not found in VS 2015 location: ${path}`)\n\n throw new Error('Microsoft Visual Studio not found')\n}\nexports.findVcvarsall = findVcvarsall\n\nfunction isPathVariable(name) {\n const pathLikeVariables = ['PATH', 'INCLUDE', 'LIB', 'LIBPATH']\n return pathLikeVariables.indexOf(name.toUpperCase()) != -1\n}\n\nfunction filterPathValue(path) {\n let paths = path.split(';')\n // Remove duplicates by keeping the first occurance and preserving order.\n // This keeps path shadowing working as intended.\n function unique(value, index, self) {\n return self.indexOf(value) === index\n }\n return paths.filter(unique).join(';')\n}\n\n/**\n * Setup MSVC Developer Command Prompt\n * @param {string} arch - Target architecture\n * @param {string | undefined} sdk - Windows SDK number to build for\n * @param {string | undefined} toolset - VC++ compiler toolset version\n * @param {boolean | 'true' | 'false' | undefined} uwp - Build for Universal Windows Platform\n * @param {boolean | 'true' | 'false' | undefined} spectre - Enable Spectre mitigations\n * @param {string | undefined} vsversion - The Visual Studio version to use. This can be the version number (e.g. 16.0 for 2019) or the year (e.g. \"2019\").\n */\nfunction setupMSVCDevCmd(arch, sdk, toolset, uwp, spectre, vsversion) {\n if (process.platform != 'win32') {\n core.info('This is not a Windows virtual environment, bye!')\n return\n }\n\n // Add standard location of \"vswhere\" to PATH, in case it's not there.\n process.env.PATH += path.delimiter + VSWHERE_PATH\n\n // There are all sorts of way the architectures are called. In addition to\n // values supported by Microsoft Visual C++, recognize some common aliases.\n let arch_aliases = {\n \"win32\": \"x86\",\n \"win64\": \"x64\",\n \"x86_64\": \"x64\",\n \"x86-64\": \"x64\",\n }\n // Ignore case when matching as that's what humans expect.\n if (arch.toLowerCase() in arch_aliases) {\n arch = arch_aliases[arch.toLowerCase()]\n }\n\n // Due to the way Microsoft Visual C++ is configured, we have to resort to the following hack:\n // Call the configuration batch file and then output *all* the environment variables.\n\n var args = [arch]\n\n if (uwp && JSON.parse(uwp) === true) {\n args.push('uwp')\n }\n if (sdk) {\n args.push(sdk)\n }\n if (toolset) {\n args.push(`-vcvars_ver=${toolset}`)\n }\n if (spectre && JSON.parse(spectre) === true) {\n args.push('-vcvars_spectre_libs=spectre')\n }\n\n const vcvars = `\"${findVcvarsall(vsversion)}\" ${args.join(' ')}`\n core.debug(`vcvars command-line: ${vcvars}`)\n\n const cmd_output_string = child_process.execSync(`set && cls && ${vcvars} && cls && set`, {shell: \"cmd\"}).toString()\n const cmd_output_parts = cmd_output_string.split('\\f')\n\n const old_environment = cmd_output_parts[0].split('\\r\\n')\n const vcvars_output = cmd_output_parts[1].split('\\r\\n')\n const new_environment = cmd_output_parts[2].split('\\r\\n')\n\n // If vsvars.bat is given an incorrect command line, it will print out\n // an error and *still* exit successfully. Parse out errors from output\n // which don't look like environment variables, and fail if appropriate.\n const error_messages = vcvars_output.filter((line) => {\n if (line.match(/^\\[ERROR.*\\]/)) {\n // Don't print this particular line which will be confusing in output.\n if (!line.match(/Error in script usage. The correct usage is:$/)) {\n return true\n }\n }\n return false\n })\n if (error_messages.length > 0) {\n throw new Error('invalid parameters' + '\\r\\n' + error_messages.join('\\r\\n'))\n }\n\n // Convert old environment lines into a dictionary for easier lookup.\n let old_env_vars = {}\n for (let string of old_environment) {\n const [name, value] = string.split('=')\n old_env_vars[name] = value\n }\n\n // Now look at the new environment and export everything that changed.\n // These are the variables set by vsvars.bat. Also export everything\n // that was not there during the first sweep: those are new variables.\n core.startGroup('Environment variables')\n for (let string of new_environment) {\n // vsvars.bat likes to print some fluff at the beginning.\n // Skip lines that don't look like environment variables.\n if (!string.includes('=')) {\n continue;\n }\n let [name, new_value] = string.split('=')\n let old_value = old_env_vars[name]\n // For new variables \"old_value === undefined\".\n if (new_value !== old_value) {\n core.info(`Setting ${name}`)\n // Special case for a bunch of PATH-like variables: vcvarsall.bat\n // just prepends its stuff without checking if its already there.\n // This makes repeated invocations of this action fail after some\n // point, when the environment variable overflows. Avoid that.\n if (isPathVariable(name)) {\n new_value = filterPathValue(new_value)\n }\n core.exportVariable(name, new_value)\n }\n }\n core.endGroup()\n\n core.info(`Configured Developer Command Prompt`)\n}\nexports.setupMSVCDevCmd = setupMSVCDevCmd\n","// eslint-disable-next-line @typescript-eslint/ban-ts-comment\n// @ts-ignore\nimport { info } from \"ci-log\"\nimport { addEnv } from \"envosman\"\nimport { setupMSVCDevCmd } from \"msvc-dev-cmd/lib.js\"\nimport { pathExists } from \"path-exists\"\nimport { rcOptions } from \"../cli-options.js\"\n\nfunction getArch(arch: string): string {\n switch (arch) {\n case \"x32\":\n case \"32\":\n case \"ia32\": {\n return \"x86\"\n }\n case \"64\": {\n return \"x64\"\n }\n default: {\n return arch\n }\n }\n}\n\nexport async function setupVCVarsall(\n vsversion: string,\n VCTargetsPath: string | undefined,\n arch: string,\n toolset: string | undefined,\n sdk?: string,\n uwp?: boolean,\n spectre?: boolean,\n) {\n if (VCTargetsPath !== undefined && (await pathExists(VCTargetsPath))) {\n info(`Adding ${VCTargetsPath} to PATH`)\n await addEnv(\"VCTargetsPath\", VCTargetsPath, rcOptions)\n }\n\n await setupMSVCDevCmd(getArch(arch), sdk, toolset, uwp, spectre, vsversion)\n}\n","import { join } from \"path\"\nimport { endGroup, startGroup } from \"@actions/core\"\nimport { error } from \"ci-log\"\nimport pTimeout from \"p-timeout\"\nimport { setupBrew } from \"setup-brew\"\nimport { getSuccessMessage, rcOptions } from \"./cli-options.js\"\nimport { type ToolName, llvmTools, setups } from \"./tool.js\"\nimport type { InstallationInfo } from \"./utils/setup/setupBin.js\"\nimport { setupVCVarsall } from \"./vcvarsall/vcvarsall.js\"\nimport { getVersion } from \"./versions/versions.js\"\n\nexport const DEFAULT_TIMEOUT = 20 * 60 * 1000 // 20 minutes\n\nexport async function installTool(\n tool: ToolName,\n version: string,\n osVersion: number[] | null,\n arch: string,\n setupCppDir: string,\n successMessages: string[],\n errorMessages: string[],\n timeout: number = DEFAULT_TIMEOUT,\n) {\n startGroup(`Installing ${tool} ${version}`)\n try {\n await pTimeout(installToolImpl(tool, version, osVersion, arch, setupCppDir, successMessages), {\n milliseconds: timeout,\n message: `Timeout while installing ${tool} ${version}. You can increase the timeout from options`,\n })\n } catch (e) {\n // push error message to the logger\n error(e as string | Error)\n if (e instanceof Error && e.stack !== undefined) {\n error(e.stack)\n }\n errorMessages.push(`${tool} failed to install`)\n }\n endGroup()\n}\n\nasync function installToolImpl(\n tool: ToolName,\n version: string,\n osVersion: number[] | null,\n arch: string,\n setupCppDir: string,\n successMessages: string[],\n) {\n const hasLLVM = llvmTools.includes(tool)\n\n let installationInfo: InstallationInfo | undefined | void\n if (tool === \"vcvarsall\") {\n // eslint-disable-next-line no-await-in-loop\n await setupVCVarsall(getVersion(tool, version, osVersion), undefined, arch, undefined, undefined, false, false)\n } else if (tool === \"brew\") {\n // eslint-disable no-await-in-loop\n installationInfo = await setupBrew({ rcOptions })\n } else {\n // the tool installation directory (for the functions that ue it)\n const setupDir = join(setupCppDir, hasLLVM ? \"llvm\" : tool)\n\n const setupVersion = getVersion(tool, version, osVersion)\n\n // get the setup function\n const setupFunction = setups[tool]\n\n // eslint-disable no-await-in-loop\n installationInfo = await setupFunction(setupVersion, setupDir, arch)\n }\n // preparing a report string\n successMessages.push(getSuccessMessage(tool, installationInfo))\n}\n","export class TimeoutError extends Error {\n\tconstructor(message) {\n\t\tsuper(message);\n\t\tthis.name = 'TimeoutError';\n\t}\n}\n\n/**\nAn error to be thrown when the request is aborted by AbortController.\nDOMException is thrown instead of this Error when DOMException is available.\n*/\nexport class AbortError extends Error {\n\tconstructor(message) {\n\t\tsuper();\n\t\tthis.name = 'AbortError';\n\t\tthis.message = message;\n\t}\n}\n\n/**\nTODO: Remove AbortError and just throw DOMException when targeting Node 18.\n*/\nconst getDOMException = errorMessage => globalThis.DOMException === undefined\n\t? new AbortError(errorMessage)\n\t: new DOMException(errorMessage);\n\n/**\nTODO: Remove below function and just 'reject(signal.reason)' when targeting Node 18.\n*/\nconst getAbortedReason = signal => {\n\tconst reason = signal.reason === undefined\n\t\t? getDOMException('This operation was aborted.')\n\t\t: signal.reason;\n\n\treturn reason instanceof Error ? reason : getDOMException(reason);\n};\n\nexport default function pTimeout(promise, options) {\n\tconst {\n\t\tmilliseconds,\n\t\tfallback,\n\t\tmessage,\n\t\tcustomTimers = {setTimeout, clearTimeout},\n\t} = options;\n\n\tlet timer;\n\n\tconst wrappedPromise = new Promise((resolve, reject) => {\n\t\tif (typeof milliseconds !== 'number' || Math.sign(milliseconds) !== 1) {\n\t\t\tthrow new TypeError(`Expected \\`milliseconds\\` to be a positive number, got \\`${milliseconds}\\``);\n\t\t}\n\n\t\tif (options.signal) {\n\t\t\tconst {signal} = options;\n\t\t\tif (signal.aborted) {\n\t\t\t\treject(getAbortedReason(signal));\n\t\t\t}\n\n\t\t\tsignal.addEventListener('abort', () => {\n\t\t\t\treject(getAbortedReason(signal));\n\t\t\t});\n\t\t}\n\n\t\tif (milliseconds === Number.POSITIVE_INFINITY) {\n\t\t\tpromise.then(resolve, reject);\n\t\t\treturn;\n\t\t}\n\n\t\t// We create the error outside of `setTimeout` to preserve the stack trace.\n\t\tconst timeoutError = new TimeoutError();\n\n\t\ttimer = customTimers.setTimeout.call(undefined, () => {\n\t\t\tif (fallback) {\n\t\t\t\ttry {\n\t\t\t\t\tresolve(fallback());\n\t\t\t\t} catch (error) {\n\t\t\t\t\treject(error);\n\t\t\t\t}\n\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (typeof promise.cancel === 'function') {\n\t\t\t\tpromise.cancel();\n\t\t\t}\n\n\t\t\tif (message === false) {\n\t\t\t\tresolve();\n\t\t\t} else if (message instanceof Error) {\n\t\t\t\treject(message);\n\t\t\t} else {\n\t\t\t\ttimeoutError.message = message ?? `Promise timed out after ${milliseconds} milliseconds`;\n\t\t\t\treject(timeoutError);\n\t\t\t}\n\t\t}, milliseconds);\n\n\t\t(async () => {\n\t\t\ttry {\n\t\t\t\tresolve(await promise);\n\t\t\t} catch (error) {\n\t\t\t\treject(error);\n\t\t\t}\n\t\t})();\n\t});\n\n\tconst cancelablePromise = wrappedPromise.finally(() => {\n\t\tcancelablePromise.clear();\n\t});\n\n\tcancelablePromise.clear = () => {\n\t\tcustomTimers.clearTimeout.call(undefined, timer);\n\t\ttimer = undefined;\n\t};\n\n\treturn cancelablePromise;\n}\n","import path, { join } from \"path\"\nimport { fileURLToPath } from \"url\"\nimport { info } from \"ci-log\"\nimport { addExeExt } from \"patha\"\nimport { loadAssetList, matchAsset } from \"../utils/asset/load-assets.js\"\nimport { arm64, armv7, powerpc64le, sparc64, x86, x86_64 } from \"../utils/env/arch.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport { ubuntuVersion } from \"../utils/env/ubuntu_version.js\"\nimport { extractExe, extractTarByExe } from \"../utils/setup/extract.js\"\nimport type { PackageInfo } from \"../utils/setup/setupBin.js\"\n\nconst dirname = typeof __dirname === \"string\" ? __dirname : path.dirname(fileURLToPath(import.meta.url))\n\nexport async function getLLVMPackageInfo(\n version: string,\n platform: NodeJS.Platform,\n arch: string,\n): Promise<PackageInfo> {\n const url = await getLLVMAssetURL(platform, arch, version)\n info(`Downloading LLVM from ${url}`)\n\n return {\n url,\n extractedFolderName: \"\",\n binRelativeDir: \"bin\",\n binFileName: addExeExt(\"clang\"),\n extractFunction: platform === \"win32\"\n ? extractExe\n : (file: string, dest: string) => {\n return extractTarByExe(file, dest, 1)\n },\n }\n}\n\nexport async function getLLVMAssetURL(platform: string, arch: string, version: string) {\n const { keywords, optionalKeywords } = await getAssetKeywords(platform, arch)\n\n // first check the github releases\n const llvmGitHubAssets = await loadAssetList(\n join(dirname, \"github_llvm_llvm-project.json\"),\n )\n const ghAsset = matchAsset(\n llvmGitHubAssets,\n {\n version,\n keywords,\n optionalKeywords,\n filterMapTag(tag) {\n return tag.replace(/^llvmorg-/, \"\")\n },\n },\n )\n\n if (ghAsset !== undefined) {\n return `https://github.com/llvm/llvm-project/releases/download/${ghAsset.tag}/${ghAsset.name}`\n }\n\n // check the llvm website\n const llvmWebsiteAssets = await loadAssetList(\n join(dirname, \"llvm_org_releases.json\"),\n )\n\n const websiteAsset = matchAsset(\n llvmWebsiteAssets,\n {\n version,\n keywords,\n optionalKeywords,\n },\n )\n\n if (websiteAsset !== undefined) {\n return `https://releases.llvm.org/${websiteAsset.tag}/${websiteAsset.name}`\n }\n\n throw new Error(`No asset found for version ${version} matching ${keywords} and ${optionalKeywords}`)\n}\n\nasync function getAssetKeywords(platform: string, arch: string) {\n const keywords: string[] = []\n const optionalKeywords: string[] = []\n\n switch (platform) {\n case \"win32\": {\n if (x86_64.includes(arch)) {\n keywords.push(\"win64\")\n // TODO fallback to win32 if win64 is not available (e.g. for LLVM 3.6.2 and older)\n } else if (x86.includes(arch)) {\n keywords.push(\"win32\")\n } else if (arm64.includes(arch)) {\n keywords.push(\"woa64\")\n } else {\n info(`Using arch ${arch} for LLVM`)\n keywords.push(arch)\n }\n break\n }\n case \"linux\": {\n keywords.push(\"linux\")\n\n if (isUbuntu()) {\n optionalKeywords.push(\"ubuntu\")\n\n const ubuntuVer = await ubuntuVersion()\n if (ubuntuVer !== null) {\n optionalKeywords.push(`${ubuntuVer[0]}`)\n const ubuntuMin = ubuntuVer[1] < 10 ? `0${ubuntuVer[1]}` : `${ubuntuVer[1]}`\n\n optionalKeywords.push(`${ubuntuVer[0]}.${ubuntuMin}`)\n optionalKeywords.push(`${ubuntuVer[0]}.${ubuntuMin}.${ubuntuVer[2]}`)\n }\n } else if (hasDnf()) {\n optionalKeywords.push(\"rhel\")\n }\n\n if (x86_64.includes(arch)) {\n keywords.push(\"x86_64\")\n } else if (x86.includes(arch)) {\n keywords.push(\"x86\")\n } else if (arm64.includes(arch)) {\n keywords.push(\"aarch64\")\n } else if (armv7.includes(arch)) {\n keywords.push(\"armv7a\")\n } else if (powerpc64le.includes(arch)) {\n keywords.push(\"powerpc64le\")\n } else if (sparc64.includes(arch)) {\n keywords.push(\"sparc64\")\n } else {\n info(`Using arch ${arch} for LLVM`)\n keywords.push(arch)\n }\n\n break\n }\n case \"darwin\": {\n keywords.push(\"apple\")\n\n if (x86_64.includes(arch)) {\n keywords.push(\"x86_64\")\n } else if (arm64.includes(arch)) {\n // allow falling back to x86_64 if arm64 is not available\n optionalKeywords.push(\"arm64\")\n } else {\n info(`Using arch ${arch} for LLVM`)\n keywords.push(arch)\n }\n break\n }\n case \"freebsd\": {\n keywords.push(\"freebsd\")\n\n if (x86_64.includes(arch)) {\n keywords.push(\"amd64\")\n } else if (x86.includes(arch)) {\n keywords.push(\"i386\")\n } else {\n info(`Using arch ${arch} for LLVM`)\n keywords.push(arch)\n }\n\n break\n }\n default:\n info(`Using ${platform} ${arch} for LLVM`)\n keywords.push(platform, arch)\n break\n }\n return { keywords, optionalKeywords }\n}\n","import { tmpdir } from \"os\"\nimport path, { delimiter, join } from \"path\"\nimport { fileURLToPath } from \"url\"\nimport { execRootSync } from \"admina\"\nimport ciInfo from \"ci-info\"\nconst { GITHUB_ACTIONS } = ciInfo\nimport { info, warning } from \"ci-log\"\nimport { addEnv } from \"envosman\"\nimport memoize from \"memoizee\"\nimport { DownloaderHelper } from \"node-downloader-helper\"\nimport { pathExists } from \"path-exists\"\nimport { addExeExt } from \"patha\"\nimport { addUpdateAlternativesToRc, installAptPack } from \"setup-apt\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { setupGcc } from \"../gcc/gcc.js\"\nimport { setupMacOSSDK } from \"../macos-sdk/macos-sdk.js\"\nimport { arm64, x86_64 } from \"../utils/env/arch.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport { ubuntuVersion } from \"../utils/env/ubuntu_version.js\"\nimport { type InstallationInfo, setupBin } from \"../utils/setup/setupBin.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\nimport { semverCoerceIfInvalid } from \"../utils/setup/version.js\"\nimport { quoteIfHasSpace } from \"../utils/std/index.js\"\nimport { getVersion } from \"../versions/versions.js\"\nimport { LLVMPackages, setupLLVMApt } from \"./llvm_installer.js\"\nimport { getLLVMPackageInfo } from \"./llvm_url.js\"\n\nconst dirname = typeof __dirname === \"string\" ? __dirname : path.dirname(fileURLToPath(import.meta.url))\n\nexport async function setupLLVM(version: string, setupDir: string, arch: string): Promise<InstallationInfo> {\n const installationInfo = await setupLLVMWithoutActivation(version, setupDir, arch)\n await activateLLVM(installationInfo.installDir ?? setupDir, version)\n return installationInfo\n}\n\nasync function setupLLVMWithoutActivation_(version: string, setupDir: string, arch: string) {\n // install LLVM\n const [installationInfo, _1] = await Promise.all([\n setupLLVMOnly(version, setupDir, arch),\n addLLVMLoggingMatcher(),\n ])\n\n // install LLVM dependencies\n await setupLLVMDeps(arch)\n\n return installationInfo\n}\nconst setupLLVMWithoutActivation = memoize(setupLLVMWithoutActivation_, { promise: true })\n\n/**\n * Setup clang-format\n *\n * This uses the LLVM installer on Ubuntu, and the LLVM binaries on other platforms\n */\nexport function setupClangFormat(version: string, setupDir: string, arch: string) {\n return setupLLVMOnly(version, setupDir, arch, LLVMPackages.ClangFormat)\n}\n\n/** Setup llvm tools (clang tidy, etc.) without activating llvm and using it as the compiler */\nexport function setupClangTools(version: string, setupDir: string, arch: string) {\n return setupLLVMOnly(version, setupDir, arch)\n}\n\nasync function setupLLVMOnly(\n version: string,\n setupDir: string,\n arch: string,\n packages: LLVMPackages = LLVMPackages.All,\n) {\n const majorVersion = majorLLVMVersion(version)\n try {\n if (isUbuntu()) {\n return await setupLLVMApt(majorVersion, packages)\n }\n } catch (err) {\n info(`Failed to install llvm via system package manager ${err}`)\n }\n\n const installationInfo = await setupBin(\"llvm\", version, getLLVMPackageInfo, setupDir, arch)\n await llvmBinaryDeps(majorVersion)\n return installationInfo\n}\n\nfunction majorLLVMVersion(version: string) {\n const coeredVersion = semverCoerceIfInvalid(version)\n return Number.parseInt(coeredVersion.split(\".\")[0], 10)\n}\n\nasync function llvmBinaryDeps_(majorVersion: number) {\n if (isUbuntu()) {\n if (majorVersion <= 10) {\n try {\n await installAptPack([{ name: \"libtinfo5\" }])\n } catch (err) {\n // Manually install libtinfo5 if the package is not available\n info(`Failed to install libtinfo5 ${err}\\nManually installing the package`)\n const arch = x86_64.includes(process.arch)\n ? \"amd64\"\n : arm64.includes(process.arch)\n ? \"arm64\"\n : process.arch\n\n const fileName = `libtinfo5_6.3-2ubuntu0.1_${arch}.deb`\n const url = `http://launchpadlibrarian.net/666971015/${fileName}`\n const dl = new DownloaderHelper(url, tmpdir(), { fileName })\n dl.on(\"error\", (dlErr) => {\n throw new Error(`Failed to download ${url}: ${dlErr}`)\n })\n await dl.start()\n // Install the downloaded package via dpkg\n execRootSync(\"dpkg\", [\"-i\", join(tmpdir(), fileName)])\n }\n } else {\n await installAptPack([{ name: \"libtinfo-dev\" }])\n }\n } else if (isArch()) {\n // https://aur.archlinux.org/packages/ncurses5-compat-libs\n await setupPacmanPack(\"ncurses5-compat-libs\", undefined, \"yay\")\n } else if (hasDnf()) {\n // https://packages.fedoraproject.org/pkgs/ncurses/ncurses-compat-libs/index.html\n await setupDnfPack([\n { name: \"ncurses-compat-libs\" },\n ])\n }\n}\nconst llvmBinaryDeps = memoize(llvmBinaryDeps_, { promise: true })\n\nasync function setupLLVMDeps_(arch: string) {\n if (process.platform === \"linux\") {\n // using llvm requires ld, an up to date libstdc++, etc. So, install gcc first,\n // but with a lower priority than the one used by activateLLVM()\n await setupGcc(getVersion(\"gcc\", undefined, await ubuntuVersion()), \"\", arch, 40)\n }\n}\nconst setupLLVMDeps = memoize(setupLLVMDeps_, { promise: true })\n\nexport async function activateLLVM(directory: string, version: string) {\n const ld = process.env.LD_LIBRARY_PATH ?? \"\"\n const dyld = process.env.DYLD_LIBRARY_PATH ?? \"\"\n\n const llvmMajor = majorLLVMVersion(version)\n\n const actPromises: Promise<void>[] = [\n // compiler paths\n addEnv(\"CC\", addExeExt(`${directory}/bin/clang`), rcOptions),\n addEnv(\"CXX\", addExeExt(`${directory}/bin/clang++`), rcOptions),\n\n // the output of this action\n addEnv(\"LLVM_PATH\", directory, rcOptions),\n\n // Setup LLVM as the compiler\n addEnv(\"LD_LIBRARY_PATH\", `${ld}${delimiter}${directory}/lib`, rcOptions),\n addEnv(\"DYLD_LIBRARY_PATH\", `${dyld}${delimiter}${directory}/lib`, rcOptions),\n\n // compiler flags\n addEnv(\"LLVM_LDFLAGS\", `-L${quoteIfHasSpace(`${directory}/lib`)}`, rcOptions),\n addEnv(\"LLVM_CPPFLAGS\", `-I${quoteIfHasSpace(`${directory}/include`)}`, rcOptions),\n\n // CPATH\n await pathExists(`${directory}/lib/clang/${version}/include`)\n ? addEnv(\"LLVM_CPATH\", `${directory}/lib/clang/${version}/include`, rcOptions)\n : await pathExists(`${directory}/lib/clang/${llvmMajor}/include`)\n ? addEnv(\"LLVM_CPATH\", `${directory}/lib/clang/${llvmMajor}/include`, rcOptions)\n : Promise.resolve(),\n\n addEnv(\"LIBRARY_PATH\", `${directory}/lib`, rcOptions),\n\n // os sdks\n setupMacOSSDK(),\n ]\n\n if (isUbuntu()) {\n const priority = 60\n actPromises.push(\n addUpdateAlternativesToRc(\"cc\", `${directory}/bin/clang`, rcOptions, priority),\n addUpdateAlternativesToRc(\"cxx\", `${directory}/bin/clang++`, rcOptions, priority),\n addUpdateAlternativesToRc(\"clang\", `${directory}/bin/clang`, rcOptions),\n addUpdateAlternativesToRc(\"clang++\", `${directory}/bin/clang++`, rcOptions),\n addUpdateAlternativesToRc(\"lld\", `${directory}/bin/lld`, rcOptions),\n addUpdateAlternativesToRc(\"ld.lld\", `${directory}/bin/ld.lld`, rcOptions),\n addUpdateAlternativesToRc(\"llvm-ar\", `${directory}/bin/llvm-ar`, rcOptions),\n )\n }\n\n await Promise.all(actPromises)\n}\n\nasync function addLLVMLoggingMatcher() {\n if (GITHUB_ACTIONS) {\n const matcherPath = join(dirname, \"llvm_matcher.json\")\n if (!(await pathExists(matcherPath))) {\n return warning(\"the llvm_matcher.json file does not exist in the same folder as setup-cpp.js\")\n }\n info(`::add-matcher::${matcherPath}`)\n }\n}\n","import { info } from \"console\"\nimport { tmpdir } from \"os\"\nimport { join } from \"path\"\nimport { execRoot } from \"admina\"\nimport { addPath } from \"envosman\"\nimport { chmod, readFile, writeFile } from \"fs/promises\"\nimport { DownloaderHelper } from \"node-downloader-helper\"\nimport { aptTimeout, hasNala, installAptPack, isAptPackRegexInstalled } from \"setup-apt\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { DEFAULT_TIMEOUT } from \"../installTool.js\"\nimport type { InstallationInfo } from \"../utils/setup/setupBin.js\"\n\nexport enum LLVMPackages {\n All = 0,\n ClangFormat = 1,\n Core = 2,\n}\n\nexport async function setupLLVMApt(\n majorVersion: number,\n packages: LLVMPackages = LLVMPackages.All,\n): Promise<InstallationInfo> {\n // TODO for older versions, this also includes the minor version\n const installationFolder = `/usr/lib/llvm-${majorVersion}`\n\n // download the installation script\n await installAptPack([{ name: \"ca-certificates\" }])\n const dl = new DownloaderHelper(\"https://apt.llvm.org/llvm.sh\", tmpdir(), { fileName: \"llvm.sh\" })\n dl.on(\"error\", (err) => {\n throw new Error(`Failed to download the LLVM installer script: ${err}`)\n })\n await dl.start()\n const installerScript = await readFile(dl.getDownloadPath(), \"utf-8\")\n\n const installerPath = join(tmpdir(), \"llvm-setup-cpp.sh\")\n const neededPackages = await patchAptLLVMScript(\n installerScript,\n installerPath,\n majorVersion,\n packages,\n )\n await installAptPack(neededPackages)\n await chmod(installerPath, \"755\")\n await execRoot(\n \"bash\",\n [installerPath, `${majorVersion}`, ...(packages === LLVMPackages.All ? [\"all\"] : [])],\n {\n stdio: \"inherit\",\n shell: true,\n timeout: DEFAULT_TIMEOUT,\n },\n )\n\n await addPath(`${installationFolder}/bin`, rcOptions)\n\n return {\n installDir: `${installationFolder}`,\n binDir: `${installationFolder}/bin`,\n bin: `${installationFolder}/bin/clang++`,\n }\n}\n\nasync function patchAptLLVMScript(\n givenScript: string,\n target_path: string,\n majorVersion: number,\n packages: LLVMPackages,\n) {\n let script = debugScript(givenScript)\n script = nonInteractiveScript(script)\n script = choosePackages(packages, script, majorVersion)\n script = await removeConflictingPackages(script)\n script = useNalaScript(script)\n\n await writeFile(target_path, script)\n\n // the packages needed by the script\n return [{ name: \"lsb-release\" }, { name: \"wget\" }, { name: \"software-properties-common\" }, { name: \"gnupg\" }]\n}\n\nfunction debugScript(script: string) {\n if (process.env.NODE_DEBUG !== \"1\" && process.env.NODE_DEBUG !== \"true\") {\n return script.replace(/set -eux/g, \"set -eu\")\n }\n return script\n}\n\nfunction nonInteractiveScript(script: string) {\n // make the scirpt non-interactive and fix broken packages\n return script.replace(\n /add-apt-repository \"\\${REPO_NAME}\"/g,\n `add-apt-repository -y -n \"\\${REPO_NAME}\"\napt-get update -o ${aptTimeout} -y`,\n )\n}\n\nasync function removeConflictingPackages(givenScript: string) {\n // fix conflicts between libclang-rt and libclang\n let script = givenScript.replace(\n /apt-get install -y/g,\n `apt-get install -o Dpkg::Options::=\"--force-overwrite\" -o ${aptTimeout} -y --fix-broken`,\n )\n\n // check if these are installed and if so, remove them from the script as they conflict\n const conflictingPackages = [\"libc++-$LLVM_VERSION-dev\", \"libc++abi-$LLVM_VERSION-dev\", \"libunwind-$LLVM_VERSION-dev\"]\n await Promise.all(\n conflictingPackages.map(async (pack) => {\n const installingPack = pack.replace(\"$LLVM_VERSION\", \"*\")\n if (await isAptPackRegexInstalled(installingPack)) {\n info(`Removing conflicting package ${installingPack}`)\n script = script.replace(pack, \"\")\n }\n }),\n )\n return script\n}\n\nfunction useNalaScript(script: string) {\n // use nala if it is available\n if (hasNala()) {\n return script.replace(/apt-get/g, \"nala\")\n }\n return script\n}\n\nfunction choosePackages(packages: LLVMPackages, script: string, majorVersion: number) {\n if (packages === LLVMPackages.ClangFormat) {\n return script.replace(/ -y \\$PKG/g, ` -y clang-format-${majorVersion}`)\n }\n return script\n}\n","import path, { join } from \"path\"\nimport { fileURLToPath } from \"url\"\n// eslint-disable-next-line @typescript-eslint/ban-ts-comment\n// @ts-ignore\nimport ciInfo from \"ci-info\"\nconst { GITHUB_ACTIONS } = ciInfo\nimport { error, info, warning } from \"ci-log\"\nimport { findVcvarsall, vsversion_to_versionnumber } from \"msvc-dev-cmd/lib.js\"\nimport { pathExists } from \"path-exists\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\nimport { setupVCVarsall } from \"../vcvarsall/vcvarsall.js\"\n\nconst dirname = typeof __dirname === \"string\" ? __dirname : path.dirname(fileURLToPath(import.meta.url))\n\ntype MSVCVersion = \"2022\" | \"17.0\" | \"2019\" | \"16.0\" | \"2017\" | \"15.0\" | \"2015\" | \"14.0\" | \"2013\" | \"12.0\" | string\n\nexport async function setupMSVC(\n versionGiven: MSVCVersion,\n _setupDir: string,\n arch: string,\n sdk?: string,\n uwp?: boolean,\n spectre?: boolean,\n) {\n if (process.platform !== \"win32\") {\n return\n }\n const version = vsversion_to_versionnumber(versionGiven) as string\n\n // check if the given version is already installed\n info(`Checking if MSVC ${version} is already installed`)\n let installed = false\n try {\n const vcvarsall_path = findVcvarsall(version) as string\n installed = true\n info(`Found the pre-installed version of MSVC at ${vcvarsall_path}`)\n } catch {\n // not installed, try installing\n }\n\n let toolset: string | undefined\n let VCTargetsPath: string | undefined\n // https://github.com/aminya/setup-cpp/issues/1\n if (!installed) {\n try {\n if (version === \"14.0\") {\n toolset = \"14.0\"\n await setupChocoPack(\"visualcpp-build-tools\", \"14.0.25420.1\", [\"--ignore-dependencies\"])\n VCTargetsPath = \"C:/Program Files (x86)/MSBuild/Microsoft.Cpp/v4.0/v140\"\n } else if (version === \"15.0\") {\n toolset = \"14.16\"\n await setupChocoPack(\"visualstudio2017buildtools\", \"15.9.41.0\", [])\n VCTargetsPath = \"C:/Program Files (x86)/Microsoft Visual Studio/2017/BuildTools/VC/Tools/MSVC/14.16\" // TODO verify path\n } else if (version === \"16.0\") {\n toolset = \"14.29\"\n await setupChocoPack(\"visualstudio2019buildtools\", \"16.11.7.0\", [])\n VCTargetsPath = \"C:/Program Files (x86)/Microsoft Visual Studio/2019/BuildTools/VC/Tools/MSVC/14.29.30133\"\n } else if (version === \"17.0\") {\n toolset = undefined\n await setupChocoPack(\"visualstudio2022buildtools\", \"117.0.5.0\", [])\n VCTargetsPath = undefined\n } else {\n error(`The given MSVC versions ${versionGiven} is not supported yet.`)\n }\n } catch (e) {\n error(e as string | Error)\n }\n }\n // run vcvarsall.bat environment variables\n await setupVCVarsall(version, VCTargetsPath, arch, toolset, sdk, uwp, spectre)\n\n if (GITHUB_ACTIONS) {\n await addMSVCLoggingMatcher()\n }\n}\n\nasync function addMSVCLoggingMatcher() {\n const matcherPath = join(dirname, \"msvc_matcher.json\")\n if (!(await pathExists(matcherPath))) {\n return warning(\"the msvc_matcher.json file does not exist in the same folder as setup-cpp.js\")\n }\n info(`::add-matcher::${matcherPath}`)\n}\n","import { addPath } from \"envosman\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport async function setupOpencppcoverage(version: string | undefined, _setupDir: string, _arch: string) {\n if (process.platform !== \"win32\") {\n return\n }\n await setupChocoPack(\"opencppcoverage\", version)\n const binDir = await activateOpencppcoverage()\n return { binDir }\n}\n\nasync function activateOpencppcoverage() {\n const binDir = \"C:/Program Files/OpenCppCoverage\"\n await addPath(binDir, rcOptions)\n return binDir\n}\n","import { execRootSync } from \"admina\"\nimport { error } from \"ci-log\"\nimport { addPath } from \"envosman\"\nimport { addExeExt } from \"patha\"\nimport { installAptPack } from \"setup-apt\"\nimport { installBrewPack } from \"setup-brew\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport { ubuntuVersion } from \"../utils/env/ubuntu_version.js\"\nimport { type PackageInfo, setupBin } from \"../utils/setup/setupBin.js\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\n\n/** Get the platform data for cmake */\nfunction getPowerShellPackageInfo(version: string, platform: NodeJS.Platform, arch: string): PackageInfo {\n return {\n url: getPowershellUrl(platform, arch, version),\n binRelativeDir: \"\",\n binFileName: addExeExt(\"pwsh\"),\n extractedFolderName: \"\",\n }\n}\n\nfunction getPowershellUrl(\n platform: string,\n arch: string,\n version: string,\n) {\n switch (platform) {\n case \"win32\": {\n const osArchStr = ([\"ia32\", \"x86\", \"i386\", \"x32\"].includes(arch))\n ? \"win-x86\"\n : \"win-x64\"\n\n return `https://github.com/PowerShell/PowerShell/releases/download/v${version}/PowerShell-${version}-${osArchStr}.zip`\n }\n case \"darwin\": {\n const osArchStr = [\"arm\", \"arm64\"].includes(arch) ? \"osx-arm64\" : \"osx-x64\"\n\n return `https://github.com/PowerShell/PowerShell/releases/download/v${version}/powershell-${version}-${osArchStr}.tar.gz`\n }\n case \"linux\": {\n const archMap = {\n arm64: \"linux-arm64\",\n arm: \"linux-arm64\",\n arm32: \"linux-arm32\",\n aarch64: \"linux-arm64\",\n x64: \"linux-x64\",\n } as Record<string, string | undefined>\n const osArchStr = archMap[arch] ?? \"linux-x64\"\n // TODO support musl\n return `https://github.com/PowerShell/PowerShell/releases/download/v${version}/powershell-${version}-${osArchStr}.tar.gz`\n }\n default:\n throw new Error(`Unsupported platform '${platform}'`)\n }\n}\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport async function setupPowershell(version: string, setupDir: string, arch: string) {\n try {\n return await setupBin(\"pwsh\", version, getPowerShellPackageInfo, setupDir, arch)\n } catch (err) {\n error(`Failed to setup pwsh via download: ${err}. Trying package managers...`)\n return setupPowershellSystem(version, setupDir, arch)\n }\n}\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport async function setupPowershellSystem(version: string | undefined, _setupDir: string, _arch: string) {\n switch (process.platform) {\n case \"win32\": {\n await setupChocoPack(\"powershell-core\", version)\n const binDir = \"C:/Program Files/PowerShell/7\"\n await addPath(binDir, rcOptions)\n return { binDir }\n }\n case \"darwin\": {\n return installBrewPack(\"powershell\", version, { cask: true, overwrite: false })\n }\n case \"linux\": {\n if (isArch()) {\n return setupPacmanPack(\"powershell-bin\", version, \"yay\")\n } else if (hasDnf()) {\n await setupDnfPack([{ name: \"curl\" }])\n execRootSync(\"/bin/bash\", [\n \"-c\",\n \"curl https://packages.microsoft.com/config/rhel/8/prod.repo | sudo tee /etc/yum.repos.d/microsoft.repo\",\n ])\n return setupDnfPack([{ name: \"powershell\", version }])\n } else if (isUbuntu()) {\n await installAptPack([{ name: \"curl\" }])\n const ubuntuVerSplitted = (await ubuntuVersion())!\n const ubuntuVersionString = `${ubuntuVerSplitted[0]}.0${ubuntuVerSplitted[1]}`\n\n execRootSync(\"curl\", [\n \"-LJO\",\n `https://packages.microsoft.com/config/ubuntu/${ubuntuVersionString}/packages-microsoft-prod.deb`,\n ])\n execRootSync(\"dpkg\", [\"-i\", \"packages-microsoft-prod.deb\"])\n\n // TODO Debian\n // const keyFileName = await addAptKeyViaURL(\n // \"microsoft.asc\",\n // \"https://packages.microsoft.com/keys/microsoft.asc\"\n // )\n // execRootSync(\"/bin/bash\", [\n // \"-c\",\n // `echo \"deb [arch=amd64 signed-by=${keyFileName}] https://packages.microsoft.com/repos/microsoft-debian-bullseye-prod bullseye main\" > /etc/apt/sources.list.d/microsoft.list`,\n // ])\n\n return installAptPack([{ name: \"powershell\", version }], true)\n }\n throw new Error(\"Unsupported linux distribution\")\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n}\n","import { addExeExt } from \"patha\"\nimport { type InstallationInfo, type PackageInfo, setupBin } from \"../utils/setup/setupBin.js\"\n\n/** Get the platform name task uses in their download links */\nfunction getTaskPlatform(platform: NodeJS.Platform) {\n switch (platform) {\n case \"win32\":\n return \"windows\"\n default:\n return platform\n }\n}\n\n/** Get the arch name task uses in their download links */\nfunction getTaskArch(arch: string) {\n switch (arch) {\n case \"x64\":\n return \"amd64\"\n case \"ia32\":\n case \"x86\":\n case \"i386\":\n case \"x32\":\n return \"386\"\n default:\n return arch\n }\n}\n\n/** Get the platform data for task */\nfunction getTaskPackageInfo(version: string, platform: NodeJS.Platform, arch: string): PackageInfo {\n const taskPlatform = getTaskPlatform(platform)\n const taskArch = getTaskArch(arch)\n const extension = platform === \"win32\" ? \"zip\" : \"tar.gz\"\n return {\n binRelativeDir: \"\",\n binFileName: addExeExt(\"task\"),\n extractedFolderName: \"\",\n url: `https://github.com/go-task/task/releases/download/v${version}/task_${taskPlatform}_${taskArch}.${extension}`,\n }\n}\n\nexport function setupTask(version: string, setupDir: string, arch: string): Promise<InstallationInfo> {\n return setupBin(\"task\", version, getTaskPackageInfo, setupDir, arch)\n}\n","import { getInput } from \"@actions/core\"\nimport { info } from \"ci-log\"\nimport mri from \"mri\"\nimport { untildifyUser } from \"untildify-user\"\nimport { type Inputs, inputs } from \"./tool.js\"\nimport type { InstallationInfo } from \"./utils/setup/setupBin.js\"\n\nexport function parseArgs(args: string[]): Opts {\n return mri<Record<Inputs, string | undefined> & { help: boolean }>(args, {\n string: [...inputs, \"timeout\"],\n default: Object.fromEntries(inputs.map((inp) => [inp, maybeGetInput(inp)])),\n alias: { h: \"help\" },\n boolean: \"help\",\n })\n}\n\nexport function printHelp() {\n info(`\nsetup-cpp [options]\nsetup-cpp --compiler llvm --cmake true --ninja true --ccache true --vcpkg true\n\nInstall all the tools required for building and testing C++/C projects.\n\n--architecture\\t the cpu architecture to install the tools for. By default it uses the current CPU architecture.\n--timeout\\t the timeout for the installation of each tool in minutes. By default it is 10 minutes.\n--compiler\\t the <compiler> to install.\n \\t You can specify the version instead of specifying just the name e.g: --compiler 'llvm-13.0.0'\n--$tool_name\\t pass \"true\" or pass the <version> you would like to install for this tool. e.g. --conan true or --conan \"1.42.1\"\n\nAll the available tools:\n`)\n\n console.table(\n {\n \"compiler and analyzer\": {\n tools: \"--llvm, --gcc, --msvc, --apple-clang, --vcvarsall\",\n },\n \"build system\": {\n tools: \"--cmake, --ninja, --meson, --make, --task, --bazel\",\n },\n \"package manager\": { tools: \"--vcpkg, --conan, --choco, --brew, --nala\" },\n \"analyzer/linter\": {\n tools:\n \"--clang-tidy, --clang-format, --cppcheck, --cpplint, --flawfinder, --lizard, --infer, , --cmakelang, --cmake-lint, --cmake-format\",\n },\n cache: { tools: \"--ccache, --sccache\" },\n documentation: { tools: \"--doxygen, --graphviz\" },\n coverage: { tools: \"--gcovr, --opencppcoverage, --kcov\" },\n other: { tools: \"--python, --powershell, --sevenzip\" },\n },\n [\"tools\"],\n )\n}\n/** Get an object from github actions */\n\nexport function maybeGetInput(key: string) {\n const value = getInput(key.toLowerCase())\n if (value !== \"false\" && value !== \"\") {\n return value\n }\n return undefined // skip installation\n}\nexport type Opts = mri.Argv<\n Record<Inputs, string | undefined> & {\n help: boolean\n timeout?: string\n }\n>\n\nexport function getSuccessMessage(tool: string, installationInfo: InstallationInfo | undefined | void) {\n let msg = `✅ ${tool} was installed successfully:`\n if (installationInfo === undefined) {\n return msg\n }\n if (\"installDir\" in installationInfo) {\n msg += `\\n- The installation directory is ${installationInfo.installDir}`\n }\n if (installationInfo.binDir !== \"\") {\n msg += `\\n- The binary directory is ${installationInfo.binDir}`\n }\n return msg\n}\n\nexport const rcOptions = {\n rcPath: untildifyUser(\"~/.cpprc\"),\n guard: \"cpp\",\n}\n","'use strict'\n\nconst vendors = require('./vendors.json')\n\nconst env = process.env\n\n// Used for testing only\nObject.defineProperty(exports, '_vendors', {\n value: vendors.map(function (v) {\n return v.constant\n })\n})\n\nexports.name = null\nexports.isPR = null\n\nvendors.forEach(function (vendor) {\n const envs = Array.isArray(vendor.env) ? vendor.env : [vendor.env]\n const isCI = envs.every(function (obj) {\n return checkEnv(obj)\n })\n\n exports[vendor.constant] = isCI\n\n if (!isCI) {\n return\n }\n\n exports.name = vendor.name\n\n switch (typeof vendor.pr) {\n case 'string':\n // \"pr\": \"CIRRUS_PR\"\n exports.isPR = !!env[vendor.pr]\n break\n case 'object':\n if ('env' in vendor.pr) {\n // \"pr\": { \"env\": \"BUILDKITE_PULL_REQUEST\", \"ne\": \"false\" }\n exports.isPR = vendor.pr.env in env && env[vendor.pr.env] !== vendor.pr.ne\n } else if ('any' in vendor.pr) {\n // \"pr\": { \"any\": [\"ghprbPullId\", \"CHANGE_ID\"] }\n exports.isPR = vendor.pr.any.some(function (key) {\n return !!env[key]\n })\n } else {\n // \"pr\": { \"DRONE_BUILD_EVENT\": \"pull_request\" }\n exports.isPR = checkEnv(vendor.pr)\n }\n break\n default:\n // PR detection not supported for this vendor\n exports.isPR = null\n }\n})\n\nexports.isCI = !!(\n env.CI !== 'false' && // Bypass all checks if CI env is explicitly set to 'false'\n (env.BUILD_ID || // Jenkins, Cloudbees\n env.BUILD_NUMBER || // Jenkins, TeamCity\n env.CI || // Travis CI, CircleCI, Cirrus CI, Gitlab CI, Appveyor, CodeShip, dsari\n env.CI_APP_ID || // Appflow\n env.CI_BUILD_ID || // Appflow\n env.CI_BUILD_NUMBER || // Appflow\n env.CI_NAME || // Codeship and others\n env.CONTINUOUS_INTEGRATION || // Travis CI, Cirrus CI\n env.RUN_ID || // TaskCluster, dsari\n exports.name ||\n false)\n)\n\nfunction checkEnv (obj) {\n // \"env\": \"CIRRUS\"\n if (typeof obj === 'string') return !!env[obj]\n\n // \"env\": { \"env\": \"NODE\", \"includes\": \"/app/.heroku/node/bin/node\" }\n if ('env' in obj) {\n // Currently there are no other types, uncomment when there are\n // if ('includes' in obj) {\n return env[obj.env] && env[obj.env].includes(obj.includes)\n // }\n }\n if ('any' in obj) {\n return obj.any.some(function (k) {\n return !!env[k]\n })\n }\n return Object.keys(obj).every(function (k) {\n return env[k] === obj[k]\n })\n}\n","\"use strict\";\n// We use any as a valid input type\n/* eslint-disable @typescript-eslint/no-explicit-any */\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.toCommandProperties = exports.toCommandValue = void 0;\n/**\n * Sanitizes an input into a string so it can be passed into issueCommand safely\n * @param input input to sanitize into a string\n */\nfunction toCommandValue(input) {\n if (input === null || input === undefined) {\n return '';\n }\n else if (typeof input === 'string' || input instanceof String) {\n return input;\n }\n return JSON.stringify(input);\n}\nexports.toCommandValue = toCommandValue;\n/**\n *\n * @param annotationProperties\n * @returns The command properties to send with the actual annotation command\n * See IssueCommandProperties: https://github.com/actions/runner/blob/main/src/Runner.Worker/ActionCommandManager.cs#L646\n */\nfunction toCommandProperties(annotationProperties) {\n if (!Object.keys(annotationProperties).length) {\n return {};\n }\n return {\n title: annotationProperties.title,\n file: annotationProperties.file,\n line: annotationProperties.startLine,\n endLine: annotationProperties.endLine,\n col: annotationProperties.startColumn,\n endColumn: annotationProperties.endColumn\n };\n}\nexports.toCommandProperties = toCommandProperties;\n//# sourceMappingURL=utils.js.map","\"use strict\";\n// For internal use, subject to change.\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.prepareKeyValueMessage = exports.issueFileCommand = void 0;\n// We use any as a valid input type\n/* eslint-disable @typescript-eslint/no-explicit-any */\nconst crypto = __importStar(require(\"crypto\"));\nconst fs = __importStar(require(\"fs\"));\nconst os = __importStar(require(\"os\"));\nconst utils_1 = require(\"./utils\");\nfunction issueFileCommand(command, message) {\n const filePath = process.env[`GITHUB_${command}`];\n if (!filePath) {\n throw new Error(`Unable to find environment variable for file command ${command}`);\n }\n if (!fs.existsSync(filePath)) {\n throw new Error(`Missing file at path: ${filePath}`);\n }\n fs.appendFileSync(filePath, `${(0, utils_1.toCommandValue)(message)}${os.EOL}`, {\n encoding: 'utf8'\n });\n}\nexports.issueFileCommand = issueFileCommand;\nfunction prepareKeyValueMessage(key, value) {\n const delimiter = `ghadelimiter_${crypto.randomUUID()}`;\n const convertedValue = (0, utils_1.toCommandValue)(value);\n // These should realistically never happen, but just in case someone finds a\n // way to exploit uuid generation let's not allow keys or values that contain\n // the delimiter.\n if (key.includes(delimiter)) {\n throw new Error(`Unexpected input: name should not contain the delimiter \"${delimiter}\"`);\n }\n if (convertedValue.includes(delimiter)) {\n throw new Error(`Unexpected input: value should not contain the delimiter \"${delimiter}\"`);\n }\n return `${key}<<${delimiter}${os.EOL}${convertedValue}${os.EOL}${delimiter}`;\n}\nexports.prepareKeyValueMessage = prepareKeyValueMessage;\n//# sourceMappingURL=file-command.js.map","module.exports = require('./lib/tunnel');\n","/* eslint-disable @typescript-eslint/no-explicit-any */\nimport * as http from 'http';\nimport * as https from 'https';\nimport * as pm from './proxy';\nimport * as tunnel from 'tunnel';\nexport var HttpCodes;\n(function (HttpCodes) {\n HttpCodes[HttpCodes[\"OK\"] = 200] = \"OK\";\n HttpCodes[HttpCodes[\"MultipleChoices\"] = 300] = \"MultipleChoices\";\n HttpCodes[HttpCodes[\"MovedPermanently\"] = 301] = \"MovedPermanently\";\n HttpCodes[HttpCodes[\"ResourceMoved\"] = 302] = \"ResourceMoved\";\n HttpCodes[HttpCodes[\"SeeOther\"] = 303] = \"SeeOther\";\n HttpCodes[HttpCodes[\"NotModified\"] = 304] = \"NotModified\";\n HttpCodes[HttpCodes[\"UseProxy\"] = 305] = \"UseProxy\";\n HttpCodes[HttpCodes[\"SwitchProxy\"] = 306] = \"SwitchProxy\";\n HttpCodes[HttpCodes[\"TemporaryRedirect\"] = 307] = \"TemporaryRedirect\";\n HttpCodes[HttpCodes[\"PermanentRedirect\"] = 308] = \"PermanentRedirect\";\n HttpCodes[HttpCodes[\"BadRequest\"] = 400] = \"BadRequest\";\n HttpCodes[HttpCodes[\"Unauthorized\"] = 401] = \"Unauthorized\";\n HttpCodes[HttpCodes[\"PaymentRequired\"] = 402] = \"PaymentRequired\";\n HttpCodes[HttpCodes[\"Forbidden\"] = 403] = \"Forbidden\";\n HttpCodes[HttpCodes[\"NotFound\"] = 404] = \"NotFound\";\n HttpCodes[HttpCodes[\"MethodNotAllowed\"] = 405] = \"MethodNotAllowed\";\n HttpCodes[HttpCodes[\"NotAcceptable\"] = 406] = \"NotAcceptable\";\n HttpCodes[HttpCodes[\"ProxyAuthenticationRequired\"] = 407] = \"ProxyAuthenticationRequired\";\n HttpCodes[HttpCodes[\"RequestTimeout\"] = 408] = \"RequestTimeout\";\n HttpCodes[HttpCodes[\"Conflict\"] = 409] = \"Conflict\";\n HttpCodes[HttpCodes[\"Gone\"] = 410] = \"Gone\";\n HttpCodes[HttpCodes[\"TooManyRequests\"] = 429] = \"TooManyRequests\";\n HttpCodes[HttpCodes[\"InternalServerError\"] = 500] = \"InternalServerError\";\n HttpCodes[HttpCodes[\"NotImplemented\"] = 501] = \"NotImplemented\";\n HttpCodes[HttpCodes[\"BadGateway\"] = 502] = \"BadGateway\";\n HttpCodes[HttpCodes[\"ServiceUnavailable\"] = 503] = \"ServiceUnavailable\";\n HttpCodes[HttpCodes[\"GatewayTimeout\"] = 504] = \"GatewayTimeout\";\n})(HttpCodes || (HttpCodes = {}));\nexport var Headers;\n(function (Headers) {\n Headers[\"Accept\"] = \"accept\";\n Headers[\"ContentType\"] = \"content-type\";\n})(Headers || (Headers = {}));\nexport var MediaTypes;\n(function (MediaTypes) {\n MediaTypes[\"ApplicationJson\"] = \"application/json\";\n})(MediaTypes || (MediaTypes = {}));\n/**\n * Returns the proxy URL, depending upon the supplied url and proxy environment variables.\n * @param serverUrl The server URL where the request will be sent. For example, https://api.github.com\n */\nexport function getProxyUrl(serverUrl) {\n const proxyUrl = pm.getProxyUrl(new URL(serverUrl));\n return proxyUrl ? proxyUrl.href : '';\n}\nconst HttpRedirectCodes = [\n HttpCodes.MovedPermanently,\n HttpCodes.ResourceMoved,\n HttpCodes.SeeOther,\n HttpCodes.TemporaryRedirect,\n HttpCodes.PermanentRedirect\n];\nconst HttpResponseRetryCodes = [\n HttpCodes.BadGateway,\n HttpCodes.ServiceUnavailable,\n HttpCodes.GatewayTimeout\n];\nconst RetryableHttpVerbs = ['OPTIONS', 'GET', 'DELETE', 'HEAD'];\nconst ExponentialBackoffCeiling = 10;\nconst ExponentialBackoffTimeSlice = 5;\nexport class HttpClientError extends Error {\n constructor(message, statusCode) {\n super(message);\n this.name = 'HttpClientError';\n this.statusCode = statusCode;\n Object.setPrototypeOf(this, HttpClientError.prototype);\n }\n statusCode;\n result;\n}\nexport class HttpClientResponse {\n constructor(message) {\n this.message = message;\n }\n message;\n async readBody() {\n return new Promise(async (resolve) => {\n let output = Buffer.alloc(0);\n this.message.on('data', (chunk) => {\n output = Buffer.concat([output, chunk]);\n });\n this.message.on('end', () => {\n resolve(output.toString());\n });\n });\n }\n async readBodyBuffer() {\n return new Promise(async (resolve) => {\n const chunks = [];\n this.message.on('data', (chunk) => {\n chunks.push(chunk);\n });\n this.message.on('end', () => {\n resolve(Buffer.concat(chunks));\n });\n });\n }\n}\nexport function isHttps(requestUrl) {\n const parsedUrl = new URL(requestUrl);\n return parsedUrl.protocol === 'https:';\n}\nexport class HttpClient {\n userAgent;\n handlers;\n requestOptions;\n _ignoreSslError = false;\n _socketTimeout;\n _allowRedirects = true;\n _allowRedirectDowngrade = false;\n _maxRedirects = 50;\n _allowRetries = false;\n _maxRetries = 1;\n _agent;\n _proxyAgent;\n _proxyAgentDispatcher;\n _keepAlive = false;\n _disposed = false;\n constructor(userAgent, handlers, requestOptions) {\n this.userAgent = userAgent;\n this.handlers = handlers || [];\n this.requestOptions = requestOptions;\n if (requestOptions) {\n if (requestOptions.ignoreSslError != null) {\n this._ignoreSslError = requestOptions.ignoreSslError;\n }\n this._socketTimeout = requestOptions.socketTimeout;\n if (requestOptions.allowRedirects != null) {\n this._allowRedirects = requestOptions.allowRedirects;\n }\n if (requestOptions.allowRedirectDowngrade != null) {\n this._allowRedirectDowngrade = requestOptions.allowRedirectDowngrade;\n }\n if (requestOptions.maxRedirects != null) {\n this._maxRedirects = Math.max(requestOptions.maxRedirects, 0);\n }\n if (requestOptions.keepAlive != null) {\n this._keepAlive = requestOptions.keepAlive;\n }\n if (requestOptions.allowRetries != null) {\n this._allowRetries = requestOptions.allowRetries;\n }\n if (requestOptions.maxRetries != null) {\n this._maxRetries = requestOptions.maxRetries;\n }\n }\n }\n async options(requestUrl, additionalHeaders) {\n return this.request('OPTIONS', requestUrl, null, additionalHeaders || {});\n }\n async get(requestUrl, additionalHeaders) {\n return this.request('GET', requestUrl, null, additionalHeaders || {});\n }\n async del(requestUrl, additionalHeaders) {\n return this.request('DELETE', requestUrl, null, additionalHeaders || {});\n }\n async post(requestUrl, data, additionalHeaders) {\n return this.request('POST', requestUrl, data, additionalHeaders || {});\n }\n async patch(requestUrl, data, additionalHeaders) {\n return this.request('PATCH', requestUrl, data, additionalHeaders || {});\n }\n async put(requestUrl, data, additionalHeaders) {\n return this.request('PUT', requestUrl, data, additionalHeaders || {});\n }\n async head(requestUrl, additionalHeaders) {\n return this.request('HEAD', requestUrl, null, additionalHeaders || {});\n }\n async sendStream(verb, requestUrl, stream, additionalHeaders) {\n return this.request(verb, requestUrl, stream, additionalHeaders);\n }\n /**\n * Gets a typed object from an endpoint\n * Be aware that not found returns a null. Other errors (4xx, 5xx) reject the promise\n */\n async getJson(requestUrl, additionalHeaders = {}) {\n additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);\n const res = await this.get(requestUrl, additionalHeaders);\n return this._processResponse(res, this.requestOptions);\n }\n async postJson(requestUrl, obj, additionalHeaders = {}) {\n const data = JSON.stringify(obj, null, 2);\n additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);\n additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson);\n const res = await this.post(requestUrl, data, additionalHeaders);\n return this._processResponse(res, this.requestOptions);\n }\n async putJson(requestUrl, obj, additionalHeaders = {}) {\n const data = JSON.stringify(obj, null, 2);\n additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);\n additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson);\n const res = await this.put(requestUrl, data, additionalHeaders);\n return this._processResponse(res, this.requestOptions);\n }\n async patchJson(requestUrl, obj, additionalHeaders = {}) {\n const data = JSON.stringify(obj, null, 2);\n additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);\n additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson);\n const res = await this.patch(requestUrl, data, additionalHeaders);\n return this._processResponse(res, this.requestOptions);\n }\n /**\n * Makes a raw http request.\n * All other methods such as get, post, patch, and request ultimately call this.\n * Prefer get, del, post and patch\n */\n async request(verb, requestUrl, data, headers) {\n if (this._disposed) {\n throw new Error('Client has already been disposed.');\n }\n const parsedUrl = new URL(requestUrl);\n let info = this._prepareRequest(verb, parsedUrl, headers);\n // Only perform retries on reads since writes may not be idempotent.\n const maxTries = this._allowRetries && RetryableHttpVerbs.includes(verb)\n ? this._maxRetries + 1\n : 1;\n let numTries = 0;\n let response;\n do {\n response = await this.requestRaw(info, data);\n // Check if it's an authentication challenge\n if (response &&\n response.message &&\n response.message.statusCode === HttpCodes.Unauthorized) {\n let authenticationHandler;\n for (const handler of this.handlers) {\n if (handler.canHandleAuthentication(response)) {\n authenticationHandler = handler;\n break;\n }\n }\n if (authenticationHandler) {\n return authenticationHandler.handleAuthentication(this, info, data);\n }\n else {\n // We have received an unauthorized response but have no handlers to handle it.\n // Let the response return to the caller.\n return response;\n }\n }\n let redirectsRemaining = this._maxRedirects;\n while (response.message.statusCode &&\n HttpRedirectCodes.includes(response.message.statusCode) &&\n this._allowRedirects &&\n redirectsRemaining > 0) {\n const redirectUrl = response.message.headers['location'];\n if (!redirectUrl) {\n // if there's no location to redirect to, we won't\n break;\n }\n const parsedRedirectUrl = new URL(redirectUrl);\n if (parsedUrl.protocol === 'https:' &&\n parsedUrl.protocol !== parsedRedirectUrl.protocol &&\n !this._allowRedirectDowngrade) {\n throw new Error('Redirect from HTTPS to HTTP protocol. This downgrade is not allowed for security reasons. If you want to allow this behavior, set the allowRedirectDowngrade option to true.');\n }\n // we need to finish reading the response before reassigning response\n // which will leak the open socket.\n await response.readBody();\n // strip authorization header if redirected to a different hostname\n if (parsedRedirectUrl.hostname !== parsedUrl.hostname) {\n for (const header in headers) {\n // header names are case insensitive\n if (header.toLowerCase() === 'authorization') {\n delete headers[header];\n }\n }\n }\n // let's make the request with the new redirectUrl\n info = this._prepareRequest(verb, parsedRedirectUrl, headers);\n response = await this.requestRaw(info, data);\n redirectsRemaining--;\n }\n if (!response.message.statusCode ||\n !HttpResponseRetryCodes.includes(response.message.statusCode)) {\n // If not a retry code, return immediately instead of retrying\n return response;\n }\n numTries += 1;\n if (numTries < maxTries) {\n await response.readBody();\n await this._performExponentialBackoff(numTries);\n }\n } while (numTries < maxTries);\n return response;\n }\n /**\n * Needs to be called if keepAlive is set to true in request options.\n */\n dispose() {\n if (this._agent) {\n this._agent.destroy();\n }\n this._disposed = true;\n }\n /**\n * Raw request.\n * @param info\n * @param data\n */\n async requestRaw(info, data) {\n return new Promise((resolve, reject) => {\n function callbackForResult(err, res) {\n if (err) {\n reject(err);\n }\n else if (!res) {\n // If `err` is not passed, then `res` must be passed.\n reject(new Error('Unknown error'));\n }\n else {\n resolve(res);\n }\n }\n this.requestRawWithCallback(info, data, callbackForResult);\n });\n }\n /**\n * Raw request with callback.\n * @param info\n * @param data\n * @param onResult\n */\n requestRawWithCallback(info, data, onResult) {\n if (typeof data === 'string') {\n if (!info.options.headers) {\n info.options.headers = {};\n }\n info.options.headers['Content-Length'] = Buffer.byteLength(data, 'utf8');\n }\n let callbackCalled = false;\n function handleResult(err, res) {\n if (!callbackCalled) {\n callbackCalled = true;\n onResult(err, res);\n }\n }\n const req = info.httpModule.request(info.options, (msg) => {\n const res = new HttpClientResponse(msg);\n handleResult(undefined, res);\n });\n let socket;\n req.on('socket', sock => {\n socket = sock;\n });\n // If we ever get disconnected, we want the socket to timeout eventually\n req.setTimeout(this._socketTimeout || 3 * 60000, () => {\n if (socket) {\n socket.end();\n }\n handleResult(new Error(`Request timeout: ${info.options.path}`));\n });\n req.on('error', function (err) {\n // err has statusCode property\n // res should have headers\n handleResult(err);\n });\n if (data && typeof data === 'string') {\n req.write(data, 'utf8');\n }\n if (data && typeof data !== 'string') {\n data.on('close', function () {\n req.end();\n });\n data.pipe(req);\n }\n else {\n req.end();\n }\n }\n /**\n * Gets an http agent. This function is useful when you need an http agent that handles\n * routing through a proxy server - depending upon the url and proxy environment variables.\n * @param serverUrl The server URL where the request will be sent. For example, https://api.github.com\n */\n getAgent(serverUrl) {\n const parsedUrl = new URL(serverUrl);\n return this._getAgent(parsedUrl);\n }\n async getAgentDispatcher(serverUrl) {\n const parsedUrl = new URL(serverUrl);\n const proxyUrl = pm.getProxyUrl(parsedUrl);\n const useProxy = proxyUrl && proxyUrl.hostname;\n if (!useProxy) {\n return undefined;\n }\n return await this._getProxyAgentDispatcher(parsedUrl, proxyUrl);\n }\n _prepareRequest(method, requestUrl, headers) {\n const info = {};\n info.parsedUrl = requestUrl;\n const usingSsl = info.parsedUrl.protocol === 'https:';\n info.httpModule = usingSsl ? https : http;\n const defaultPort = usingSsl ? 443 : 80;\n info.options = {};\n info.options.host = info.parsedUrl.hostname;\n info.options.port = info.parsedUrl.port\n ? parseInt(info.parsedUrl.port)\n : defaultPort;\n info.options.path =\n (info.parsedUrl.pathname || '') + (info.parsedUrl.search || '');\n info.options.method = method;\n info.options.headers = this._mergeHeaders(headers);\n if (this.userAgent != null) {\n info.options.headers['user-agent'] = this.userAgent;\n }\n info.options.agent = this._getAgent(info.parsedUrl);\n // gives handlers an opportunity to participate\n if (this.handlers) {\n for (const handler of this.handlers) {\n handler.prepareRequest(info.options);\n }\n }\n return info;\n }\n _mergeHeaders(headers) {\n if (this.requestOptions && this.requestOptions.headers) {\n return Object.assign({}, lowercaseKeys(this.requestOptions.headers), lowercaseKeys(headers || {}));\n }\n return lowercaseKeys(headers || {});\n }\n _getExistingOrDefaultHeader(additionalHeaders, header, _default) {\n let clientHeader;\n if (this.requestOptions && this.requestOptions.headers) {\n clientHeader = lowercaseKeys(this.requestOptions.headers)[header];\n }\n return additionalHeaders[header] || clientHeader || _default;\n }\n _getAgent(parsedUrl) {\n let agent;\n const proxyUrl = pm.getProxyUrl(parsedUrl);\n const useProxy = proxyUrl && proxyUrl.hostname;\n if (this._keepAlive && useProxy) {\n agent = this._proxyAgent;\n }\n if (!useProxy) {\n agent = this._agent;\n }\n // if agent is already assigned use that agent.\n if (agent) {\n return agent;\n }\n const usingSsl = parsedUrl.protocol === 'https:';\n let maxSockets = 100;\n if (this.requestOptions) {\n maxSockets = this.requestOptions.maxSockets || http.globalAgent.maxSockets;\n }\n // This is `useProxy` again, but we need to check `proxyURl` directly for TypeScripts's flow analysis.\n if (proxyUrl && proxyUrl.hostname) {\n const agentOptions = {\n maxSockets,\n keepAlive: this._keepAlive,\n proxy: {\n ...((proxyUrl.username || proxyUrl.password) && {\n proxyAuth: `${proxyUrl.username}:${proxyUrl.password}`\n }),\n host: proxyUrl.hostname,\n port: proxyUrl.port\n }\n };\n let tunnelAgent;\n const overHttps = proxyUrl.protocol === 'https:';\n if (usingSsl) {\n tunnelAgent = overHttps ? tunnel.httpsOverHttps : tunnel.httpsOverHttp;\n }\n else {\n tunnelAgent = overHttps ? tunnel.httpOverHttps : tunnel.httpOverHttp;\n }\n agent = tunnelAgent(agentOptions);\n this._proxyAgent = agent;\n }\n // if tunneling agent isn't assigned create a new agent\n if (!agent) {\n const options = { keepAlive: this._keepAlive, maxSockets };\n agent = usingSsl ? new https.Agent(options) : new http.Agent(options);\n this._agent = agent;\n }\n if (usingSsl && this._ignoreSslError) {\n // we don't want to set NODE_TLS_REJECT_UNAUTHORIZED=0 since that will affect request for entire process\n // http.RequestOptions doesn't expose a way to modify RequestOptions.agent.options\n // we have to cast it to any and change it directly\n agent.options = Object.assign(agent.options || {}, {\n rejectUnauthorized: false\n });\n }\n return agent;\n }\n async _getProxyAgentDispatcher(parsedUrl, proxyUrl) {\n let proxyAgent;\n if (this._keepAlive) {\n proxyAgent = this._proxyAgentDispatcher;\n }\n // if agent is already assigned use that agent.\n if (proxyAgent) {\n return proxyAgent;\n }\n const usingSsl = parsedUrl.protocol === 'https:';\n // Lazy load ProxyAgent to avoid bundling all the undici\n const ProxyAgent = (await import('undici/lib/proxy-agent'));\n proxyAgent = new ProxyAgent({\n uri: proxyUrl.href,\n pipelining: !this._keepAlive ? 0 : 1,\n ...((proxyUrl.username || proxyUrl.password) && {\n token: `Basic ${Buffer.from(`${proxyUrl.username}:${proxyUrl.password}`).toString('base64')}`\n })\n });\n this._proxyAgentDispatcher = proxyAgent;\n if (usingSsl && this._ignoreSslError) {\n // we don't want to set NODE_TLS_REJECT_UNAUTHORIZED=0 since that will affect request for entire process\n // http.RequestOptions doesn't expose a way to modify RequestOptions.agent.options\n // we have to cast it to any and change it directly\n proxyAgent.options = Object.assign(proxyAgent.options.requestTls || {}, {\n rejectUnauthorized: false\n });\n }\n return proxyAgent;\n }\n async _performExponentialBackoff(retryNumber) {\n retryNumber = Math.min(ExponentialBackoffCeiling, retryNumber);\n const ms = ExponentialBackoffTimeSlice * Math.pow(2, retryNumber);\n return new Promise(resolve => setTimeout(() => resolve(), ms));\n }\n async _processResponse(res, options) {\n return new Promise(async (resolve, reject) => {\n const statusCode = res.message.statusCode || 0;\n const response = {\n statusCode,\n result: null,\n headers: {}\n };\n // not found leads to null obj returned\n if (statusCode === HttpCodes.NotFound) {\n resolve(response);\n }\n // get the result from the body\n function dateTimeDeserializer(key, value) {\n if (typeof value === 'string') {\n const a = new Date(value);\n if (!isNaN(a.valueOf())) {\n return a;\n }\n }\n return value;\n }\n let obj;\n let contents;\n try {\n contents = await res.readBody();\n if (contents && contents.length > 0) {\n if (options && options.deserializeDates) {\n obj = JSON.parse(contents, dateTimeDeserializer);\n }\n else {\n obj = JSON.parse(contents);\n }\n response.result = obj;\n }\n response.headers = res.message.headers;\n }\n catch (err) {\n // Invalid resource (contents not json); leaving result obj null\n }\n // note that 3xx redirects are handled by the http layer.\n if (statusCode > 299) {\n let msg;\n // if exception/error in body, attempt to get better error\n if (obj && obj.message) {\n msg = obj.message;\n }\n else if (contents && contents.length > 0) {\n // it may be the case that the exception is in the body message as string\n msg = contents;\n }\n else {\n msg = `Failed request: (${statusCode})`;\n }\n const err = new HttpClientError(msg, statusCode);\n err.result = response.result;\n reject(err);\n }\n else {\n resolve(response);\n }\n });\n }\n}\nconst lowercaseKeys = (obj) => Object.keys(obj).reduce((c, k) => ((c[k.toLowerCase()] = obj[k]), c), {});\n//# sourceMappingURL=index.js.map","\"use strict\";\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.PersonalAccessTokenCredentialHandler = exports.BearerCredentialHandler = exports.BasicCredentialHandler = void 0;\nclass BasicCredentialHandler {\n constructor(username, password) {\n this.username = username;\n this.password = password;\n }\n prepareRequest(options) {\n if (!options.headers) {\n throw Error('The request has no headers');\n }\n options.headers['Authorization'] = `Basic ${Buffer.from(`${this.username}:${this.password}`).toString('base64')}`;\n }\n // This handler cannot handle 401\n canHandleAuthentication() {\n return false;\n }\n handleAuthentication() {\n return __awaiter(this, void 0, void 0, function* () {\n throw new Error('not implemented');\n });\n }\n}\nexports.BasicCredentialHandler = BasicCredentialHandler;\nclass BearerCredentialHandler {\n constructor(token) {\n this.token = token;\n }\n // currently implements pre-authorization\n // TODO: support preAuth = false where it hooks on 401\n prepareRequest(options) {\n if (!options.headers) {\n throw Error('The request has no headers');\n }\n options.headers['Authorization'] = `Bearer ${this.token}`;\n }\n // This handler cannot handle 401\n canHandleAuthentication() {\n return false;\n }\n handleAuthentication() {\n return __awaiter(this, void 0, void 0, function* () {\n throw new Error('not implemented');\n });\n }\n}\nexports.BearerCredentialHandler = BearerCredentialHandler;\nclass PersonalAccessTokenCredentialHandler {\n constructor(token) {\n this.token = token;\n }\n // currently implements pre-authorization\n // TODO: support preAuth = false where it hooks on 401\n prepareRequest(options) {\n if (!options.headers) {\n throw Error('The request has no headers');\n }\n options.headers['Authorization'] = `Basic ${Buffer.from(`PAT:${this.token}`).toString('base64')}`;\n }\n // This handler cannot handle 401\n canHandleAuthentication() {\n return false;\n }\n handleAuthentication() {\n return __awaiter(this, void 0, void 0, function* () {\n throw new Error('not implemented');\n });\n }\n}\nexports.PersonalAccessTokenCredentialHandler = PersonalAccessTokenCredentialHandler;\n//# sourceMappingURL=auth.js.map","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar _a;\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getCmdPath = exports.tryGetExecutablePath = exports.isRooted = exports.isDirectory = exports.exists = exports.READONLY = exports.UV_FS_O_EXLOCK = exports.IS_WINDOWS = exports.unlink = exports.symlink = exports.stat = exports.rmdir = exports.rm = exports.rename = exports.readlink = exports.readdir = exports.open = exports.mkdir = exports.lstat = exports.copyFile = exports.chmod = void 0;\nconst fs = __importStar(require(\"fs\"));\nconst path = __importStar(require(\"path\"));\n_a = fs.promises\n// export const {open} = 'fs'\n, exports.chmod = _a.chmod, exports.copyFile = _a.copyFile, exports.lstat = _a.lstat, exports.mkdir = _a.mkdir, exports.open = _a.open, exports.readdir = _a.readdir, exports.readlink = _a.readlink, exports.rename = _a.rename, exports.rm = _a.rm, exports.rmdir = _a.rmdir, exports.stat = _a.stat, exports.symlink = _a.symlink, exports.unlink = _a.unlink;\n// export const {open} = 'fs'\nexports.IS_WINDOWS = process.platform === 'win32';\n// See https://github.com/nodejs/node/blob/d0153aee367422d0858105abec186da4dff0a0c5/deps/uv/include/uv/win.h#L691\nexports.UV_FS_O_EXLOCK = 0x10000000;\nexports.READONLY = fs.constants.O_RDONLY;\nfunction exists(fsPath) {\n return __awaiter(this, void 0, void 0, function* () {\n try {\n yield exports.stat(fsPath);\n }\n catch (err) {\n if (err.code === 'ENOENT') {\n return false;\n }\n throw err;\n }\n return true;\n });\n}\nexports.exists = exists;\nfunction isDirectory(fsPath, useStat = false) {\n return __awaiter(this, void 0, void 0, function* () {\n const stats = useStat ? yield exports.stat(fsPath) : yield exports.lstat(fsPath);\n return stats.isDirectory();\n });\n}\nexports.isDirectory = isDirectory;\n/**\n * On OSX/Linux, true if path starts with '/'. On Windows, true for paths like:\n * \\, \\hello, \\\\hello\\share, C:, and C:\\hello (and corresponding alternate separator cases).\n */\nfunction isRooted(p) {\n p = normalizeSeparators(p);\n if (!p) {\n throw new Error('isRooted() parameter \"p\" cannot be empty');\n }\n if (exports.IS_WINDOWS) {\n return (p.startsWith('\\\\') || /^[A-Z]:/i.test(p) // e.g. \\ or \\hello or \\\\hello\n ); // e.g. C: or C:\\hello\n }\n return p.startsWith('/');\n}\nexports.isRooted = isRooted;\n/**\n * Best effort attempt to determine whether a file exists and is executable.\n * @param filePath file path to check\n * @param extensions additional file extensions to try\n * @return if file exists and is executable, returns the file path. otherwise empty string.\n */\nfunction tryGetExecutablePath(filePath, extensions) {\n return __awaiter(this, void 0, void 0, function* () {\n let stats = undefined;\n try {\n // test file exists\n stats = yield exports.stat(filePath);\n }\n catch (err) {\n if (err.code !== 'ENOENT') {\n // eslint-disable-next-line no-console\n console.log(`Unexpected error attempting to determine if executable file exists '${filePath}': ${err}`);\n }\n }\n if (stats && stats.isFile()) {\n if (exports.IS_WINDOWS) {\n // on Windows, test for valid extension\n const upperExt = path.extname(filePath).toUpperCase();\n if (extensions.some(validExt => validExt.toUpperCase() === upperExt)) {\n return filePath;\n }\n }\n else {\n if (isUnixExecutable(stats)) {\n return filePath;\n }\n }\n }\n // try each extension\n const originalFilePath = filePath;\n for (const extension of extensions) {\n filePath = originalFilePath + extension;\n stats = undefined;\n try {\n stats = yield exports.stat(filePath);\n }\n catch (err) {\n if (err.code !== 'ENOENT') {\n // eslint-disable-next-line no-console\n console.log(`Unexpected error attempting to determine if executable file exists '${filePath}': ${err}`);\n }\n }\n if (stats && stats.isFile()) {\n if (exports.IS_WINDOWS) {\n // preserve the case of the actual file (since an extension was appended)\n try {\n const directory = path.dirname(filePath);\n const upperName = path.basename(filePath).toUpperCase();\n for (const actualName of yield exports.readdir(directory)) {\n if (upperName === actualName.toUpperCase()) {\n filePath = path.join(directory, actualName);\n break;\n }\n }\n }\n catch (err) {\n // eslint-disable-next-line no-console\n console.log(`Unexpected error attempting to determine the actual case of the file '${filePath}': ${err}`);\n }\n return filePath;\n }\n else {\n if (isUnixExecutable(stats)) {\n return filePath;\n }\n }\n }\n }\n return '';\n });\n}\nexports.tryGetExecutablePath = tryGetExecutablePath;\nfunction normalizeSeparators(p) {\n p = p || '';\n if (exports.IS_WINDOWS) {\n // convert slashes on Windows\n p = p.replace(/\\//g, '\\\\');\n // remove redundant slashes\n return p.replace(/\\\\\\\\+/g, '\\\\');\n }\n // remove redundant slashes\n return p.replace(/\\/\\/+/g, '/');\n}\n// on Mac/Linux, test the execute bit\n// R W X R W X R W X\n// 256 128 64 32 16 8 4 2 1\nfunction isUnixExecutable(stats) {\n return ((stats.mode & 1) > 0 ||\n ((stats.mode & 8) > 0 && stats.gid === process.getgid()) ||\n ((stats.mode & 64) > 0 && stats.uid === process.getuid()));\n}\n// Get the path of cmd.exe in windows\nfunction getCmdPath() {\n var _a;\n return (_a = process.env['COMSPEC']) !== null && _a !== void 0 ? _a : `cmd.exe`;\n}\nexports.getCmdPath = getCmdPath;\n//# sourceMappingURL=io-util.js.map","import {fileURLToPath} from 'node:url';\n\n// Allow some arguments/options to be either a file path string or a file URL\nexport const safeNormalizeFileUrl = (file, name) => {\n\tconst fileString = normalizeFileUrl(normalizeDenoExecPath(file));\n\n\tif (typeof fileString !== 'string') {\n\t\tthrow new TypeError(`${name} must be a string or a file URL: ${fileString}.`);\n\t}\n\n\treturn fileString;\n};\n\n// In Deno node:process execPath is a special object, not just a string:\n// https://github.com/denoland/deno/blob/f460188e583f00144000aa0d8ade08218d47c3c1/ext/node/polyfills/process.ts#L344\nconst normalizeDenoExecPath = file => isDenoExecPath(file)\n\t? file.toString()\n\t: file;\n\nexport const isDenoExecPath = file => typeof file !== 'string'\n\t&& file\n\t&& Object.getPrototypeOf(file) === String.prototype;\n\n// Same but also allows other values, e.g. `boolean` for the `shell` option\nexport const normalizeFileUrl = file => file instanceof URL ? fileURLToPath(file) : file;\n","import isPlainObject from 'is-plain-obj';\nimport {safeNormalizeFileUrl} from '../arguments/file-url.js';\n\n// The command `arguments` and `options` are both optional.\n// This also does basic validation on them and on the command file.\nexport const normalizeParameters = (rawFile, rawArguments = [], rawOptions = {}) => {\n\tconst filePath = safeNormalizeFileUrl(rawFile, 'First argument');\n\tconst [commandArguments, options] = isPlainObject(rawArguments)\n\t\t? [[], rawArguments]\n\t\t: [rawArguments, rawOptions];\n\n\tif (!Array.isArray(commandArguments)) {\n\t\tthrow new TypeError(`Second argument must be either an array of arguments or an options object: ${commandArguments}`);\n\t}\n\n\tif (commandArguments.some(commandArgument => typeof commandArgument === 'object' && commandArgument !== null)) {\n\t\tthrow new TypeError(`Second argument must be an array of strings: ${commandArguments}`);\n\t}\n\n\tconst normalizedArguments = commandArguments.map(String);\n\tconst nullByteArgument = normalizedArguments.find(normalizedArgument => normalizedArgument.includes('\\0'));\n\tif (nullByteArgument !== undefined) {\n\t\tthrow new TypeError(`Arguments cannot contain null bytes (\"\\\\0\"): ${nullByteArgument}`);\n\t}\n\n\tif (!isPlainObject(options)) {\n\t\tthrow new TypeError(`Last argument must be an options object: ${options}`);\n\t}\n\n\treturn [filePath, normalizedArguments, options];\n};\n","import {StringDecoder} from 'node:string_decoder';\n\nconst {toString: objectToString} = Object.prototype;\n\nexport const isArrayBuffer = value => objectToString.call(value) === '[object ArrayBuffer]';\n\n// Is either Uint8Array or Buffer\nexport const isUint8Array = value => objectToString.call(value) === '[object Uint8Array]';\n\nexport const bufferToUint8Array = buffer => new Uint8Array(buffer.buffer, buffer.byteOffset, buffer.byteLength);\n\nconst textEncoder = new TextEncoder();\nconst stringToUint8Array = string => textEncoder.encode(string);\n\nconst textDecoder = new TextDecoder();\nexport const uint8ArrayToString = uint8Array => textDecoder.decode(uint8Array);\n\nexport const joinToString = (uint8ArraysOrStrings, encoding) => {\n\tconst strings = uint8ArraysToStrings(uint8ArraysOrStrings, encoding);\n\treturn strings.join('');\n};\n\nconst uint8ArraysToStrings = (uint8ArraysOrStrings, encoding) => {\n\tif (encoding === 'utf8' && uint8ArraysOrStrings.every(uint8ArrayOrString => typeof uint8ArrayOrString === 'string')) {\n\t\treturn uint8ArraysOrStrings;\n\t}\n\n\tconst decoder = new StringDecoder(encoding);\n\tconst strings = uint8ArraysOrStrings\n\t\t.map(uint8ArrayOrString => typeof uint8ArrayOrString === 'string'\n\t\t\t? stringToUint8Array(uint8ArrayOrString)\n\t\t\t: uint8ArrayOrString)\n\t\t.map(uint8Array => decoder.write(uint8Array));\n\tconst finalString = decoder.end();\n\treturn finalString === '' ? strings : [...strings, finalString];\n};\n\nexport const joinToUint8Array = uint8ArraysOrStrings => {\n\tif (uint8ArraysOrStrings.length === 1 && isUint8Array(uint8ArraysOrStrings[0])) {\n\t\treturn uint8ArraysOrStrings[0];\n\t}\n\n\treturn concatUint8Arrays(stringsToUint8Arrays(uint8ArraysOrStrings));\n};\n\nconst stringsToUint8Arrays = uint8ArraysOrStrings => uint8ArraysOrStrings.map(uint8ArrayOrString => typeof uint8ArrayOrString === 'string'\n\t? stringToUint8Array(uint8ArrayOrString)\n\t: uint8ArrayOrString);\n\nexport const concatUint8Arrays = uint8Arrays => {\n\tconst result = new Uint8Array(getJoinLength(uint8Arrays));\n\n\tlet index = 0;\n\tfor (const uint8Array of uint8Arrays) {\n\t\tresult.set(uint8Array, index);\n\t\tindex += uint8Array.length;\n\t}\n\n\treturn result;\n};\n\nconst getJoinLength = uint8Arrays => {\n\tlet joinLength = 0;\n\tfor (const uint8Array of uint8Arrays) {\n\t\tjoinLength += uint8Array.length;\n\t}\n\n\treturn joinLength;\n};\n","import {ChildProcess} from 'node:child_process';\nimport isPlainObject from 'is-plain-obj';\nimport {isUint8Array, uint8ArrayToString} from '../utils/uint-array.js';\n\n// Check whether the template string syntax is being used\nexport const isTemplateString = templates => Array.isArray(templates) && Array.isArray(templates.raw);\n\n// Convert execa`file ...commandArguments` to execa(file, commandArguments)\nexport const parseTemplates = (templates, expressions) => {\n\tlet tokens = [];\n\n\tfor (const [index, template] of templates.entries()) {\n\t\ttokens = parseTemplate({\n\t\t\ttemplates,\n\t\t\texpressions,\n\t\t\ttokens,\n\t\t\tindex,\n\t\t\ttemplate,\n\t\t});\n\t}\n\n\tif (tokens.length === 0) {\n\t\tthrow new TypeError('Template script must not be empty');\n\t}\n\n\tconst [file, ...commandArguments] = tokens;\n\treturn [file, commandArguments, {}];\n};\n\nconst parseTemplate = ({templates, expressions, tokens, index, template}) => {\n\tif (template === undefined) {\n\t\tthrow new TypeError(`Invalid backslash sequence: ${templates.raw[index]}`);\n\t}\n\n\tconst {nextTokens, leadingWhitespaces, trailingWhitespaces} = splitByWhitespaces(template, templates.raw[index]);\n\tconst newTokens = concatTokens(tokens, nextTokens, leadingWhitespaces);\n\n\tif (index === expressions.length) {\n\t\treturn newTokens;\n\t}\n\n\tconst expression = expressions[index];\n\tconst expressionTokens = Array.isArray(expression)\n\t\t? expression.map(expression => parseExpression(expression))\n\t\t: [parseExpression(expression)];\n\treturn concatTokens(newTokens, expressionTokens, trailingWhitespaces);\n};\n\n// Like `string.split(/[ \\t\\r\\n]+/)` except newlines and tabs are:\n// - ignored when input as a backslash sequence like: `echo foo\\n bar`\n// - not ignored when input directly\n// The only way to distinguish those in JavaScript is to use a tagged template and compare:\n// - the first array argument, which does not escape backslash sequences\n// - its `raw` property, which escapes them\nconst splitByWhitespaces = (template, rawTemplate) => {\n\tif (rawTemplate.length === 0) {\n\t\treturn {nextTokens: [], leadingWhitespaces: false, trailingWhitespaces: false};\n\t}\n\n\tconst nextTokens = [];\n\tlet templateStart = 0;\n\tconst leadingWhitespaces = DELIMITERS.has(rawTemplate[0]);\n\n\tfor (\n\t\tlet templateIndex = 0, rawIndex = 0;\n\t\ttemplateIndex < template.length;\n\t\ttemplateIndex += 1, rawIndex += 1\n\t) {\n\t\tconst rawCharacter = rawTemplate[rawIndex];\n\t\tif (DELIMITERS.has(rawCharacter)) {\n\t\t\tif (templateStart !== templateIndex) {\n\t\t\t\tnextTokens.push(template.slice(templateStart, templateIndex));\n\t\t\t}\n\n\t\t\ttemplateStart = templateIndex + 1;\n\t\t} else if (rawCharacter === '\\\\') {\n\t\t\tconst nextRawCharacter = rawTemplate[rawIndex + 1];\n\t\t\tif (nextRawCharacter === 'u' && rawTemplate[rawIndex + 2] === '{') {\n\t\t\t\trawIndex = rawTemplate.indexOf('}', rawIndex + 3);\n\t\t\t} else {\n\t\t\t\trawIndex += ESCAPE_LENGTH[nextRawCharacter] ?? 1;\n\t\t\t}\n\t\t}\n\t}\n\n\tconst trailingWhitespaces = templateStart === template.length;\n\tif (!trailingWhitespaces) {\n\t\tnextTokens.push(template.slice(templateStart));\n\t}\n\n\treturn {nextTokens, leadingWhitespaces, trailingWhitespaces};\n};\n\nconst DELIMITERS = new Set([' ', '\\t', '\\r', '\\n']);\n\n// Number of characters in backslash escape sequences: \\0 \\xXX or \\uXXXX\n// \\cX is allowed in RegExps but not in strings\n// Octal sequences are not allowed in strict mode\nconst ESCAPE_LENGTH = {x: 3, u: 5};\n\nconst concatTokens = (tokens, nextTokens, isSeparated) => isSeparated\n\t|| tokens.length === 0\n\t|| nextTokens.length === 0\n\t? [...tokens, ...nextTokens]\n\t: [\n\t\t...tokens.slice(0, -1),\n\t\t`${tokens.at(-1)}${nextTokens[0]}`,\n\t\t...nextTokens.slice(1),\n\t];\n\n// Handle `${expression}` inside the template string syntax\nconst parseExpression = expression => {\n\tconst typeOfExpression = typeof expression;\n\n\tif (typeOfExpression === 'string') {\n\t\treturn expression;\n\t}\n\n\tif (typeOfExpression === 'number') {\n\t\treturn String(expression);\n\t}\n\n\tif (isPlainObject(expression) && ('stdout' in expression || 'isMaxBuffer' in expression)) {\n\t\treturn getSubprocessResult(expression);\n\t}\n\n\tif (expression instanceof ChildProcess || Object.prototype.toString.call(expression) === '[object Promise]') {\n\t\t// eslint-disable-next-line no-template-curly-in-string\n\t\tthrow new TypeError('Unexpected subprocess in template expression. Please use ${await subprocess} instead of ${subprocess}.');\n\t}\n\n\tthrow new TypeError(`Unexpected \"${typeOfExpression}\" in template expression`);\n};\n\nconst getSubprocessResult = ({stdout}) => {\n\tif (typeof stdout === 'string') {\n\t\treturn stdout;\n\t}\n\n\tif (isUint8Array(stdout)) {\n\t\treturn uint8ArrayToString(stdout);\n\t}\n\n\tif (stdout === undefined) {\n\t\tthrow new TypeError('Missing result.stdout in template expression. This is probably due to the previous subprocess\\' \"stdout\" option.');\n\t}\n\n\tthrow new TypeError(`Unexpected \"${typeof stdout}\" stdout in template expression`);\n};\n","import process from 'node:process';\n\nexport const isStandardStream = stream => STANDARD_STREAMS.includes(stream);\nexport const STANDARD_STREAMS = [process.stdin, process.stdout, process.stderr];\nexport const STANDARD_STREAMS_ALIASES = ['stdin', 'stdout', 'stderr'];\nexport const getStreamName = fdNumber => STANDARD_STREAMS_ALIASES[fdNumber] ?? `stdio[${fdNumber}]`;\n","import {debuglog} from 'node:util';\nimport isPlainObject from 'is-plain-obj';\nimport {STANDARD_STREAMS_ALIASES} from '../utils/standard-stream.js';\n\n// Some options can have different values for `stdout`/`stderr`/`fd3`.\n// This normalizes those to array of values.\n// For example, `{verbose: {stdout: 'none', stderr: 'full'}}` becomes `{verbose: ['none', 'none', 'full']}`\nexport const normalizeFdSpecificOptions = options => {\n\tconst optionsCopy = {...options};\n\n\tfor (const optionName of FD_SPECIFIC_OPTIONS) {\n\t\toptionsCopy[optionName] = normalizeFdSpecificOption(options, optionName);\n\t}\n\n\treturn optionsCopy;\n};\n\nexport const normalizeFdSpecificOption = (options, optionName) => {\n\tconst optionBaseArray = Array.from({length: getStdioLength(options) + 1});\n\tconst optionArray = normalizeFdSpecificValue(options[optionName], optionBaseArray, optionName);\n\treturn addDefaultValue(optionArray, optionName);\n};\n\nconst getStdioLength = ({stdio}) => Array.isArray(stdio)\n\t? Math.max(stdio.length, STANDARD_STREAMS_ALIASES.length)\n\t: STANDARD_STREAMS_ALIASES.length;\n\nconst normalizeFdSpecificValue = (optionValue, optionArray, optionName) => isPlainObject(optionValue)\n\t? normalizeOptionObject(optionValue, optionArray, optionName)\n\t: optionArray.fill(optionValue);\n\nconst normalizeOptionObject = (optionValue, optionArray, optionName) => {\n\tfor (const fdName of Object.keys(optionValue).sort(compareFdName)) {\n\t\tfor (const fdNumber of parseFdName(fdName, optionName, optionArray)) {\n\t\t\toptionArray[fdNumber] = optionValue[fdName];\n\t\t}\n\t}\n\n\treturn optionArray;\n};\n\n// Ensure priority order when setting both `stdout`/`stderr`, `fd1`/`fd2`, and `all`\nconst compareFdName = (fdNameA, fdNameB) => getFdNameOrder(fdNameA) < getFdNameOrder(fdNameB) ? 1 : -1;\n\nconst getFdNameOrder = fdName => {\n\tif (fdName === 'stdout' || fdName === 'stderr') {\n\t\treturn 0;\n\t}\n\n\treturn fdName === 'all' ? 2 : 1;\n};\n\nconst parseFdName = (fdName, optionName, optionArray) => {\n\tif (fdName === 'ipc') {\n\t\treturn [optionArray.length - 1];\n\t}\n\n\tconst fdNumber = parseFd(fdName);\n\tif (fdNumber === undefined || fdNumber === 0) {\n\t\tthrow new TypeError(`\"${optionName}.${fdName}\" is invalid.\nIt must be \"${optionName}.stdout\", \"${optionName}.stderr\", \"${optionName}.all\", \"${optionName}.ipc\", or \"${optionName}.fd3\", \"${optionName}.fd4\" (and so on).`);\n\t}\n\n\tif (fdNumber >= optionArray.length) {\n\t\tthrow new TypeError(`\"${optionName}.${fdName}\" is invalid: that file descriptor does not exist.\nPlease set the \"stdio\" option to ensure that file descriptor exists.`);\n\t}\n\n\treturn fdNumber === 'all' ? [1, 2] : [fdNumber];\n};\n\n// Use the same syntax for fd-specific options and the `from`/`to` options\nexport const parseFd = fdName => {\n\tif (fdName === 'all') {\n\t\treturn fdName;\n\t}\n\n\tif (STANDARD_STREAMS_ALIASES.includes(fdName)) {\n\t\treturn STANDARD_STREAMS_ALIASES.indexOf(fdName);\n\t}\n\n\tconst regexpResult = FD_REGEXP.exec(fdName);\n\tif (regexpResult !== null) {\n\t\treturn Number(regexpResult[1]);\n\t}\n};\n\nconst FD_REGEXP = /^fd(\\d+)$/;\n\nconst addDefaultValue = (optionArray, optionName) => optionArray.map(optionValue => optionValue === undefined\n\t? DEFAULT_OPTIONS[optionName]\n\t: optionValue);\n\n// Default value for the `verbose` option\nconst verboseDefault = debuglog('execa').enabled ? 'full' : 'none';\n\nconst DEFAULT_OPTIONS = {\n\tlines: false,\n\tbuffer: true,\n\tmaxBuffer: 1000 * 1000 * 100,\n\tverbose: verboseDefault,\n\tstripFinalNewline: true,\n};\n\n// List of options which can have different values for `stdout`/`stderr`\nexport const FD_SPECIFIC_OPTIONS = ['lines', 'buffer', 'maxBuffer', 'verbose', 'stripFinalNewline'];\n\n// Retrieve fd-specific option\nexport const getFdSpecificValue = (optionArray, fdNumber) => fdNumber === 'ipc'\n\t? optionArray.at(-1)\n\t: optionArray[fdNumber];\n","import {getFdSpecificValue} from '../arguments/specific.js';\n\n// The `verbose` option can have different values for `stdout`/`stderr`\nexport const isVerbose = ({verbose}, fdNumber) => getFdVerbose(verbose, fdNumber) !== 'none';\n\n// Whether IPC and output and logged\nexport const isFullVerbose = ({verbose}, fdNumber) => !['none', 'short'].includes(getFdVerbose(verbose, fdNumber));\n\n// The `verbose` option can be a function to customize logging\nexport const getVerboseFunction = ({verbose}, fdNumber) => {\n\tconst fdVerbose = getFdVerbose(verbose, fdNumber);\n\treturn isVerboseFunction(fdVerbose) ? fdVerbose : undefined;\n};\n\n// When using `verbose: {stdout, stderr, fd3, ipc}`:\n// - `verbose.stdout|stderr|fd3` is used for 'output'\n// - `verbose.ipc` is only used for 'ipc'\n// - highest `verbose.*` value is used for 'command', 'error' and 'duration'\nconst getFdVerbose = (verbose, fdNumber) => fdNumber === undefined\n\t? getFdGenericVerbose(verbose)\n\t: getFdSpecificValue(verbose, fdNumber);\n\n// When using `verbose: {stdout, stderr, fd3, ipc}` and logging is not specific to a file descriptor.\n// We then use the highest `verbose.*` value, using the following order:\n// - function > 'full' > 'short' > 'none'\n// - if several functions are defined: stdout > stderr > fd3 > ipc\nconst getFdGenericVerbose = verbose => verbose.find(fdVerbose => isVerboseFunction(fdVerbose))\n\t?? VERBOSE_VALUES.findLast(fdVerbose => verbose.includes(fdVerbose));\n\n// Whether the `verbose` option is customized using a function\nexport const isVerboseFunction = fdVerbose => typeof fdVerbose === 'function';\n\nexport const VERBOSE_VALUES = ['none', 'short', 'full'];\n","import {platform} from 'node:process';\nimport {stripVTControlCharacters} from 'node:util';\n\n// Compute `result.command` and `result.escapedCommand`\nexport const joinCommand = (filePath, rawArguments) => {\n\tconst fileAndArguments = [filePath, ...rawArguments];\n\tconst command = fileAndArguments.join(' ');\n\tconst escapedCommand = fileAndArguments\n\t\t.map(fileAndArgument => quoteString(escapeControlCharacters(fileAndArgument)))\n\t\t.join(' ');\n\treturn {command, escapedCommand};\n};\n\n// Remove ANSI sequences and escape control characters and newlines\nexport const escapeLines = lines => stripVTControlCharacters(lines)\n\t.split('\\n')\n\t.map(line => escapeControlCharacters(line))\n\t.join('\\n');\n\nconst escapeControlCharacters = line => line.replaceAll(SPECIAL_CHAR_REGEXP, character => escapeControlCharacter(character));\n\nconst escapeControlCharacter = character => {\n\tconst commonEscape = COMMON_ESCAPES[character];\n\tif (commonEscape !== undefined) {\n\t\treturn commonEscape;\n\t}\n\n\tconst codepoint = character.codePointAt(0);\n\tconst codepointHex = codepoint.toString(16);\n\treturn codepoint <= ASTRAL_START\n\t\t? `\\\\u${codepointHex.padStart(4, '0')}`\n\t\t: `\\\\U${codepointHex}`;\n};\n\n// Characters that would create issues when printed are escaped using the \\u or \\U notation.\n// Those include control characters and newlines.\n// The \\u and \\U notation is Bash specific, but there is no way to do this in a shell-agnostic way.\n// Some shells do not even have a way to print those characters in an escaped fashion.\n// Therefore, we prioritize printing those safely, instead of allowing those to be copy-pasted.\n// List of Unicode character categories: https://www.fileformat.info/info/unicode/category/index.htm\nconst getSpecialCharRegExp = () => {\n\ttry {\n\t\t// This throws when using Node.js without ICU support.\n\t\t// When using a RegExp literal, this would throw at parsing-time, instead of runtime.\n\t\t// eslint-disable-next-line prefer-regex-literals\n\t\treturn new RegExp('\\\\p{Separator}|\\\\p{Other}', 'gu');\n\t} catch {\n\t\t// Similar to the above RegExp, but works even when Node.js has been built without ICU support.\n\t\t// Unlike the above RegExp, it only covers whitespaces and C0/C1 control characters.\n\t\t// It does not cover some edge cases, such as Unicode reserved characters.\n\t\t// See https://github.com/sindresorhus/execa/issues/1143\n\t\t// eslint-disable-next-line no-control-regex\n\t\treturn /[\\s\\u0000-\\u001F\\u007F-\\u009F\\u00AD]/g;\n\t}\n};\n\nconst SPECIAL_CHAR_REGEXP = getSpecialCharRegExp();\n\n// Accepted by $'...' in Bash.\n// Exclude \\a \\e \\v which are accepted in Bash but not in JavaScript (except \\v) and JSON.\nconst COMMON_ESCAPES = {\n\t' ': ' ',\n\t'\\b': '\\\\b',\n\t'\\f': '\\\\f',\n\t'\\n': '\\\\n',\n\t'\\r': '\\\\r',\n\t'\\t': '\\\\t',\n};\n\n// Up until that codepoint, \\u notation can be used instead of \\U\nconst ASTRAL_START = 65_535;\n\n// Some characters are shell-specific, i.e. need to be escaped when the command is copy-pasted then run.\n// Escaping is shell-specific. We cannot know which shell is used: `process.platform` detection is not enough.\n// For example, Windows users could be using `cmd.exe`, Powershell or Bash for Windows which all use different escaping.\n// We use '...' on Unix, which is POSIX shell compliant and escape all characters but ' so this is fairly safe.\n// On Windows, we assume cmd.exe is used and escape with \"...\", which also works with Powershell.\nconst quoteString = escapedArgument => {\n\tif (NO_ESCAPE_REGEXP.test(escapedArgument)) {\n\t\treturn escapedArgument;\n\t}\n\n\treturn platform === 'win32'\n\t\t? `\"${escapedArgument.replaceAll('\"', '\"\"')}\"`\n\t\t: `'${escapedArgument.replaceAll('\\'', '\\'\\\\\\'\\'')}'`;\n};\n\nconst NO_ESCAPE_REGEXP = /^[\\w./-]+$/;\n","import isUnicodeSupported from 'is-unicode-supported';\n\nconst common = {\n\tcircleQuestionMark: '(?)',\n\tquestionMarkPrefix: '(?)',\n\tsquare: '█',\n\tsquareDarkShade: '▓',\n\tsquareMediumShade: '▒',\n\tsquareLightShade: '░',\n\tsquareTop: '▀',\n\tsquareBottom: '▄',\n\tsquareLeft: '▌',\n\tsquareRight: '▐',\n\tsquareCenter: '■',\n\tbullet: '●',\n\tdot: '',\n\tellipsis: '…',\n\tpointerSmall: '',\n\ttriangleUp: '▲',\n\ttriangleUpSmall: '▴',\n\ttriangleDown: '▼',\n\ttriangleDownSmall: '▾',\n\ttriangleLeftSmall: '◂',\n\ttriangleRightSmall: '▸',\n\thome: '⌂',\n\theart: '♥',\n\tmusicNote: '♪',\n\tmusicNoteBeamed: '♫',\n\tarrowUp: '↑',\n\tarrowDown: '↓',\n\tarrowLeft: '←',\n\tarrowRight: '→',\n\tarrowLeftRight: '↔',\n\tarrowUpDown: '↕',\n\talmostEqual: '≈',\n\tnotEqual: '≠',\n\tlessOrEqual: '≤',\n\tgreaterOrEqual: '≥',\n\tidentical: '≡',\n\tinfinity: '∞',\n\tsubscriptZero: '₀',\n\tsubscriptOne: '₁',\n\tsubscriptTwo: '₂',\n\tsubscriptThree: '₃',\n\tsubscriptFour: '₄',\n\tsubscriptFive: '₅',\n\tsubscriptSix: '₆',\n\tsubscriptSeven: '₇',\n\tsubscriptEight: '₈',\n\tsubscriptNine: '₉',\n\toneHalf: '½',\n\toneThird: '⅓',\n\toneQuarter: '¼',\n\toneFifth: '⅕',\n\toneSixth: '⅙',\n\toneEighth: '⅛',\n\ttwoThirds: '⅔',\n\ttwoFifths: '⅖',\n\tthreeQuarters: '¾',\n\tthreeFifths: '⅗',\n\tthreeEighths: '⅜',\n\tfourFifths: '⅘',\n\tfiveSixths: '⅚',\n\tfiveEighths: '⅝',\n\tsevenEighths: '⅞',\n\tline: '─',\n\tlineBold: '━',\n\tlineDouble: '═',\n\tlineDashed0: '┄',\n\tlineDashed1: '┅',\n\tlineDashed2: '┈',\n\tlineDashed3: '┉',\n\tlineDashed4: '╌',\n\tlineDashed5: '╍',\n\tlineDashed6: '╴',\n\tlineDashed7: '╶',\n\tlineDashed8: '╸',\n\tlineDashed9: '╺',\n\tlineDashed10: '╼',\n\tlineDashed11: '╾',\n\tlineDashed12: '',\n\tlineDashed13: '',\n\tlineDashed14: '',\n\tlineDashed15: '',\n\tlineVertical: '│',\n\tlineVerticalBold: '┃',\n\tlineVerticalDouble: '║',\n\tlineVerticalDashed0: '┆',\n\tlineVerticalDashed1: '┇',\n\tlineVerticalDashed2: '┊',\n\tlineVerticalDashed3: '┋',\n\tlineVerticalDashed4: '╎',\n\tlineVerticalDashed5: '╏',\n\tlineVerticalDashed6: '╵',\n\tlineVerticalDashed7: '╷',\n\tlineVerticalDashed8: '╹',\n\tlineVerticalDashed9: '╻',\n\tlineVerticalDashed10: '╽',\n\tlineVerticalDashed11: '╿',\n\tlineDownLeft: '┐',\n\tlineDownLeftArc: '╮',\n\tlineDownBoldLeftBold: '┓',\n\tlineDownBoldLeft: '┒',\n\tlineDownLeftBold: '┑',\n\tlineDownDoubleLeftDouble: '╗',\n\tlineDownDoubleLeft: '╖',\n\tlineDownLeftDouble: '╕',\n\tlineDownRight: '┌',\n\tlineDownRightArc: '╭',\n\tlineDownBoldRightBold: '┏',\n\tlineDownBoldRight: '┎',\n\tlineDownRightBold: '┍',\n\tlineDownDoubleRightDouble: '╔',\n\tlineDownDoubleRight: '╓',\n\tlineDownRightDouble: '╒',\n\tlineUpLeft: '┘',\n\tlineUpLeftArc: '╯',\n\tlineUpBoldLeftBold: '┛',\n\tlineUpBoldLeft: '┚',\n\tlineUpLeftBold: '┙',\n\tlineUpDoubleLeftDouble: '╝',\n\tlineUpDoubleLeft: '╜',\n\tlineUpLeftDouble: '╛',\n\tlineUpRight: '└',\n\tlineUpRightArc: '╰',\n\tlineUpBoldRightBold: '┗',\n\tlineUpBoldRight: '┖',\n\tlineUpRightBold: '┕',\n\tlineUpDoubleRightDouble: '╚',\n\tlineUpDoubleRight: '╙',\n\tlineUpRightDouble: '╘',\n\tlineUpDownLeft: '┤',\n\tlineUpBoldDownBoldLeftBold: '┫',\n\tlineUpBoldDownBoldLeft: '┨',\n\tlineUpDownLeftBold: '┥',\n\tlineUpBoldDownLeftBold: '┩',\n\tlineUpDownBoldLeftBold: '┪',\n\tlineUpDownBoldLeft: '┧',\n\tlineUpBoldDownLeft: '┦',\n\tlineUpDoubleDownDoubleLeftDouble: '╣',\n\tlineUpDoubleDownDoubleLeft: '╢',\n\tlineUpDownLeftDouble: '╡',\n\tlineUpDownRight: '├',\n\tlineUpBoldDownBoldRightBold: '┣',\n\tlineUpBoldDownBoldRight: '┠',\n\tlineUpDownRightBold: '┝',\n\tlineUpBoldDownRightBold: '┡',\n\tlineUpDownBoldRightBold: '┢',\n\tlineUpDownBoldRight: '┟',\n\tlineUpBoldDownRight: '┞',\n\tlineUpDoubleDownDoubleRightDouble: '╠',\n\tlineUpDoubleDownDoubleRight: '╟',\n\tlineUpDownRightDouble: '╞',\n\tlineDownLeftRight: '┬',\n\tlineDownBoldLeftBoldRightBold: '┳',\n\tlineDownLeftBoldRightBold: '┯',\n\tlineDownBoldLeftRight: '┰',\n\tlineDownBoldLeftBoldRight: '┱',\n\tlineDownBoldLeftRightBold: '┲',\n\tlineDownLeftRightBold: '┮',\n\tlineDownLeftBoldRight: '┭',\n\tlineDownDoubleLeftDoubleRightDouble: '╦',\n\tlineDownDoubleLeftRight: '╥',\n\tlineDownLeftDoubleRightDouble: '╤',\n\tlineUpLeftRight: '┴',\n\tlineUpBoldLeftBoldRightBold: '┻',\n\tlineUpLeftBoldRightBold: '┷',\n\tlineUpBoldLeftRight: '┸',\n\tlineUpBoldLeftBoldRight: '┹',\n\tlineUpBoldLeftRightBold: '┺',\n\tlineUpLeftRightBold: '┶',\n\tlineUpLeftBoldRight: '┵',\n\tlineUpDoubleLeftDoubleRightDouble: '╩',\n\tlineUpDoubleLeftRight: '╨',\n\tlineUpLeftDoubleRightDouble: '╧',\n\tlineUpDownLeftRight: '┼',\n\tlineUpBoldDownBoldLeftBoldRightBold: '╋',\n\tlineUpDownBoldLeftBoldRightBold: '╈',\n\tlineUpBoldDownLeftBoldRightBold: '╇',\n\tlineUpBoldDownBoldLeftRightBold: '╊',\n\tlineUpBoldDownBoldLeftBoldRight: '╉',\n\tlineUpBoldDownLeftRight: '╀',\n\tlineUpDownBoldLeftRight: '╁',\n\tlineUpDownLeftBoldRight: '┽',\n\tlineUpDownLeftRightBold: '┾',\n\tlineUpBoldDownBoldLeftRight: '╂',\n\tlineUpDownLeftBoldRightBold: '┿',\n\tlineUpBoldDownLeftBoldRight: '╃',\n\tlineUpBoldDownLeftRightBold: '╄',\n\tlineUpDownBoldLeftBoldRight: '╅',\n\tlineUpDownBoldLeftRightBold: '╆',\n\tlineUpDoubleDownDoubleLeftDoubleRightDouble: '╬',\n\tlineUpDoubleDownDoubleLeftRight: '╫',\n\tlineUpDownLeftDoubleRightDouble: '╪',\n\tlineCross: '',\n\tlineBackslash: '╲',\n\tlineSlash: '',\n};\n\nconst specialMainSymbols = {\n\ttick: '✔',\n\tinfo: '',\n\twarning: '⚠',\n\tcross: '✘',\n\tsquareSmall: '◻',\n\tsquareSmallFilled: '◼',\n\tcircle: '◯',\n\tcircleFilled: '◉',\n\tcircleDotted: '◌',\n\tcircleDouble: '◎',\n\tcircleCircle: 'ⓞ',\n\tcircleCross: 'ⓧ',\n\tcirclePipe: 'Ⓘ',\n\tradioOn: '◉',\n\tradioOff: '◯',\n\tcheckboxOn: '☒',\n\tcheckboxOff: '☐',\n\tcheckboxCircleOn: 'ⓧ',\n\tcheckboxCircleOff: 'Ⓘ',\n\tpointer: '',\n\ttriangleUpOutline: '△',\n\ttriangleLeft: '◀',\n\ttriangleRight: '▶',\n\tlozenge: '◆',\n\tlozengeOutline: '◇',\n\thamburger: '☰',\n\tsmiley: '㋡',\n\tmustache: '෴',\n\tstar: '★',\n\tplay: '▶',\n\tnodejs: '⬢',\n\toneSeventh: '⅐',\n\toneNinth: '⅑',\n\toneTenth: '⅒',\n};\n\nconst specialFallbackSymbols = {\n\ttick: '√',\n\tinfo: 'i',\n\twarning: '‼',\n\tcross: '×',\n\tsquareSmall: '□',\n\tsquareSmallFilled: '■',\n\tcircle: '( )',\n\tcircleFilled: '(*)',\n\tcircleDotted: '( )',\n\tcircleDouble: '( )',\n\tcircleCircle: '(○)',\n\tcircleCross: '(×)',\n\tcirclePipe: '(│)',\n\tradioOn: '(*)',\n\tradioOff: '( )',\n\tcheckboxOn: '[×]',\n\tcheckboxOff: '[ ]',\n\tcheckboxCircleOn: '(×)',\n\tcheckboxCircleOff: '( )',\n\tpointer: '>',\n\ttriangleUpOutline: '∆',\n\ttriangleLeft: '◄',\n\ttriangleRight: '►',\n\tlozenge: '♦',\n\tlozengeOutline: '◊',\n\thamburger: '≡',\n\tsmiley: '☺',\n\tmustache: '┌─┐',\n\tstar: '✶',\n\tplay: '►',\n\tnodejs: '♦',\n\toneSeventh: '1/7',\n\toneNinth: '1/9',\n\toneTenth: '1/10',\n};\n\nexport const mainSymbols = {...common, ...specialMainSymbols};\nexport const fallbackSymbols = {...common, ...specialFallbackSymbols};\n\nconst shouldUseMain = isUnicodeSupported();\nconst figures = shouldUseMain ? mainSymbols : fallbackSymbols;\nexport default figures;\n\nconst replacements = Object.entries(specialMainSymbols);\n\n// On terminals which do not support Unicode symbols, substitute them to other symbols\nexport const replaceSymbols = (string, {useFallback = !shouldUseMain} = {}) => {\n\tif (useFallback) {\n\t\tfor (const [key, mainSymbol] of replacements) {\n\t\t\tstring = string.replaceAll(mainSymbol, fallbackSymbols[key]);\n\t\t}\n\t}\n\n\treturn string;\n};\n","import process from 'node:process';\n\nexport default function isUnicodeSupported() {\n\tconst {env} = process;\n\tconst {TERM, TERM_PROGRAM} = env;\n\n\tif (process.platform !== 'win32') {\n\t\treturn TERM !== 'linux'; // Linux console (kernel)\n\t}\n\n\treturn Boolean(env.WT_SESSION) // Windows Terminal\n\t\t|| Boolean(env.TERMINUS_SUBLIME) // Terminus (<0.2.27)\n\t\t|| env.ConEmuTask === '{cmd::Cmder}' // ConEmu and cmder\n\t\t|| TERM_PROGRAM === 'Terminus-Sublime'\n\t\t|| TERM_PROGRAM === 'vscode'\n\t\t|| TERM === 'xterm-256color'\n\t\t|| TERM === 'alacritty'\n\t\t|| TERM === 'rxvt-unicode'\n\t\t|| TERM === 'rxvt-unicode-256color'\n\t\t|| env.TERMINAL_EMULATOR === 'JetBrains-JediTerm';\n}\n","import tty from 'node:tty';\n\n// eslint-disable-next-line no-warning-comments\n// TODO: Use a better method when it's added to Node.js (https://github.com/nodejs/node/pull/40240)\n// Lots of optionals here to support Deno.\nconst hasColors = tty?.WriteStream?.prototype?.hasColors?.() ?? false;\n\nconst format = (open, close) => {\n\tif (!hasColors) {\n\t\treturn input => input;\n\t}\n\n\tconst openCode = `\\u001B[${open}m`;\n\tconst closeCode = `\\u001B[${close}m`;\n\n\treturn input => {\n\t\tconst string = input + ''; // eslint-disable-line no-implicit-coercion -- This is faster.\n\t\tlet index = string.indexOf(closeCode);\n\n\t\tif (index === -1) {\n\t\t\t// Note: Intentionally not using string interpolation for performance reasons.\n\t\t\treturn openCode + string + closeCode;\n\t\t}\n\n\t\t// Handle nested colors.\n\n\t\t// We could have done this, but it's too slow (as of Node.js 22).\n\t\t// return openCode + string.replaceAll(closeCode, openCode) + closeCode;\n\n\t\tlet result = openCode;\n\t\tlet lastIndex = 0;\n\n\t\twhile (index !== -1) {\n\t\t\tresult += string.slice(lastIndex, index) + openCode;\n\t\t\tlastIndex = index + closeCode.length;\n\t\t\tindex = string.indexOf(closeCode, lastIndex);\n\t\t}\n\n\t\tresult += string.slice(lastIndex) + closeCode;\n\n\t\treturn result;\n\t};\n};\n\nexport const reset = format(0, 0);\nexport const bold = format(1, 22);\nexport const dim = format(2, 22);\nexport const italic = format(3, 23);\nexport const underline = format(4, 24);\nexport const overline = format(53, 55);\nexport const inverse = format(7, 27);\nexport const hidden = format(8, 28);\nexport const strikethrough = format(9, 29);\n\nexport const black = format(30, 39);\nexport const red = format(31, 39);\nexport const green = format(32, 39);\nexport const yellow = format(33, 39);\nexport const blue = format(34, 39);\nexport const magenta = format(35, 39);\nexport const cyan = format(36, 39);\nexport const white = format(37, 39);\nexport const gray = format(90, 39);\n\nexport const bgBlack = format(40, 49);\nexport const bgRed = format(41, 49);\nexport const bgGreen = format(42, 49);\nexport const bgYellow = format(43, 49);\nexport const bgBlue = format(44, 49);\nexport const bgMagenta = format(45, 49);\nexport const bgCyan = format(46, 49);\nexport const bgWhite = format(47, 49);\nexport const bgGray = format(100, 49);\n\nexport const redBright = format(91, 39);\nexport const greenBright = format(92, 39);\nexport const yellowBright = format(93, 39);\nexport const blueBright = format(94, 39);\nexport const magentaBright = format(95, 39);\nexport const cyanBright = format(96, 39);\nexport const whiteBright = format(97, 39);\n\nexport const bgRedBright = format(101, 49);\nexport const bgGreenBright = format(102, 49);\nexport const bgYellowBright = format(103, 49);\nexport const bgBlueBright = format(104, 49);\nexport const bgMagentaBright = format(105, 49);\nexport const bgCyanBright = format(106, 49);\nexport const bgWhiteBright = format(107, 49);\n","import figures from 'figures';\nimport {\n\tgray,\n\tbold,\n\tredBright,\n\tyellowBright,\n} from 'yoctocolors';\n\n// Default when `verbose` is not a function\nexport const defaultVerboseFunction = ({\n\ttype,\n\tmessage,\n\ttimestamp,\n\tpiped,\n\tcommandId,\n\tresult: {failed = false} = {},\n\toptions: {reject = true},\n}) => {\n\tconst timestampString = serializeTimestamp(timestamp);\n\tconst icon = ICONS[type]({failed, reject, piped});\n\tconst color = COLORS[type]({reject});\n\treturn `${gray(`[${timestampString}]`)} ${gray(`[${commandId}]`)} ${color(icon)} ${color(message)}`;\n};\n\n// Prepending the timestamp allows debugging the slow paths of a subprocess\nconst serializeTimestamp = timestamp => `${padField(timestamp.getHours(), 2)}:${padField(timestamp.getMinutes(), 2)}:${padField(timestamp.getSeconds(), 2)}.${padField(timestamp.getMilliseconds(), 3)}`;\n\nconst padField = (field, padding) => String(field).padStart(padding, '0');\n\nconst getFinalIcon = ({failed, reject}) => {\n\tif (!failed) {\n\t\treturn figures.tick;\n\t}\n\n\treturn reject ? figures.cross : figures.warning;\n};\n\nconst ICONS = {\n\tcommand: ({piped}) => piped ? '|' : '$',\n\toutput: () => ' ',\n\tipc: () => '*',\n\terror: getFinalIcon,\n\tduration: getFinalIcon,\n};\n\nconst identity = string => string;\n\nconst COLORS = {\n\tcommand: () => bold,\n\toutput: () => identity,\n\tipc: () => identity,\n\terror: ({reject}) => reject ? redBright : yellowBright,\n\tduration: () => gray,\n};\n","import {getVerboseFunction} from './values.js';\n\n// Apply the `verbose` function on each line\nexport const applyVerboseOnLines = (printedLines, verboseInfo, fdNumber) => {\n\tconst verboseFunction = getVerboseFunction(verboseInfo, fdNumber);\n\treturn printedLines\n\t\t.map(({verboseLine, verboseObject}) => applyVerboseFunction(verboseLine, verboseObject, verboseFunction))\n\t\t.filter(printedLine => printedLine !== undefined)\n\t\t.map(printedLine => appendNewline(printedLine))\n\t\t.join('');\n};\n\nconst applyVerboseFunction = (verboseLine, verboseObject, verboseFunction) => {\n\tif (verboseFunction === undefined) {\n\t\treturn verboseLine;\n\t}\n\n\tconst printedLine = verboseFunction(verboseLine, verboseObject);\n\tif (typeof printedLine === 'string') {\n\t\treturn printedLine;\n\t}\n};\n\nconst appendNewline = printedLine => printedLine.endsWith('\\n')\n\t? printedLine\n\t: `${printedLine}\\n`;\n","import {writeFileSync} from 'node:fs';\nimport {inspect} from 'node:util';\nimport {escapeLines} from '../arguments/escape.js';\nimport {defaultVerboseFunction} from './default.js';\nimport {applyVerboseOnLines} from './custom.js';\n\n// Write synchronously to ensure lines are properly ordered and not interleaved with `stdout`\nexport const verboseLog = ({type, verboseMessage, fdNumber, verboseInfo, result}) => {\n\tconst verboseObject = getVerboseObject({type, result, verboseInfo});\n\tconst printedLines = getPrintedLines(verboseMessage, verboseObject);\n\tconst finalLines = applyVerboseOnLines(printedLines, verboseInfo, fdNumber);\n\twriteFileSync(STDERR_FD, finalLines);\n};\n\nconst getVerboseObject = ({\n\ttype,\n\tresult,\n\tverboseInfo: {escapedCommand, commandId, rawOptions: {piped = false, ...options}},\n}) => ({\n\ttype,\n\tescapedCommand,\n\tcommandId: `${commandId}`,\n\ttimestamp: new Date(),\n\tpiped,\n\tresult,\n\toptions,\n});\n\nconst getPrintedLines = (verboseMessage, verboseObject) => verboseMessage\n\t.split('\\n')\n\t.map(message => getPrintedLine({...verboseObject, message}));\n\nconst getPrintedLine = verboseObject => {\n\tconst verboseLine = defaultVerboseFunction(verboseObject);\n\treturn {verboseLine, verboseObject};\n};\n\n// Unless a `verbose` function is used, print all logs on `stderr`\nconst STDERR_FD = 2;\n\n// Serialize any type to a line string, for logging\nexport const serializeVerboseMessage = message => {\n\tconst messageString = typeof message === 'string' ? message : inspect(message);\n\tconst escapedMessage = escapeLines(messageString);\n\treturn escapedMessage.replaceAll('\\t', ' '.repeat(TAB_SIZE));\n};\n\n// Same as `util.inspect()`\nconst TAB_SIZE = 2;\n","import {isVerbose, VERBOSE_VALUES, isVerboseFunction} from './values.js';\n\n// Information computed before spawning, used by the `verbose` option\nexport const getVerboseInfo = (verbose, escapedCommand, rawOptions) => {\n\tvalidateVerbose(verbose);\n\tconst commandId = getCommandId(verbose);\n\treturn {\n\t\tverbose,\n\t\tescapedCommand,\n\t\tcommandId,\n\t\trawOptions,\n\t};\n};\n\nconst getCommandId = verbose => isVerbose({verbose}) ? COMMAND_ID++ : undefined;\n\n// Prepending the `pid` is useful when multiple commands print their output at the same time.\n// However, we cannot use the real PID since this is not available with `child_process.spawnSync()`.\n// Also, we cannot use the real PID if we want to print it before `child_process.spawn()` is run.\n// As a pro, it is shorter than a normal PID and never re-uses the same id.\n// As a con, it cannot be used to send signals.\nlet COMMAND_ID = 0n;\n\nconst validateVerbose = verbose => {\n\tfor (const fdVerbose of verbose) {\n\t\tif (fdVerbose === false) {\n\t\t\tthrow new TypeError('The \"verbose: false\" option was renamed to \"verbose: \\'none\\'\".');\n\t\t}\n\n\t\tif (fdVerbose === true) {\n\t\t\tthrow new TypeError('The \"verbose: true\" option was renamed to \"verbose: \\'short\\'\".');\n\t\t}\n\n\t\tif (!VERBOSE_VALUES.includes(fdVerbose) && !isVerboseFunction(fdVerbose)) {\n\t\t\tconst allowedValues = VERBOSE_VALUES.map(allowedValue => `'${allowedValue}'`).join(', ');\n\t\t\tthrow new TypeError(`The \"verbose\" option must not be ${fdVerbose}. Allowed values are: ${allowedValues} or a function.`);\n\t\t}\n\t}\n};\n","import {hrtime} from 'node:process';\n\n// Start counting time before spawning the subprocess\nexport const getStartTime = () => hrtime.bigint();\n\n// Compute duration after the subprocess ended.\n// Printed by the `verbose` option.\nexport const getDurationMs = startTime => Number(hrtime.bigint() - startTime) / 1e6;\n","import {logCommand} from '../verbose/start.js';\nimport {getVerboseInfo} from '../verbose/info.js';\nimport {getStartTime} from '../return/duration.js';\nimport {joinCommand} from './escape.js';\nimport {normalizeFdSpecificOption} from './specific.js';\n\n// Compute `result.command`, `result.escapedCommand` and `verbose`-related information\nexport const handleCommand = (filePath, rawArguments, rawOptions) => {\n\tconst startTime = getStartTime();\n\tconst {command, escapedCommand} = joinCommand(filePath, rawArguments);\n\tconst verbose = normalizeFdSpecificOption(rawOptions, 'verbose');\n\tconst verboseInfo = getVerboseInfo(verbose, escapedCommand, {...rawOptions});\n\tlogCommand(escapedCommand, verboseInfo);\n\treturn {\n\t\tcommand,\n\t\tescapedCommand,\n\t\tstartTime,\n\t\tverboseInfo,\n\t};\n};\n","import {isVerbose} from './values.js';\nimport {verboseLog} from './log.js';\n\n// When `verbose` is `short|full|custom`, print each command\nexport const logCommand = (escapedCommand, verboseInfo) => {\n\tif (!isVerbose(verboseInfo)) {\n\t\treturn;\n\t}\n\n\tverboseLog({\n\t\ttype: 'command',\n\t\tverboseMessage: escapedCommand,\n\t\tverboseInfo,\n\t});\n};\n","module.exports = isexe\nisexe.sync = sync\n\nvar fs = require('fs')\n\nfunction checkPathExt (path, options) {\n var pathext = options.pathExt !== undefined ?\n options.pathExt : process.env.PATHEXT\n\n if (!pathext) {\n return true\n }\n\n pathext = pathext.split(';')\n if (pathext.indexOf('') !== -1) {\n return true\n }\n for (var i = 0; i < pathext.length; i++) {\n var p = pathext[i].toLowerCase()\n if (p && path.substr(-p.length).toLowerCase() === p) {\n return true\n }\n }\n return false\n}\n\nfunction checkStat (stat, path, options) {\n if (!stat.isSymbolicLink() && !stat.isFile()) {\n return false\n }\n return checkPathExt(path, options)\n}\n\nfunction isexe (path, options, cb) {\n fs.stat(path, function (er, stat) {\n cb(er, er ? false : checkStat(stat, path, options))\n })\n}\n\nfunction sync (path, options) {\n return checkStat(fs.statSync(path), path, options)\n}\n","module.exports = isexe\nisexe.sync = sync\n\nvar fs = require('fs')\n\nfunction isexe (path, options, cb) {\n fs.stat(path, function (er, stat) {\n cb(er, er ? false : checkStat(stat, options))\n })\n}\n\nfunction sync (path, options) {\n return checkStat(fs.statSync(path), options)\n}\n\nfunction checkStat (stat, options) {\n return stat.isFile() && checkMode(stat, options)\n}\n\nfunction checkMode (stat, options) {\n var mod = stat.mode\n var uid = stat.uid\n var gid = stat.gid\n\n var myUid = options.uid !== undefined ?\n options.uid : process.getuid && process.getuid()\n var myGid = options.gid !== undefined ?\n options.gid : process.getgid && process.getgid()\n\n var u = parseInt('100', 8)\n var g = parseInt('010', 8)\n var o = parseInt('001', 8)\n var ug = u | g\n\n var ret = (mod & o) ||\n (mod & g) && gid === myGid ||\n (mod & u) && uid === myUid ||\n (mod & ug) && myUid === 0\n\n return ret\n}\n","const isWindows = process.platform === 'win32' ||\n process.env.OSTYPE === 'cygwin' ||\n process.env.OSTYPE === 'msys'\n\nconst path = require('path')\nconst COLON = isWindows ? ';' : ':'\nconst isexe = require('isexe')\n\nconst getNotFoundError = (cmd) =>\n Object.assign(new Error(`not found: ${cmd}`), { code: 'ENOENT' })\n\nconst getPathInfo = (cmd, opt) => {\n const colon = opt.colon || COLON\n\n // If it has a slash, then we don't bother searching the pathenv.\n // just check the file itself, and that's it.\n const pathEnv = cmd.match(/\\//) || isWindows && cmd.match(/\\\\/) ? ['']\n : (\n [\n // windows always checks the cwd first\n ...(isWindows ? [process.cwd()] : []),\n ...(opt.path || process.env.PATH ||\n /* istanbul ignore next: very unusual */ '').split(colon),\n ]\n )\n const pathExtExe = isWindows\n ? opt.pathExt || process.env.PATHEXT || '.EXE;.CMD;.BAT;.COM'\n : ''\n const pathExt = isWindows ? pathExtExe.split(colon) : ['']\n\n if (isWindows) {\n if (cmd.indexOf('.') !== -1 && pathExt[0] !== '')\n pathExt.unshift('')\n }\n\n return {\n pathEnv,\n pathExt,\n pathExtExe,\n }\n}\n\nconst which = (cmd, opt, cb) => {\n if (typeof opt === 'function') {\n cb = opt\n opt = {}\n }\n if (!opt)\n opt = {}\n\n const { pathEnv, pathExt, pathExtExe } = getPathInfo(cmd, opt)\n const found = []\n\n const step = i => new Promise((resolve, reject) => {\n if (i === pathEnv.length)\n return opt.all && found.length ? resolve(found)\n : reject(getNotFoundError(cmd))\n\n const ppRaw = pathEnv[i]\n const pathPart = /^\".*\"$/.test(ppRaw) ? ppRaw.slice(1, -1) : ppRaw\n\n const pCmd = path.join(pathPart, cmd)\n const p = !pathPart && /^\\.[\\\\\\/]/.test(cmd) ? cmd.slice(0, 2) + pCmd\n : pCmd\n\n resolve(subStep(p, i, 0))\n })\n\n const subStep = (p, i, ii) => new Promise((resolve, reject) => {\n if (ii === pathExt.length)\n return resolve(step(i + 1))\n const ext = pathExt[ii]\n isexe(p + ext, { pathExt: pathExtExe }, (er, is) => {\n if (!er && is) {\n if (opt.all)\n found.push(p + ext)\n else\n return resolve(p + ext)\n }\n return resolve(subStep(p, i, ii + 1))\n })\n })\n\n return cb ? step(0).then(res => cb(null, res), cb) : step(0)\n}\n\nconst whichSync = (cmd, opt) => {\n opt = opt || {}\n\n const { pathEnv, pathExt, pathExtExe } = getPathInfo(cmd, opt)\n const found = []\n\n for (let i = 0; i < pathEnv.length; i ++) {\n const ppRaw = pathEnv[i]\n const pathPart = /^\".*\"$/.test(ppRaw) ? ppRaw.slice(1, -1) : ppRaw\n\n const pCmd = path.join(pathPart, cmd)\n const p = !pathPart && /^\\.[\\\\\\/]/.test(cmd) ? cmd.slice(0, 2) + pCmd\n : pCmd\n\n for (let j = 0; j < pathExt.length; j ++) {\n const cur = p + pathExt[j]\n try {\n const is = isexe.sync(cur, { pathExt: pathExtExe })\n if (is) {\n if (opt.all)\n found.push(cur)\n else\n return cur\n }\n } catch (ex) {}\n }\n }\n\n if (opt.all && found.length)\n return found\n\n if (opt.nothrow)\n return null\n\n throw getNotFoundError(cmd)\n}\n\nmodule.exports = which\nwhich.sync = whichSync\n","'use strict';\n\nconst pathKey = (options = {}) => {\n\tconst environment = options.env || process.env;\n\tconst platform = options.platform || process.platform;\n\n\tif (platform !== 'win32') {\n\t\treturn 'PATH';\n\t}\n\n\treturn Object.keys(environment).reverse().find(key => key.toUpperCase() === 'PATH') || 'Path';\n};\n\nmodule.exports = pathKey;\n// TODO: Remove this for the next major release\nmodule.exports.default = pathKey;\n","'use strict';\n\n// See http://www.robvanderwoude.com/escapechars.php\nconst metaCharsRegExp = /([()\\][%!^\"`<>&|;, *?])/g;\n\nfunction escapeCommand(arg) {\n // Escape meta chars\n arg = arg.replace(metaCharsRegExp, '^$1');\n\n return arg;\n}\n\nfunction escapeArgument(arg, doubleEscapeMetaChars) {\n // Convert to string\n arg = `${arg}`;\n\n // Algorithm below is based on https://qntm.org/cmd\n\n // Sequence of backslashes followed by a double quote:\n // double up all the backslashes and escape the double quote\n arg = arg.replace(/(\\\\*)\"/g, '$1$1\\\\\"');\n\n // Sequence of backslashes followed by the end of the string\n // (which will become a double quote later):\n // double up all the backslashes\n arg = arg.replace(/(\\\\*)$/, '$1$1');\n\n // All other backslashes occur literally\n\n // Quote the whole thing:\n arg = `\"${arg}\"`;\n\n // Escape meta chars\n arg = arg.replace(metaCharsRegExp, '^$1');\n\n // Double escape meta chars if necessary\n if (doubleEscapeMetaChars) {\n arg = arg.replace(metaCharsRegExp, '^$1');\n }\n\n return arg;\n}\n\nmodule.exports.command = escapeCommand;\nmodule.exports.argument = escapeArgument;\n","'use strict';\nconst shebangRegex = require('shebang-regex');\n\nmodule.exports = (string = '') => {\n\tconst match = string.match(shebangRegex);\n\n\tif (!match) {\n\t\treturn null;\n\t}\n\n\tconst [path, argument] = match[0].replace(/#! ?/, '').split(' ');\n\tconst binary = path.split('/').pop();\n\n\tif (binary === 'env') {\n\t\treturn argument;\n\t}\n\n\treturn argument ? `${binary} ${argument}` : binary;\n};\n","'use strict';\nmodule.exports = /^#!(.*)/;\n","'use strict';\n\nconst fs = require('fs');\nconst shebangCommand = require('shebang-command');\n\nfunction readShebang(command) {\n // Read the first 150 bytes from the file\n const size = 150;\n const buffer = Buffer.alloc(size);\n\n let fd;\n\n try {\n fd = fs.openSync(command, 'r');\n fs.readSync(fd, buffer, 0, size, 0);\n fs.closeSync(fd);\n } catch (e) { /* Empty */ }\n\n // Attempt to extract shebang (null is returned if not a shebang)\n return shebangCommand(buffer.toString());\n}\n\nmodule.exports = readShebang;\n","'use strict';\n\nconst path = require('path');\nconst resolveCommand = require('./util/resolveCommand');\nconst escape = require('./util/escape');\nconst readShebang = require('./util/readShebang');\n\nconst isWin = process.platform === 'win32';\nconst isExecutableRegExp = /\\.(?:com|exe)$/i;\nconst isCmdShimRegExp = /node_modules[\\\\/].bin[\\\\/][^\\\\/]+\\.cmd$/i;\n\nfunction detectShebang(parsed) {\n parsed.file = resolveCommand(parsed);\n\n const shebang = parsed.file && readShebang(parsed.file);\n\n if (shebang) {\n parsed.args.unshift(parsed.file);\n parsed.command = shebang;\n\n return resolveCommand(parsed);\n }\n\n return parsed.file;\n}\n\nfunction parseNonShell(parsed) {\n if (!isWin) {\n return parsed;\n }\n\n // Detect & add support for shebangs\n const commandFile = detectShebang(parsed);\n\n // We don't need a shell if the command filename is an executable\n const needsShell = !isExecutableRegExp.test(commandFile);\n\n // If a shell is required, use cmd.exe and take care of escaping everything correctly\n // Note that `forceShell` is an hidden option used only in tests\n if (parsed.options.forceShell || needsShell) {\n // Need to double escape meta chars if the command is a cmd-shim located in `node_modules/.bin/`\n // The cmd-shim simply calls execute the package bin file with NodeJS, proxying any argument\n // Because the escape of metachars with ^ gets interpreted when the cmd.exe is first called,\n // we need to double escape them\n const needsDoubleEscapeMetaChars = isCmdShimRegExp.test(commandFile);\n\n // Normalize posix paths into OS compatible paths (e.g.: foo/bar -> foo\\bar)\n // This is necessary otherwise it will always fail with ENOENT in those cases\n parsed.command = path.normalize(parsed.command);\n\n // Escape command & arguments\n parsed.command = escape.command(parsed.command);\n parsed.args = parsed.args.map((arg) => escape.argument(arg, needsDoubleEscapeMetaChars));\n\n const shellCommand = [parsed.command].concat(parsed.args).join(' ');\n\n parsed.args = ['/d', '/s', '/c', `\"${shellCommand}\"`];\n parsed.command = process.env.comspec || 'cmd.exe';\n parsed.options.windowsVerbatimArguments = true; // Tell node's spawn that the arguments are already escaped\n }\n\n return parsed;\n}\n\nfunction parse(command, args, options) {\n // Normalize arguments, similar to nodejs\n if (args && !Array.isArray(args)) {\n options = args;\n args = null;\n }\n\n args = args ? args.slice(0) : []; // Clone array to avoid changing the original\n options = Object.assign({}, options); // Clone object to avoid changing the original\n\n // Build our parsed object\n const parsed = {\n command,\n args,\n options,\n file: undefined,\n original: {\n command,\n args,\n },\n };\n\n // Delegate further parsing to shell or non-shell\n return options.shell ? parsed : parseNonShell(parsed);\n}\n\nmodule.exports = parse;\n","import process from 'node:process';\nimport path from 'node:path';\nimport pathKey from 'path-key';\nimport {toPath, traversePathUp} from 'unicorn-magic';\n\nexport const npmRunPath = ({\n\tcwd = process.cwd(),\n\tpath: pathOption = process.env[pathKey()],\n\tpreferLocal = true,\n\texecPath = process.execPath,\n\taddExecPath = true,\n} = {}) => {\n\tconst cwdPath = path.resolve(toPath(cwd));\n\tconst result = [];\n\tconst pathParts = pathOption.split(path.delimiter);\n\n\tif (preferLocal) {\n\t\tapplyPreferLocal(result, pathParts, cwdPath);\n\t}\n\n\tif (addExecPath) {\n\t\tapplyExecPath(result, pathParts, execPath, cwdPath);\n\t}\n\n\treturn pathOption === '' || pathOption === path.delimiter\n\t\t? `${result.join(path.delimiter)}${pathOption}`\n\t\t: [...result, pathOption].join(path.delimiter);\n};\n\nconst applyPreferLocal = (result, pathParts, cwdPath) => {\n\tfor (const directory of traversePathUp(cwdPath)) {\n\t\tconst pathPart = path.join(directory, 'node_modules/.bin');\n\t\tif (!pathParts.includes(pathPart)) {\n\t\t\tresult.push(pathPart);\n\t\t}\n\t}\n};\n\n// Ensure the running `node` binary is used\nconst applyExecPath = (result, pathParts, execPath, cwdPath) => {\n\tconst pathPart = path.resolve(cwdPath, toPath(execPath), '..');\n\tif (!pathParts.includes(pathPart)) {\n\t\tresult.push(pathPart);\n\t}\n};\n\nexport const npmRunPathEnv = ({env = process.env, ...options} = {}) => {\n\tenv = {...env};\n\n\tconst pathName = pathKey({env});\n\toptions.path = env[pathName];\n\tenv[pathName] = npmRunPath(options);\n\n\treturn env;\n};\n","// When the subprocess fails, this is the error instance being returned.\n// If another error instance is being thrown, it is kept as `error.cause`.\nexport const getFinalError = (originalError, message, isSync) => {\n\tconst ErrorClass = isSync ? ExecaSyncError : ExecaError;\n\tconst options = originalError instanceof DiscardedError ? {} : {cause: originalError};\n\treturn new ErrorClass(message, options);\n};\n\n// Indicates that the error is used only to interrupt control flow, but not in the return value\nexport class DiscardedError extends Error {}\n\n// Proper way to set `error.name`: it should be inherited and non-enumerable\nconst setErrorName = (ErrorClass, value) => {\n\tObject.defineProperty(ErrorClass.prototype, 'name', {\n\t\tvalue,\n\t\twritable: true,\n\t\tenumerable: false,\n\t\tconfigurable: true,\n\t});\n\tObject.defineProperty(ErrorClass.prototype, execaErrorSymbol, {\n\t\tvalue: true,\n\t\twritable: false,\n\t\tenumerable: false,\n\t\tconfigurable: false,\n\t});\n};\n\n// Unlike `instanceof`, this works across realms\nexport const isExecaError = error => isErrorInstance(error) && execaErrorSymbol in error;\n\nconst execaErrorSymbol = Symbol('isExecaError');\n\nexport const isErrorInstance = value => Object.prototype.toString.call(value) === '[object Error]';\n\n// We use two different Error classes for async/sync methods since they have slightly different shape and types\nexport class ExecaError extends Error {}\nsetErrorName(ExecaError, ExecaError.name);\n\nexport class ExecaSyncError extends Error {}\nsetErrorName(ExecaSyncError, ExecaSyncError.name);\n","\nexport const getRealtimeSignals=()=>{\nconst length=SIGRTMAX-SIGRTMIN+1;\nreturn Array.from({length},getRealtimeSignal)\n};\n\nconst getRealtimeSignal=(value,index)=>({\nname:`SIGRT${index+1}`,\nnumber:SIGRTMIN+index,\naction:\"terminate\",\ndescription:\"Application-specific signal (realtime)\",\nstandard:\"posix\"\n});\n\nconst SIGRTMIN=34;\nexport const SIGRTMAX=64;","\n\nexport const SIGNALS=[\n{\nname:\"SIGHUP\",\nnumber:1,\naction:\"terminate\",\ndescription:\"Terminal closed\",\nstandard:\"posix\"\n},\n{\nname:\"SIGINT\",\nnumber:2,\naction:\"terminate\",\ndescription:\"User interruption with CTRL-C\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGQUIT\",\nnumber:3,\naction:\"core\",\ndescription:\"User interruption with CTRL-\\\\\",\nstandard:\"posix\"\n},\n{\nname:\"SIGILL\",\nnumber:4,\naction:\"core\",\ndescription:\"Invalid machine instruction\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGTRAP\",\nnumber:5,\naction:\"core\",\ndescription:\"Debugger breakpoint\",\nstandard:\"posix\"\n},\n{\nname:\"SIGABRT\",\nnumber:6,\naction:\"core\",\ndescription:\"Aborted\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGIOT\",\nnumber:6,\naction:\"core\",\ndescription:\"Aborted\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGBUS\",\nnumber:7,\naction:\"core\",\ndescription:\n\"Bus error due to misaligned, non-existing address or paging error\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGEMT\",\nnumber:7,\naction:\"terminate\",\ndescription:\"Command should be emulated but is not implemented\",\nstandard:\"other\"\n},\n{\nname:\"SIGFPE\",\nnumber:8,\naction:\"core\",\ndescription:\"Floating point arithmetic error\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGKILL\",\nnumber:9,\naction:\"terminate\",\ndescription:\"Forced termination\",\nstandard:\"posix\",\nforced:true\n},\n{\nname:\"SIGUSR1\",\nnumber:10,\naction:\"terminate\",\ndescription:\"Application-specific signal\",\nstandard:\"posix\"\n},\n{\nname:\"SIGSEGV\",\nnumber:11,\naction:\"core\",\ndescription:\"Segmentation fault\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGUSR2\",\nnumber:12,\naction:\"terminate\",\ndescription:\"Application-specific signal\",\nstandard:\"posix\"\n},\n{\nname:\"SIGPIPE\",\nnumber:13,\naction:\"terminate\",\ndescription:\"Broken pipe or socket\",\nstandard:\"posix\"\n},\n{\nname:\"SIGALRM\",\nnumber:14,\naction:\"terminate\",\ndescription:\"Timeout or timer\",\nstandard:\"posix\"\n},\n{\nname:\"SIGTERM\",\nnumber:15,\naction:\"terminate\",\ndescription:\"Termination\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGSTKFLT\",\nnumber:16,\naction:\"terminate\",\ndescription:\"Stack is empty or overflowed\",\nstandard:\"other\"\n},\n{\nname:\"SIGCHLD\",\nnumber:17,\naction:\"ignore\",\ndescription:\"Child process terminated, paused or unpaused\",\nstandard:\"posix\"\n},\n{\nname:\"SIGCLD\",\nnumber:17,\naction:\"ignore\",\ndescription:\"Child process terminated, paused or unpaused\",\nstandard:\"other\"\n},\n{\nname:\"SIGCONT\",\nnumber:18,\naction:\"unpause\",\ndescription:\"Unpaused\",\nstandard:\"posix\",\nforced:true\n},\n{\nname:\"SIGSTOP\",\nnumber:19,\naction:\"pause\",\ndescription:\"Paused\",\nstandard:\"posix\",\nforced:true\n},\n{\nname:\"SIGTSTP\",\nnumber:20,\naction:\"pause\",\ndescription:\"Paused using CTRL-Z or \\\"suspend\\\"\",\nstandard:\"posix\"\n},\n{\nname:\"SIGTTIN\",\nnumber:21,\naction:\"pause\",\ndescription:\"Background process cannot read terminal input\",\nstandard:\"posix\"\n},\n{\nname:\"SIGBREAK\",\nnumber:21,\naction:\"terminate\",\ndescription:\"User interruption with CTRL-BREAK\",\nstandard:\"other\"\n},\n{\nname:\"SIGTTOU\",\nnumber:22,\naction:\"pause\",\ndescription:\"Background process cannot write to terminal output\",\nstandard:\"posix\"\n},\n{\nname:\"SIGURG\",\nnumber:23,\naction:\"ignore\",\ndescription:\"Socket received out-of-band data\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGXCPU\",\nnumber:24,\naction:\"core\",\ndescription:\"Process timed out\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGXFSZ\",\nnumber:25,\naction:\"core\",\ndescription:\"File too big\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGVTALRM\",\nnumber:26,\naction:\"terminate\",\ndescription:\"Timeout or timer\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGPROF\",\nnumber:27,\naction:\"terminate\",\ndescription:\"Timeout or timer\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGWINCH\",\nnumber:28,\naction:\"ignore\",\ndescription:\"Terminal window size changed\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGIO\",\nnumber:29,\naction:\"terminate\",\ndescription:\"I/O is available\",\nstandard:\"other\"\n},\n{\nname:\"SIGPOLL\",\nnumber:29,\naction:\"terminate\",\ndescription:\"Watched event\",\nstandard:\"other\"\n},\n{\nname:\"SIGINFO\",\nnumber:29,\naction:\"ignore\",\ndescription:\"Request for process information\",\nstandard:\"other\"\n},\n{\nname:\"SIGPWR\",\nnumber:30,\naction:\"terminate\",\ndescription:\"Device running out of power\",\nstandard:\"systemv\"\n},\n{\nname:\"SIGSYS\",\nnumber:31,\naction:\"core\",\ndescription:\"Invalid system call\",\nstandard:\"other\"\n},\n{\nname:\"SIGUNUSED\",\nnumber:31,\naction:\"terminate\",\ndescription:\"Invalid system call\",\nstandard:\"other\"\n}];","import{constants}from\"node:os\";\n\nimport{SIGNALS}from\"./core.js\";\nimport{getRealtimeSignals}from\"./realtime.js\";\n\n\n\nexport const getSignals=()=>{\nconst realtimeSignals=getRealtimeSignals();\nconst signals=[...SIGNALS,...realtimeSignals].map(normalizeSignal);\nreturn signals\n};\n\n\n\n\n\n\n\nconst normalizeSignal=({\nname,\nnumber:defaultNumber,\ndescription,\naction,\nforced=false,\nstandard\n})=>{\nconst{\nsignals:{[name]:constantSignal}\n}=constants;\nconst supported=constantSignal!==undefined;\nconst number=supported?constantSignal:defaultNumber;\nreturn{name,number,description,supported,action,forced,standard}\n};","import{constants}from\"node:os\";\n\nimport{SIGRTMAX}from\"./realtime.js\";\nimport{getSignals}from\"./signals.js\";\n\n\n\nconst getSignalsByName=()=>{\nconst signals=getSignals();\nreturn Object.fromEntries(signals.map(getSignalByName))\n};\n\nconst getSignalByName=({\nname,\nnumber,\ndescription,\nsupported,\naction,\nforced,\nstandard\n})=>[name,{name,number,description,supported,action,forced,standard}];\n\nexport const signalsByName=getSignalsByName();\n\n\n\n\nconst getSignalsByNumber=()=>{\nconst signals=getSignals();\nconst length=SIGRTMAX+1;\nconst signalsA=Array.from({length},(value,number)=>\ngetSignalByNumber(number,signals)\n);\nreturn Object.assign({},...signalsA)\n};\n\nconst getSignalByNumber=(number,signals)=>{\nconst signal=findSignalByNumber(number,signals);\n\nif(signal===undefined){\nreturn{}\n}\n\nconst{name,description,supported,action,forced,standard}=signal;\nreturn{\n[number]:{\nname,\nnumber,\ndescription,\nsupported,\naction,\nforced,\nstandard\n}\n}\n};\n\n\n\nconst findSignalByNumber=(number,signals)=>{\nconst signal=signals.find(({name})=>constants.signals[name]===number);\n\nif(signal!==undefined){\nreturn signal\n}\n\nreturn signals.find((signalA)=>signalA.number===number)\n};\n\nexport const signalsByNumber=getSignalsByNumber();","import {constants} from 'node:os';\nimport {signalsByName} from 'human-signals';\n\n// Normalize signals for comparison purpose.\n// Also validate the signal exists.\nexport const normalizeKillSignal = killSignal => {\n\tconst optionName = 'option `killSignal`';\n\tif (killSignal === 0) {\n\t\tthrow new TypeError(`Invalid ${optionName}: 0 cannot be used.`);\n\t}\n\n\treturn normalizeSignal(killSignal, optionName);\n};\n\nexport const normalizeSignalArgument = signal => signal === 0\n\t? signal\n\t: normalizeSignal(signal, '`subprocess.kill()`\\'s argument');\n\nconst normalizeSignal = (signalNameOrInteger, optionName) => {\n\tif (Number.isInteger(signalNameOrInteger)) {\n\t\treturn normalizeSignalInteger(signalNameOrInteger, optionName);\n\t}\n\n\tif (typeof signalNameOrInteger === 'string') {\n\t\treturn normalizeSignalName(signalNameOrInteger, optionName);\n\t}\n\n\tthrow new TypeError(`Invalid ${optionName} ${String(signalNameOrInteger)}: it must be a string or an integer.\\n${getAvailableSignals()}`);\n};\n\nconst normalizeSignalInteger = (signalInteger, optionName) => {\n\tif (signalsIntegerToName.has(signalInteger)) {\n\t\treturn signalsIntegerToName.get(signalInteger);\n\t}\n\n\tthrow new TypeError(`Invalid ${optionName} ${signalInteger}: this signal integer does not exist.\\n${getAvailableSignals()}`);\n};\n\nconst getSignalsIntegerToName = () => new Map(Object.entries(constants.signals)\n\t.reverse()\n\t.map(([signalName, signalInteger]) => [signalInteger, signalName]));\n\nconst signalsIntegerToName = getSignalsIntegerToName();\n\nconst normalizeSignalName = (signalName, optionName) => {\n\tif (signalName in constants.signals) {\n\t\treturn signalName;\n\t}\n\n\tif (signalName.toUpperCase() in constants.signals) {\n\t\tthrow new TypeError(`Invalid ${optionName} '${signalName}': please rename it to '${signalName.toUpperCase()}'.`);\n\t}\n\n\tthrow new TypeError(`Invalid ${optionName} '${signalName}': this signal name does not exist.\\n${getAvailableSignals()}`);\n};\n\nconst getAvailableSignals = () => `Available signal names: ${getAvailableSignalNames()}.\nAvailable signal numbers: ${getAvailableSignalIntegers()}.`;\n\nconst getAvailableSignalNames = () => Object.keys(constants.signals)\n\t.sort()\n\t.map(signalName => `'${signalName}'`)\n\t.join(', ');\n\nconst getAvailableSignalIntegers = () => [...new Set(Object.values(constants.signals)\n\t.sort((signalInteger, signalIntegerTwo) => signalInteger - signalIntegerTwo))]\n\t.join(', ');\n\n// Human-friendly description of a signal\nexport const getSignalDescription = signal => signalsByName[signal].description;\n","import {setTimeout} from 'node:timers/promises';\nimport {isErrorInstance} from '../return/final-error.js';\nimport {normalizeSignalArgument} from './signal.js';\n\n// Normalize the `forceKillAfterDelay` option\nexport const normalizeForceKillAfterDelay = forceKillAfterDelay => {\n\tif (forceKillAfterDelay === false) {\n\t\treturn forceKillAfterDelay;\n\t}\n\n\tif (forceKillAfterDelay === true) {\n\t\treturn DEFAULT_FORCE_KILL_TIMEOUT;\n\t}\n\n\tif (!Number.isFinite(forceKillAfterDelay) || forceKillAfterDelay < 0) {\n\t\tthrow new TypeError(`Expected the \\`forceKillAfterDelay\\` option to be a non-negative integer, got \\`${forceKillAfterDelay}\\` (${typeof forceKillAfterDelay})`);\n\t}\n\n\treturn forceKillAfterDelay;\n};\n\nconst DEFAULT_FORCE_KILL_TIMEOUT = 1000 * 5;\n\n// Monkey-patches `subprocess.kill()` to add `forceKillAfterDelay` behavior and `.kill(error)`\nexport const subprocessKill = (\n\t{kill, options: {forceKillAfterDelay, killSignal}, onInternalError, context, controller},\n\tsignalOrError,\n\terrorArgument,\n) => {\n\tconst {signal, error} = parseKillArguments(signalOrError, errorArgument, killSignal);\n\temitKillError(error, onInternalError);\n\tconst killResult = kill(signal);\n\tsetKillTimeout({\n\t\tkill,\n\t\tsignal,\n\t\tforceKillAfterDelay,\n\t\tkillSignal,\n\t\tkillResult,\n\t\tcontext,\n\t\tcontroller,\n\t});\n\treturn killResult;\n};\n\nconst parseKillArguments = (signalOrError, errorArgument, killSignal) => {\n\tconst [signal = killSignal, error] = isErrorInstance(signalOrError)\n\t\t? [undefined, signalOrError]\n\t\t: [signalOrError, errorArgument];\n\n\tif (typeof signal !== 'string' && !Number.isInteger(signal)) {\n\t\tthrow new TypeError(`The first argument must be an error instance or a signal name string/integer: ${String(signal)}`);\n\t}\n\n\tif (error !== undefined && !isErrorInstance(error)) {\n\t\tthrow new TypeError(`The second argument is optional. If specified, it must be an error instance: ${error}`);\n\t}\n\n\treturn {signal: normalizeSignalArgument(signal), error};\n};\n\n// Fails right away when calling `subprocess.kill(error)`.\n// Does not wait for actual signal termination.\n// Uses a deferred promise instead of the `error` event on the subprocess, as this is less intrusive.\nconst emitKillError = (error, onInternalError) => {\n\tif (error !== undefined) {\n\t\tonInternalError.reject(error);\n\t}\n};\n\nconst setKillTimeout = async ({kill, signal, forceKillAfterDelay, killSignal, killResult, context, controller}) => {\n\tif (signal === killSignal && killResult) {\n\t\tkillOnTimeout({\n\t\t\tkill,\n\t\t\tforceKillAfterDelay,\n\t\t\tcontext,\n\t\t\tcontrollerSignal: controller.signal,\n\t\t});\n\t}\n};\n\n// Forcefully terminate a subprocess after a timeout\nexport const killOnTimeout = async ({kill, forceKillAfterDelay, context, controllerSignal}) => {\n\tif (forceKillAfterDelay === false) {\n\t\treturn;\n\t}\n\n\ttry {\n\t\tawait setTimeout(forceKillAfterDelay, undefined, {signal: controllerSignal});\n\t\tif (kill('SIGKILL')) {\n\t\t\tcontext.isForcefullyTerminated ??= true;\n\t\t}\n\t} catch {}\n};\n","import {once} from 'node:events';\n\n// Combines `util.aborted()` and `events.addAbortListener()`: promise-based and cleaned up with a stop signal\nexport const onAbortedSignal = async (mainSignal, stopSignal) => {\n\tif (!mainSignal.aborted) {\n\t\tawait once(mainSignal, 'abort', {signal: stopSignal});\n\t}\n};\n","import {onAbortedSignal} from '../utils/abort-signal.js';\n\n// Validate the `cancelSignal` option\nexport const validateCancelSignal = ({cancelSignal}) => {\n\tif (cancelSignal !== undefined && Object.prototype.toString.call(cancelSignal) !== '[object AbortSignal]') {\n\t\tthrow new Error(`The \\`cancelSignal\\` option must be an AbortSignal: ${String(cancelSignal)}`);\n\t}\n};\n\n// Terminate the subprocess when aborting the `cancelSignal` option and `gracefulSignal` is `false`\nexport const throwOnCancel = ({subprocess, cancelSignal, gracefulCancel, context, controller}) => cancelSignal === undefined || gracefulCancel\n\t? []\n\t: [terminateOnCancel(subprocess, cancelSignal, context, controller)];\n\nconst terminateOnCancel = async (subprocess, cancelSignal, context, {signal}) => {\n\tawait onAbortedSignal(cancelSignal, signal);\n\tcontext.terminationReason ??= 'cancel';\n\tsubprocess.kill();\n\tthrow cancelSignal.reason;\n};\n","// Validate the IPC channel is connected before receiving/sending messages\nexport const validateIpcMethod = ({methodName, isSubprocess, ipc, isConnected}) => {\n\tvalidateIpcOption(methodName, isSubprocess, ipc);\n\tvalidateConnection(methodName, isSubprocess, isConnected);\n};\n\n// Better error message when forgetting to set `ipc: true` and using the IPC methods\nconst validateIpcOption = (methodName, isSubprocess, ipc) => {\n\tif (!ipc) {\n\t\tthrow new Error(`${getMethodName(methodName, isSubprocess)} can only be used if the \\`ipc\\` option is \\`true\\`.`);\n\t}\n};\n\n// Better error message when one process does not send/receive messages once the other process has disconnected.\n// This also makes it clear that any buffered messages are lost once either process has disconnected.\n// Also when aborting `cancelSignal` after disconnecting the IPC.\nexport const validateConnection = (methodName, isSubprocess, isConnected) => {\n\tif (!isConnected) {\n\t\tthrow new Error(`${getMethodName(methodName, isSubprocess)} cannot be used: the ${getOtherProcessName(isSubprocess)} has already exited or disconnected.`);\n\t}\n};\n\n// When `getOneMessage()` could not complete due to an early disconnection\nexport const throwOnEarlyDisconnect = isSubprocess => {\n\tthrow new Error(`${getMethodName('getOneMessage', isSubprocess)} could not complete: the ${getOtherProcessName(isSubprocess)} exited or disconnected.`);\n};\n\n// When both processes use `sendMessage()` with `strict` at the same time\nexport const throwOnStrictDeadlockError = isSubprocess => {\n\tthrow new Error(`${getMethodName('sendMessage', isSubprocess)} failed: the ${getOtherProcessName(isSubprocess)} is sending a message too, instead of listening to incoming messages.\nThis can be fixed by both sending a message and listening to incoming messages at the same time:\n\nconst [receivedMessage] = await Promise.all([\n\t${getMethodName('getOneMessage', isSubprocess)},\n\t${getMethodName('sendMessage', isSubprocess, 'message, {strict: true}')},\n]);`);\n};\n\n// When the other process used `strict` but the current process had I/O error calling `sendMessage()` for the response\nexport const getStrictResponseError = (error, isSubprocess) => new Error(`${getMethodName('sendMessage', isSubprocess)} failed when sending an acknowledgment response to the ${getOtherProcessName(isSubprocess)}.`, {cause: error});\n\n// When using `strict` but the other process was not listening for messages\nexport const throwOnMissingStrict = isSubprocess => {\n\tthrow new Error(`${getMethodName('sendMessage', isSubprocess)} failed: the ${getOtherProcessName(isSubprocess)} is not listening to incoming messages.`);\n};\n\n// When using `strict` but the other process disconnected before receiving the message\nexport const throwOnStrictDisconnect = isSubprocess => {\n\tthrow new Error(`${getMethodName('sendMessage', isSubprocess)} failed: the ${getOtherProcessName(isSubprocess)} exited without listening to incoming messages.`);\n};\n\n// When the current process disconnects while the subprocess is listening to `cancelSignal`\nexport const getAbortDisconnectError = () => new Error(`\\`cancelSignal\\` aborted: the ${getOtherProcessName(true)} disconnected.`);\n\n// When the subprocess uses `cancelSignal` but not the current process\nexport const throwOnMissingParent = () => {\n\tthrow new Error('`getCancelSignal()` cannot be used without setting the `cancelSignal` subprocess option.');\n};\n\n// EPIPE can happen when sending a message to a subprocess that is closing but has not disconnected yet\nexport const handleEpipeError = ({error, methodName, isSubprocess}) => {\n\tif (error.code === 'EPIPE') {\n\t\tthrow new Error(`${getMethodName(methodName, isSubprocess)} cannot be used: the ${getOtherProcessName(isSubprocess)} is disconnecting.`, {cause: error});\n\t}\n};\n\n// Better error message when sending messages which cannot be serialized.\n// Works with both `serialization: 'advanced'` and `serialization: 'json'`.\nexport const handleSerializationError = ({error, methodName, isSubprocess, message}) => {\n\tif (isSerializationError(error)) {\n\t\tthrow new Error(`${getMethodName(methodName, isSubprocess)}'s argument type is invalid: the message cannot be serialized: ${String(message)}.`, {cause: error});\n\t}\n};\n\nconst isSerializationError = ({code, message}) => SERIALIZATION_ERROR_CODES.has(code)\n\t|| SERIALIZATION_ERROR_MESSAGES.some(serializationErrorMessage => message.includes(serializationErrorMessage));\n\n// `error.code` set by Node.js when it failed to serialize the message\nconst SERIALIZATION_ERROR_CODES = new Set([\n\t// Message is `undefined`\n\t'ERR_MISSING_ARGS',\n\t// Message is a function, a bigint, a symbol\n\t'ERR_INVALID_ARG_TYPE',\n]);\n\n// `error.message` set by Node.js when it failed to serialize the message\nconst SERIALIZATION_ERROR_MESSAGES = [\n\t// Message is a promise or a proxy, with `serialization: 'advanced'`\n\t'could not be cloned',\n\t// Message has cycles, with `serialization: 'json'`\n\t'circular structure',\n\t// Message has cycles inside toJSON(), with `serialization: 'json'`\n\t'call stack size exceeded',\n];\n\nconst getMethodName = (methodName, isSubprocess, parameters = '') => methodName === 'cancelSignal'\n\t? '`cancelSignal`\\'s `controller.abort()`'\n\t: `${getNamespaceName(isSubprocess)}${methodName}(${parameters})`;\n\nconst getNamespaceName = isSubprocess => isSubprocess ? '' : 'subprocess.';\n\nconst getOtherProcessName = isSubprocess => isSubprocess ? 'parent process' : 'subprocess';\n\n// When any error arises, we disconnect the IPC.\n// Otherwise, it is likely that one of the processes will stop sending/receiving messages.\n// This would leave the other process hanging.\nexport const disconnect = anyProcess => {\n\tif (anyProcess.connected) {\n\t\tanyProcess.disconnect();\n\t}\n};\n","export const createDeferred = () => {\n\tconst methods = {};\n\tconst promise = new Promise((resolve, reject) => {\n\t\tObject.assign(methods, {resolve, reject});\n\t});\n\treturn Object.assign(promise, methods);\n};\n","import {parseFd} from './specific.js';\n\n// Retrieve stream targeted by the `to` option\nexport const getToStream = (destination, to = 'stdin') => {\n\tconst isWritable = true;\n\tconst {options, fileDescriptors} = SUBPROCESS_OPTIONS.get(destination);\n\tconst fdNumber = getFdNumber(fileDescriptors, to, isWritable);\n\tconst destinationStream = destination.stdio[fdNumber];\n\n\tif (destinationStream === null) {\n\t\tthrow new TypeError(getInvalidStdioOptionMessage(fdNumber, to, options, isWritable));\n\t}\n\n\treturn destinationStream;\n};\n\n// Retrieve stream targeted by the `from` option\nexport const getFromStream = (source, from = 'stdout') => {\n\tconst isWritable = false;\n\tconst {options, fileDescriptors} = SUBPROCESS_OPTIONS.get(source);\n\tconst fdNumber = getFdNumber(fileDescriptors, from, isWritable);\n\tconst sourceStream = fdNumber === 'all' ? source.all : source.stdio[fdNumber];\n\n\tif (sourceStream === null || sourceStream === undefined) {\n\t\tthrow new TypeError(getInvalidStdioOptionMessage(fdNumber, from, options, isWritable));\n\t}\n\n\treturn sourceStream;\n};\n\n// Keeps track of the options passed to each Execa call\nexport const SUBPROCESS_OPTIONS = new WeakMap();\n\nconst getFdNumber = (fileDescriptors, fdName, isWritable) => {\n\tconst fdNumber = parseFdNumber(fdName, isWritable);\n\tvalidateFdNumber(fdNumber, fdName, isWritable, fileDescriptors);\n\treturn fdNumber;\n};\n\nconst parseFdNumber = (fdName, isWritable) => {\n\tconst fdNumber = parseFd(fdName);\n\tif (fdNumber !== undefined) {\n\t\treturn fdNumber;\n\t}\n\n\tconst {validOptions, defaultValue} = isWritable\n\t\t? {validOptions: '\"stdin\"', defaultValue: 'stdin'}\n\t\t: {validOptions: '\"stdout\", \"stderr\", \"all\"', defaultValue: 'stdout'};\n\tthrow new TypeError(`\"${getOptionName(isWritable)}\" must not be \"${fdName}\".\nIt must be ${validOptions} or \"fd3\", \"fd4\" (and so on).\nIt is optional and defaults to \"${defaultValue}\".`);\n};\n\nconst validateFdNumber = (fdNumber, fdName, isWritable, fileDescriptors) => {\n\tconst fileDescriptor = fileDescriptors[getUsedDescriptor(fdNumber)];\n\tif (fileDescriptor === undefined) {\n\t\tthrow new TypeError(`\"${getOptionName(isWritable)}\" must not be ${fdName}. That file descriptor does not exist.\nPlease set the \"stdio\" option to ensure that file descriptor exists.`);\n\t}\n\n\tif (fileDescriptor.direction === 'input' && !isWritable) {\n\t\tthrow new TypeError(`\"${getOptionName(isWritable)}\" must not be ${fdName}. It must be a readable stream, not writable.`);\n\t}\n\n\tif (fileDescriptor.direction !== 'input' && isWritable) {\n\t\tthrow new TypeError(`\"${getOptionName(isWritable)}\" must not be ${fdName}. It must be a writable stream, not readable.`);\n\t}\n};\n\nconst getInvalidStdioOptionMessage = (fdNumber, fdName, options, isWritable) => {\n\tif (fdNumber === 'all' && !options.all) {\n\t\treturn 'The \"all\" option must be true to use \"from: \\'all\\'\".';\n\t}\n\n\tconst {optionName, optionValue} = getInvalidStdioOption(fdNumber, options);\n\treturn `The \"${optionName}: ${serializeOptionValue(optionValue)}\" option is incompatible with using \"${getOptionName(isWritable)}: ${serializeOptionValue(fdName)}\".\nPlease set this option with \"pipe\" instead.`;\n};\n\nconst getInvalidStdioOption = (fdNumber, {stdin, stdout, stderr, stdio}) => {\n\tconst usedDescriptor = getUsedDescriptor(fdNumber);\n\n\tif (usedDescriptor === 0 && stdin !== undefined) {\n\t\treturn {optionName: 'stdin', optionValue: stdin};\n\t}\n\n\tif (usedDescriptor === 1 && stdout !== undefined) {\n\t\treturn {optionName: 'stdout', optionValue: stdout};\n\t}\n\n\tif (usedDescriptor === 2 && stderr !== undefined) {\n\t\treturn {optionName: 'stderr', optionValue: stderr};\n\t}\n\n\treturn {optionName: `stdio[${usedDescriptor}]`, optionValue: stdio[usedDescriptor]};\n};\n\nconst getUsedDescriptor = fdNumber => fdNumber === 'all' ? 1 : fdNumber;\n\nconst getOptionName = isWritable => isWritable ? 'to' : 'from';\n\nexport const serializeOptionValue = value => {\n\tif (typeof value === 'string') {\n\t\treturn `'${value}'`;\n\t}\n\n\treturn typeof value === 'number' ? `${value}` : 'Stream';\n};\n","import {addAbortListener} from 'node:events';\n\n// Temporarily increase the maximum number of listeners on an eventEmitter\nexport const incrementMaxListeners = (eventEmitter, maxListenersIncrement, signal) => {\n\tconst maxListeners = eventEmitter.getMaxListeners();\n\tif (maxListeners === 0 || maxListeners === Number.POSITIVE_INFINITY) {\n\t\treturn;\n\t}\n\n\teventEmitter.setMaxListeners(maxListeners + maxListenersIncrement);\n\taddAbortListener(signal, () => {\n\t\teventEmitter.setMaxListeners(eventEmitter.getMaxListeners() - maxListenersIncrement);\n\t});\n};\n","// By default, Node.js keeps the subprocess alive while it has a `message` or `disconnect` listener.\n// We replicate the same logic for the events that we proxy.\n// This ensures the subprocess is kept alive while `getOneMessage()` and `getEachMessage()` are ongoing.\n// This is not a problem with `sendMessage()` since Node.js handles that method automatically.\n// We do not use `anyProcess.channel.ref()` since this would prevent the automatic `.channel.refCounted()` Node.js is doing.\n// We keep a reference to `anyProcess.channel` since it might be `null` while `getOneMessage()` or `getEachMessage()` is still processing debounced messages.\n// See https://github.com/nodejs/node/blob/2aaeaa863c35befa2ebaa98fb7737ec84df4d8e9/lib/internal/child_process.js#L547\nexport const addReference = (channel, reference) => {\n\tif (reference) {\n\t\taddReferenceCount(channel);\n\t}\n};\n\nconst addReferenceCount = channel => {\n\tchannel.refCounted();\n};\n\nexport const removeReference = (channel, reference) => {\n\tif (reference) {\n\t\tremoveReferenceCount(channel);\n\t}\n};\n\nconst removeReferenceCount = channel => {\n\tchannel.unrefCounted();\n};\n\n// To proxy events, we setup some global listeners on the `message` and `disconnect` events.\n// Those should not keep the subprocess alive, so we remove the automatic counting that Node.js is doing.\n// See https://github.com/nodejs/node/blob/1b965270a9c273d4cf70e8808e9d28b9ada7844f/lib/child_process.js#L180\nexport const undoAddedReferences = (channel, isSubprocess) => {\n\tif (isSubprocess) {\n\t\tremoveReferenceCount(channel);\n\t\tremoveReferenceCount(channel);\n\t}\n};\n\n// Reverse it during `disconnect`\nexport const redoAddedReferences = (channel, isSubprocess) => {\n\tif (isSubprocess) {\n\t\taddReferenceCount(channel);\n\t\taddReferenceCount(channel);\n\t}\n};\n","import {once} from 'node:events';\nimport {scheduler} from 'node:timers/promises';\nimport {waitForOutgoingMessages} from './outgoing.js';\nimport {redoAddedReferences} from './reference.js';\nimport {handleStrictRequest, handleStrictResponse} from './strict.js';\nimport {handleAbort, abortOnDisconnect} from './graceful.js';\n\n// By default, Node.js buffers `message` events.\n// - Buffering happens when there is a `message` event is emitted but there is no handler.\n// - As soon as a `message` event handler is set, all buffered `message` events are emitted, emptying the buffer.\n// - This happens both in the current process and the subprocess.\n// - See https://github.com/nodejs/node/blob/501546e8f37059cd577041e23941b640d0d4d406/lib/internal/child_process.js#L719\n// This is helpful. Notably, this allows sending messages to a subprocess that's still initializing.\n// However, it has several problems.\n// - This works with `events.on()` but not `events.once()` since all buffered messages are emitted at once.\n// For example, users cannot call `await getOneMessage()`/`getEachMessage()` multiple times in a row.\n// - When a user intentionally starts listening to `message` at a specific point in time, past `message` events are replayed, which might be unexpected.\n// - Buffering is unlimited, which might lead to an out-of-memory crash.\n// - This does not work well with multiple consumers.\n// For example, Execa consumes events with both `result.ipcOutput` and manual IPC calls like `getOneMessage()`.\n// Since `result.ipcOutput` reads all incoming messages, no buffering happens for manual IPC calls.\n// - Forgetting to setup a `message` listener, or setting it up too late, is a programming mistake.\n// The default behavior does not allow users to realize they made that mistake.\n// To solve those problems, instead of buffering messages, we debounce them.\n// The `message` event so it is emitted at most once per macrotask.\nexport const onMessage = async ({anyProcess, channel, isSubprocess, ipcEmitter}, wrappedMessage) => {\n\tif (handleStrictResponse(wrappedMessage) || handleAbort(wrappedMessage)) {\n\t\treturn;\n\t}\n\n\tif (!INCOMING_MESSAGES.has(anyProcess)) {\n\t\tINCOMING_MESSAGES.set(anyProcess, []);\n\t}\n\n\tconst incomingMessages = INCOMING_MESSAGES.get(anyProcess);\n\tincomingMessages.push(wrappedMessage);\n\n\tif (incomingMessages.length > 1) {\n\t\treturn;\n\t}\n\n\twhile (incomingMessages.length > 0) {\n\t\t// eslint-disable-next-line no-await-in-loop\n\t\tawait waitForOutgoingMessages(anyProcess, ipcEmitter, wrappedMessage);\n\t\t// eslint-disable-next-line no-await-in-loop\n\t\tawait scheduler.yield();\n\n\t\t// eslint-disable-next-line no-await-in-loop\n\t\tconst message = await handleStrictRequest({\n\t\t\twrappedMessage: incomingMessages[0],\n\t\t\tanyProcess,\n\t\t\tchannel,\n\t\t\tisSubprocess,\n\t\t\tipcEmitter,\n\t\t});\n\n\t\tincomingMessages.shift();\n\t\tipcEmitter.emit('message', message);\n\t\tipcEmitter.emit('message:done');\n\t}\n};\n\n// If the `message` event is currently debounced, the `disconnect` event must wait for it\nexport const onDisconnect = async ({anyProcess, channel, isSubprocess, ipcEmitter, boundOnMessage}) => {\n\tabortOnDisconnect();\n\n\tconst incomingMessages = INCOMING_MESSAGES.get(anyProcess);\n\twhile (incomingMessages?.length > 0) {\n\t\t// eslint-disable-next-line no-await-in-loop\n\t\tawait once(ipcEmitter, 'message:done');\n\t}\n\n\tanyProcess.removeListener('message', boundOnMessage);\n\tredoAddedReferences(channel, isSubprocess);\n\tipcEmitter.connected = false;\n\tipcEmitter.emit('disconnect');\n};\n\nconst INCOMING_MESSAGES = new WeakMap();\n","import {EventEmitter} from 'node:events';\nimport {onMessage, onDisconnect} from './incoming.js';\nimport {undoAddedReferences} from './reference.js';\n\n// Forward the `message` and `disconnect` events from the process and subprocess to a proxy emitter.\n// This prevents the `error` event from stopping IPC.\n// This also allows debouncing the `message` event.\nexport const getIpcEmitter = (anyProcess, channel, isSubprocess) => {\n\tif (IPC_EMITTERS.has(anyProcess)) {\n\t\treturn IPC_EMITTERS.get(anyProcess);\n\t}\n\n\t// Use an `EventEmitter`, like the `process` that is being proxied\n\t// eslint-disable-next-line unicorn/prefer-event-target\n\tconst ipcEmitter = new EventEmitter();\n\tipcEmitter.connected = true;\n\tIPC_EMITTERS.set(anyProcess, ipcEmitter);\n\tforwardEvents({\n\t\tipcEmitter,\n\t\tanyProcess,\n\t\tchannel,\n\t\tisSubprocess,\n\t});\n\treturn ipcEmitter;\n};\n\nconst IPC_EMITTERS = new WeakMap();\n\n// The `message` and `disconnect` events are buffered in the subprocess until the first listener is setup.\n// However, unbuffering happens after one tick, so this give enough time for the caller to setup the listener on the proxy emitter first.\n// See https://github.com/nodejs/node/blob/2aaeaa863c35befa2ebaa98fb7737ec84df4d8e9/lib/internal/child_process.js#L721\nconst forwardEvents = ({ipcEmitter, anyProcess, channel, isSubprocess}) => {\n\tconst boundOnMessage = onMessage.bind(undefined, {\n\t\tanyProcess,\n\t\tchannel,\n\t\tisSubprocess,\n\t\tipcEmitter,\n\t});\n\tanyProcess.on('message', boundOnMessage);\n\tanyProcess.once('disconnect', onDisconnect.bind(undefined, {\n\t\tanyProcess,\n\t\tchannel,\n\t\tisSubprocess,\n\t\tipcEmitter,\n\t\tboundOnMessage,\n\t}));\n\tundoAddedReferences(channel, isSubprocess);\n};\n\n// Check whether there might still be some `message` events to receive\nexport const isConnected = anyProcess => {\n\tconst ipcEmitter = IPC_EMITTERS.get(anyProcess);\n\treturn ipcEmitter === undefined\n\t\t? anyProcess.channel !== null\n\t\t: ipcEmitter.connected;\n};\n","import {once} from 'node:events';\nimport {createDeferred} from '../utils/deferred.js';\nimport {incrementMaxListeners} from '../utils/max-listeners.js';\nimport {sendMessage} from './send.js';\nimport {throwOnMissingStrict, throwOnStrictDisconnect, throwOnStrictDeadlockError} from './validation.js';\nimport {getIpcEmitter} from './forward.js';\nimport {hasMessageListeners} from './outgoing.js';\n\n// When using the `strict` option, wrap the message with metadata during `sendMessage()`\nexport const handleSendStrict = ({anyProcess, channel, isSubprocess, message, strict}) => {\n\tif (!strict) {\n\t\treturn message;\n\t}\n\n\tconst ipcEmitter = getIpcEmitter(anyProcess, channel, isSubprocess);\n\tconst hasListeners = hasMessageListeners(anyProcess, ipcEmitter);\n\treturn {\n\t\tid: count++,\n\t\ttype: REQUEST_TYPE,\n\t\tmessage,\n\t\thasListeners,\n\t};\n};\n\nlet count = 0n;\n\n// Handles when both processes are calling `sendMessage()` with `strict` at the same time.\n// If neither process is listening, this would create a deadlock. We detect it and throw.\nexport const validateStrictDeadlock = (outgoingMessages, wrappedMessage) => {\n\tif (wrappedMessage?.type !== REQUEST_TYPE || wrappedMessage.hasListeners) {\n\t\treturn;\n\t}\n\n\tfor (const {id} of outgoingMessages) {\n\t\tif (id !== undefined) {\n\t\t\tSTRICT_RESPONSES[id].resolve({isDeadlock: true, hasListeners: false});\n\t\t}\n\t}\n};\n\n// The other process then sends the acknowledgment back as a response\nexport const handleStrictRequest = async ({wrappedMessage, anyProcess, channel, isSubprocess, ipcEmitter}) => {\n\tif (wrappedMessage?.type !== REQUEST_TYPE || !anyProcess.connected) {\n\t\treturn wrappedMessage;\n\t}\n\n\tconst {id, message} = wrappedMessage;\n\tconst response = {id, type: RESPONSE_TYPE, message: hasMessageListeners(anyProcess, ipcEmitter)};\n\n\ttry {\n\t\tawait sendMessage({\n\t\t\tanyProcess,\n\t\t\tchannel,\n\t\t\tisSubprocess,\n\t\t\tipc: true,\n\t\t}, response);\n\t} catch (error) {\n\t\tipcEmitter.emit('strict:error', error);\n\t}\n\n\treturn message;\n};\n\n// Reception of the acknowledgment response\nexport const handleStrictResponse = wrappedMessage => {\n\tif (wrappedMessage?.type !== RESPONSE_TYPE) {\n\t\treturn false;\n\t}\n\n\tconst {id, message: hasListeners} = wrappedMessage;\n\tSTRICT_RESPONSES[id]?.resolve({isDeadlock: false, hasListeners});\n\treturn true;\n};\n\n// Wait for the other process to receive the message from `sendMessage()`\nexport const waitForStrictResponse = async (wrappedMessage, anyProcess, isSubprocess) => {\n\tif (wrappedMessage?.type !== REQUEST_TYPE) {\n\t\treturn;\n\t}\n\n\tconst deferred = createDeferred();\n\tSTRICT_RESPONSES[wrappedMessage.id] = deferred;\n\tconst controller = new AbortController();\n\n\ttry {\n\t\tconst {isDeadlock, hasListeners} = await Promise.race([\n\t\t\tdeferred,\n\t\t\tthrowOnDisconnect(anyProcess, isSubprocess, controller),\n\t\t]);\n\n\t\tif (isDeadlock) {\n\t\t\tthrowOnStrictDeadlockError(isSubprocess);\n\t\t}\n\n\t\tif (!hasListeners) {\n\t\t\tthrowOnMissingStrict(isSubprocess);\n\t\t}\n\t} finally {\n\t\tcontroller.abort();\n\t\tdelete STRICT_RESPONSES[wrappedMessage.id];\n\t}\n};\n\nconst STRICT_RESPONSES = {};\n\nconst throwOnDisconnect = async (anyProcess, isSubprocess, {signal}) => {\n\tincrementMaxListeners(anyProcess, 1, signal);\n\tawait once(anyProcess, 'disconnect', {signal});\n\tthrowOnStrictDisconnect(isSubprocess);\n};\n\nconst REQUEST_TYPE = 'execa:ipc:request';\nconst RESPONSE_TYPE = 'execa:ipc:response';\n","import {createDeferred} from '../utils/deferred.js';\nimport {getFdSpecificValue} from '../arguments/specific.js';\nimport {SUBPROCESS_OPTIONS} from '../arguments/fd-options.js';\nimport {validateStrictDeadlock} from './strict.js';\n\n// When `sendMessage()` is ongoing, any `message` being received waits before being emitted.\n// This allows calling one or multiple `await sendMessage()` followed by `await getOneMessage()`/`await getEachMessage()`.\n// Without running into a race condition when the other process sends a response too fast, before the current process set up a listener.\nexport const startSendMessage = (anyProcess, wrappedMessage, strict) => {\n\tif (!OUTGOING_MESSAGES.has(anyProcess)) {\n\t\tOUTGOING_MESSAGES.set(anyProcess, new Set());\n\t}\n\n\tconst outgoingMessages = OUTGOING_MESSAGES.get(anyProcess);\n\tconst onMessageSent = createDeferred();\n\tconst id = strict ? wrappedMessage.id : undefined;\n\tconst outgoingMessage = {onMessageSent, id};\n\toutgoingMessages.add(outgoingMessage);\n\treturn {outgoingMessages, outgoingMessage};\n};\n\nexport const endSendMessage = ({outgoingMessages, outgoingMessage}) => {\n\toutgoingMessages.delete(outgoingMessage);\n\toutgoingMessage.onMessageSent.resolve();\n};\n\n// Await while `sendMessage()` is ongoing, unless there is already a `message` listener\nexport const waitForOutgoingMessages = async (anyProcess, ipcEmitter, wrappedMessage) => {\n\twhile (!hasMessageListeners(anyProcess, ipcEmitter) && OUTGOING_MESSAGES.get(anyProcess)?.size > 0) {\n\t\tconst outgoingMessages = [...OUTGOING_MESSAGES.get(anyProcess)];\n\t\tvalidateStrictDeadlock(outgoingMessages, wrappedMessage);\n\t\t// eslint-disable-next-line no-await-in-loop\n\t\tawait Promise.all(outgoingMessages.map(({onMessageSent}) => onMessageSent));\n\t}\n};\n\nconst OUTGOING_MESSAGES = new WeakMap();\n\n// Whether any `message` listener is setup\nexport const hasMessageListeners = (anyProcess, ipcEmitter) => ipcEmitter.listenerCount('message') > getMinListenerCount(anyProcess);\n\n// When `buffer` is `false`, we set up a `message` listener that should be ignored.\n// That listener is only meant to intercept `strict` acknowledgement responses.\nconst getMinListenerCount = anyProcess => SUBPROCESS_OPTIONS.has(anyProcess)\n\t&& !getFdSpecificValue(SUBPROCESS_OPTIONS.get(anyProcess).options.buffer, 'ipc')\n\t? 1\n\t: 0;\n","import {promisify} from 'node:util';\nimport {\n\tvalidateIpcMethod,\n\thandleEpipeError,\n\thandleSerializationError,\n\tdisconnect,\n} from './validation.js';\nimport {startSendMessage, endSendMessage} from './outgoing.js';\nimport {handleSendStrict, waitForStrictResponse} from './strict.js';\n\n// Like `[sub]process.send()` but promise-based.\n// We do not `await subprocess` during `.sendMessage()` nor `.getOneMessage()` since those methods are transient.\n// Users would still need to `await subprocess` after the method is done.\n// Also, this would prevent `unhandledRejection` event from being emitted, making it silent.\nexport const sendMessage = ({anyProcess, channel, isSubprocess, ipc}, message, {strict = false} = {}) => {\n\tconst methodName = 'sendMessage';\n\tvalidateIpcMethod({\n\t\tmethodName,\n\t\tisSubprocess,\n\t\tipc,\n\t\tisConnected: anyProcess.connected,\n\t});\n\n\treturn sendMessageAsync({\n\t\tanyProcess,\n\t\tchannel,\n\t\tmethodName,\n\t\tisSubprocess,\n\t\tmessage,\n\t\tstrict,\n\t});\n};\n\nconst sendMessageAsync = async ({anyProcess, channel, methodName, isSubprocess, message, strict}) => {\n\tconst wrappedMessage = handleSendStrict({\n\t\tanyProcess,\n\t\tchannel,\n\t\tisSubprocess,\n\t\tmessage,\n\t\tstrict,\n\t});\n\tconst outgoingMessagesState = startSendMessage(anyProcess, wrappedMessage, strict);\n\ttry {\n\t\tawait sendOneMessage({\n\t\t\tanyProcess,\n\t\t\tmethodName,\n\t\t\tisSubprocess,\n\t\t\twrappedMessage,\n\t\t\tmessage,\n\t\t});\n\t} catch (error) {\n\t\tdisconnect(anyProcess);\n\t\tthrow error;\n\t} finally {\n\t\tendSendMessage(outgoingMessagesState);\n\t}\n};\n\n// Used internally by `cancelSignal`\nexport const sendOneMessage = async ({anyProcess, methodName, isSubprocess, wrappedMessage, message}) => {\n\tconst sendMethod = getSendMethod(anyProcess);\n\n\ttry {\n\t\tawait Promise.all([\n\t\t\twaitForStrictResponse(wrappedMessage, anyProcess, isSubprocess),\n\t\t\tsendMethod(wrappedMessage),\n\t\t]);\n\t} catch (error) {\n\t\thandleEpipeError({error, methodName, isSubprocess});\n\t\thandleSerializationError({\n\t\t\terror,\n\t\t\tmethodName,\n\t\t\tisSubprocess,\n\t\t\tmessage,\n\t\t});\n\t\tthrow error;\n\t}\n};\n\n// [sub]process.send() promisified, memoized\nconst getSendMethod = anyProcess => {\n\tif (PROCESS_SEND_METHODS.has(anyProcess)) {\n\t\treturn PROCESS_SEND_METHODS.get(anyProcess);\n\t}\n\n\tconst sendMethod = promisify(anyProcess.send.bind(anyProcess));\n\tPROCESS_SEND_METHODS.set(anyProcess, sendMethod);\n\treturn sendMethod;\n};\n\nconst PROCESS_SEND_METHODS = new WeakMap();\n","import {scheduler} from 'node:timers/promises';\nimport {sendOneMessage} from './send.js';\nimport {getIpcEmitter} from './forward.js';\nimport {validateConnection, getAbortDisconnectError, throwOnMissingParent} from './validation.js';\n\n// Send an IPC message so the subprocess performs a graceful termination\nexport const sendAbort = (subprocess, message) => {\n\tconst methodName = 'cancelSignal';\n\tvalidateConnection(methodName, false, subprocess.connected);\n\treturn sendOneMessage({\n\t\tanyProcess: subprocess,\n\t\tmethodName,\n\t\tisSubprocess: false,\n\t\twrappedMessage: {type: GRACEFUL_CANCEL_TYPE, message},\n\t\tmessage,\n\t});\n};\n\n// When the signal is being used, start listening for incoming messages.\n// Unbuffering messages takes one microtask to complete, so this must be async.\nexport const getCancelSignal = async ({anyProcess, channel, isSubprocess, ipc}) => {\n\tawait startIpc({\n\t\tanyProcess,\n\t\tchannel,\n\t\tisSubprocess,\n\t\tipc,\n\t});\n\treturn cancelController.signal;\n};\n\nconst startIpc = async ({anyProcess, channel, isSubprocess, ipc}) => {\n\tif (cancelListening) {\n\t\treturn;\n\t}\n\n\tcancelListening = true;\n\n\tif (!ipc) {\n\t\tthrowOnMissingParent();\n\t\treturn;\n\t}\n\n\tif (channel === null) {\n\t\tabortOnDisconnect();\n\t\treturn;\n\t}\n\n\tgetIpcEmitter(anyProcess, channel, isSubprocess);\n\tawait scheduler.yield();\n};\n\nlet cancelListening = false;\n\n// Reception of IPC message to perform a graceful termination\nexport const handleAbort = wrappedMessage => {\n\tif (wrappedMessage?.type !== GRACEFUL_CANCEL_TYPE) {\n\t\treturn false;\n\t}\n\n\tcancelController.abort(wrappedMessage.message);\n\treturn true;\n};\n\nconst GRACEFUL_CANCEL_TYPE = 'execa:ipc:cancel';\n\n// When the current process disconnects early, the subprocess `cancelSignal` is aborted.\n// Otherwise, the signal would never be able to be aborted later on.\nexport const abortOnDisconnect = () => {\n\tcancelController.abort(getAbortDisconnectError());\n};\n\nconst cancelController = new AbortController();\n","import {onAbortedSignal} from '../utils/abort-signal.js';\nimport {sendAbort} from '../ipc/graceful.js';\nimport {killOnTimeout} from './kill.js';\n\n// Validate the `gracefulCancel` option\nexport const validateGracefulCancel = ({gracefulCancel, cancelSignal, ipc, serialization}) => {\n\tif (!gracefulCancel) {\n\t\treturn;\n\t}\n\n\tif (cancelSignal === undefined) {\n\t\tthrow new Error('The `cancelSignal` option must be defined when setting the `gracefulCancel` option.');\n\t}\n\n\tif (!ipc) {\n\t\tthrow new Error('The `ipc` option cannot be false when setting the `gracefulCancel` option.');\n\t}\n\n\tif (serialization === 'json') {\n\t\tthrow new Error('The `serialization` option cannot be \\'json\\' when setting the `gracefulCancel` option.');\n\t}\n};\n\n// Send abort reason to the subprocess when aborting the `cancelSignal` option and `gracefulCancel` is `true`\nexport const throwOnGracefulCancel = ({\n\tsubprocess,\n\tcancelSignal,\n\tgracefulCancel,\n\tforceKillAfterDelay,\n\tcontext,\n\tcontroller,\n}) => gracefulCancel\n\t? [sendOnAbort({\n\t\tsubprocess,\n\t\tcancelSignal,\n\t\tforceKillAfterDelay,\n\t\tcontext,\n\t\tcontroller,\n\t})]\n\t: [];\n\nconst sendOnAbort = async ({subprocess, cancelSignal, forceKillAfterDelay, context, controller: {signal}}) => {\n\tawait onAbortedSignal(cancelSignal, signal);\n\tconst reason = getReason(cancelSignal);\n\tawait sendAbort(subprocess, reason);\n\tkillOnTimeout({\n\t\tkill: subprocess.kill,\n\t\tforceKillAfterDelay,\n\t\tcontext,\n\t\tcontrollerSignal: signal,\n\t});\n\tcontext.terminationReason ??= 'gracefulCancel';\n\tthrow cancelSignal.reason;\n};\n\n// The default `reason` is a DOMException, which is not serializable with V8\n// See https://github.com/nodejs/node/issues/53225\nconst getReason = ({reason}) => {\n\tif (!(reason instanceof DOMException)) {\n\t\treturn reason;\n\t}\n\n\tconst error = new Error(reason.message);\n\tObject.defineProperty(error, 'stack', {\n\t\tvalue: reason.stack,\n\t\tenumerable: false,\n\t\tconfigurable: true,\n\t\twritable: true,\n\t});\n\treturn error;\n};\n","import {setTimeout} from 'node:timers/promises';\nimport {DiscardedError} from '../return/final-error.js';\n\n// Validate `timeout` option\nexport const validateTimeout = ({timeout}) => {\n\tif (timeout !== undefined && (!Number.isFinite(timeout) || timeout < 0)) {\n\t\tthrow new TypeError(`Expected the \\`timeout\\` option to be a non-negative integer, got \\`${timeout}\\` (${typeof timeout})`);\n\t}\n};\n\n// Fails when the `timeout` option is exceeded\nexport const throwOnTimeout = (subprocess, timeout, context, controller) => timeout === 0 || timeout === undefined\n\t? []\n\t: [killAfterTimeout(subprocess, timeout, context, controller)];\n\nconst killAfterTimeout = async (subprocess, timeout, context, {signal}) => {\n\tawait setTimeout(timeout, undefined, {signal});\n\tcontext.terminationReason ??= 'timeout';\n\tsubprocess.kill();\n\tthrow new DiscardedError();\n};\n","import {serialize} from 'node:v8';\n\n// Validate the `ipcInput` option\nexport const validateIpcInputOption = ({ipcInput, ipc, serialization}) => {\n\tif (ipcInput === undefined) {\n\t\treturn;\n\t}\n\n\tif (!ipc) {\n\t\tthrow new Error('The `ipcInput` option cannot be set unless the `ipc` option is `true`.');\n\t}\n\n\tvalidateIpcInput[serialization](ipcInput);\n};\n\nconst validateAdvancedInput = ipcInput => {\n\ttry {\n\t\tserialize(ipcInput);\n\t} catch (error) {\n\t\tthrow new Error('The `ipcInput` option is not serializable with a structured clone.', {cause: error});\n\t}\n};\n\nconst validateJsonInput = ipcInput => {\n\ttry {\n\t\tJSON.stringify(ipcInput);\n\t} catch (error) {\n\t\tthrow new Error('The `ipcInput` option is not serializable with JSON.', {cause: error});\n\t}\n};\n\nconst validateIpcInput = {\n\tadvanced: validateAdvancedInput,\n\tjson: validateJsonInput,\n};\n\n// When the `ipcInput` option is set, it is sent as an initial IPC message to the subprocess\nexport const sendIpcInput = async (subprocess, ipcInput) => {\n\tif (ipcInput === undefined) {\n\t\treturn;\n\t}\n\n\tawait subprocess.sendMessage(ipcInput);\n};\n","// Validate `encoding` option\nexport const validateEncoding = ({encoding}) => {\n\tif (ENCODINGS.has(encoding)) {\n\t\treturn;\n\t}\n\n\tconst correctEncoding = getCorrectEncoding(encoding);\n\tif (correctEncoding !== undefined) {\n\t\tthrow new TypeError(`Invalid option \\`encoding: ${serializeEncoding(encoding)}\\`.\nPlease rename it to ${serializeEncoding(correctEncoding)}.`);\n\t}\n\n\tconst correctEncodings = [...ENCODINGS].map(correctEncoding => serializeEncoding(correctEncoding)).join(', ');\n\tthrow new TypeError(`Invalid option \\`encoding: ${serializeEncoding(encoding)}\\`.\nPlease rename it to one of: ${correctEncodings}.`);\n};\n\nconst TEXT_ENCODINGS = new Set(['utf8', 'utf16le']);\nexport const BINARY_ENCODINGS = new Set(['buffer', 'hex', 'base64', 'base64url', 'latin1', 'ascii']);\nconst ENCODINGS = new Set([...TEXT_ENCODINGS, ...BINARY_ENCODINGS]);\n\nconst getCorrectEncoding = encoding => {\n\tif (encoding === null) {\n\t\treturn 'buffer';\n\t}\n\n\tif (typeof encoding !== 'string') {\n\t\treturn;\n\t}\n\n\tconst lowerEncoding = encoding.toLowerCase();\n\tif (lowerEncoding in ENCODING_ALIASES) {\n\t\treturn ENCODING_ALIASES[lowerEncoding];\n\t}\n\n\tif (ENCODINGS.has(lowerEncoding)) {\n\t\treturn lowerEncoding;\n\t}\n};\n\nconst ENCODING_ALIASES = {\n\t// eslint-disable-next-line unicorn/text-encoding-identifier-case\n\t'utf-8': 'utf8',\n\t'utf-16le': 'utf16le',\n\t'ucs-2': 'utf16le',\n\tucs2: 'utf16le',\n\tbinary: 'latin1',\n};\n\nconst serializeEncoding = encoding => typeof encoding === 'string' ? `\"${encoding}\"` : String(encoding);\n","import {statSync} from 'node:fs';\nimport path from 'node:path';\nimport process from 'node:process';\nimport {safeNormalizeFileUrl} from './file-url.js';\n\n// Normalize `cwd` option\nexport const normalizeCwd = (cwd = getDefaultCwd()) => {\n\tconst cwdString = safeNormalizeFileUrl(cwd, 'The \"cwd\" option');\n\treturn path.resolve(cwdString);\n};\n\nconst getDefaultCwd = () => {\n\ttry {\n\t\treturn process.cwd();\n\t} catch (error) {\n\t\terror.message = `The current directory does not exist.\\n${error.message}`;\n\t\tthrow error;\n\t}\n};\n\n// When `cwd` option has an invalid value, provide with a better error message\nexport const fixCwdError = (originalMessage, cwd) => {\n\tif (cwd === getDefaultCwd()) {\n\t\treturn originalMessage;\n\t}\n\n\tlet cwdStat;\n\ttry {\n\t\tcwdStat = statSync(cwd);\n\t} catch (error) {\n\t\treturn `The \"cwd\" option is invalid: ${cwd}.\\n${error.message}\\n${originalMessage}`;\n\t}\n\n\tif (!cwdStat.isDirectory()) {\n\t\treturn `The \"cwd\" option is not a directory: ${cwd}.\\n${originalMessage}`;\n\t}\n\n\treturn originalMessage;\n};\n","import path from 'node:path';\nimport process from 'node:process';\nimport crossSpawn from 'cross-spawn';\nimport {npmRunPathEnv} from 'npm-run-path';\nimport {normalizeForceKillAfterDelay} from '../terminate/kill.js';\nimport {normalizeKillSignal} from '../terminate/signal.js';\nimport {validateCancelSignal} from '../terminate/cancel.js';\nimport {validateGracefulCancel} from '../terminate/graceful.js';\nimport {validateTimeout} from '../terminate/timeout.js';\nimport {handleNodeOption} from '../methods/node.js';\nimport {validateIpcInputOption} from '../ipc/ipc-input.js';\nimport {validateEncoding, BINARY_ENCODINGS} from './encoding-option.js';\nimport {normalizeCwd} from './cwd.js';\nimport {normalizeFileUrl} from './file-url.js';\nimport {normalizeFdSpecificOptions} from './specific.js';\n\n// Normalize the options object, and sometimes also the file paths and arguments.\n// Applies default values, validate allowed options, normalize them.\nexport const normalizeOptions = (filePath, rawArguments, rawOptions) => {\n\trawOptions.cwd = normalizeCwd(rawOptions.cwd);\n\tconst [processedFile, processedArguments, processedOptions] = handleNodeOption(filePath, rawArguments, rawOptions);\n\n\tconst {command: file, args: commandArguments, options: initialOptions} = crossSpawn._parse(processedFile, processedArguments, processedOptions);\n\n\tconst fdOptions = normalizeFdSpecificOptions(initialOptions);\n\tconst options = addDefaultOptions(fdOptions);\n\tvalidateTimeout(options);\n\tvalidateEncoding(options);\n\tvalidateIpcInputOption(options);\n\tvalidateCancelSignal(options);\n\tvalidateGracefulCancel(options);\n\toptions.shell = normalizeFileUrl(options.shell);\n\toptions.env = getEnv(options);\n\toptions.killSignal = normalizeKillSignal(options.killSignal);\n\toptions.forceKillAfterDelay = normalizeForceKillAfterDelay(options.forceKillAfterDelay);\n\toptions.lines = options.lines.map((lines, fdNumber) => lines && !BINARY_ENCODINGS.has(options.encoding) && options.buffer[fdNumber]);\n\n\tif (process.platform === 'win32' && path.basename(file, '.exe') === 'cmd') {\n\t\t// #116\n\t\tcommandArguments.unshift('/q');\n\t}\n\n\treturn {file, commandArguments, options};\n};\n\nconst addDefaultOptions = ({\n\textendEnv = true,\n\tpreferLocal = false,\n\tcwd,\n\tlocalDir: localDirectory = cwd,\n\tencoding = 'utf8',\n\treject = true,\n\tcleanup = true,\n\tall = false,\n\twindowsHide = true,\n\tkillSignal = 'SIGTERM',\n\tforceKillAfterDelay = true,\n\tgracefulCancel = false,\n\tipcInput,\n\tipc = ipcInput !== undefined || gracefulCancel,\n\tserialization = 'advanced',\n\t...options\n}) => ({\n\t...options,\n\textendEnv,\n\tpreferLocal,\n\tcwd,\n\tlocalDirectory,\n\tencoding,\n\treject,\n\tcleanup,\n\tall,\n\twindowsHide,\n\tkillSignal,\n\tforceKillAfterDelay,\n\tgracefulCancel,\n\tipcInput,\n\tipc,\n\tserialization,\n});\n\nconst getEnv = ({env: envOption, extendEnv, preferLocal, node, localDirectory, nodePath}) => {\n\tconst env = extendEnv ? {...process.env, ...envOption} : envOption;\n\n\tif (preferLocal || node) {\n\t\treturn npmRunPathEnv({\n\t\t\tenv,\n\t\t\tcwd: localDirectory,\n\t\t\texecPath: nodePath,\n\t\t\tpreferLocal,\n\t\t\taddExecPath: node,\n\t\t});\n\t}\n\n\treturn env;\n};\n","import {execPath, execArgv} from 'node:process';\nimport path from 'node:path';\nimport {safeNormalizeFileUrl} from '../arguments/file-url.js';\n\n// `execaNode()` is a shortcut for `execa(..., {node: true})`\nexport const mapNode = ({options}) => {\n\tif (options.node === false) {\n\t\tthrow new TypeError('The \"node\" option cannot be false with `execaNode()`.');\n\t}\n\n\treturn {options: {...options, node: true}};\n};\n\n// Applies the `node: true` option, and the related `nodePath`/`nodeOptions` options.\n// Modifies the file commands/arguments to ensure the same Node binary and flags are re-used.\n// Also adds `ipc: true` and `shell: false`.\nexport const handleNodeOption = (file, commandArguments, {\n\tnode: shouldHandleNode = false,\n\tnodePath = execPath,\n\tnodeOptions = execArgv.filter(nodeOption => !nodeOption.startsWith('--inspect')),\n\tcwd,\n\texecPath: formerNodePath,\n\t...options\n}) => {\n\tif (formerNodePath !== undefined) {\n\t\tthrow new TypeError('The \"execPath\" option has been removed. Please use the \"nodePath\" option instead.');\n\t}\n\n\tconst normalizedNodePath = safeNormalizeFileUrl(nodePath, 'The \"nodePath\" option');\n\tconst resolvedNodePath = path.resolve(cwd, normalizedNodePath);\n\tconst newOptions = {\n\t\t...options,\n\t\tnodePath: resolvedNodePath,\n\t\tnode: shouldHandleNode,\n\t\tcwd,\n\t};\n\n\tif (!shouldHandleNode) {\n\t\treturn [file, commandArguments, newOptions];\n\t}\n\n\tif (path.basename(file, '.exe') === 'node') {\n\t\tthrow new TypeError('When the \"node\" option is true, the first argument does not need to be \"node\".');\n\t}\n\n\treturn [\n\t\tresolvedNodePath,\n\t\t[...nodeOptions, file, ...commandArguments],\n\t\t{ipc: true, ...newOptions, shell: false},\n\t];\n};\n","import {isReadableStream} from 'is-stream';\nimport {asyncIterator} from '@sec-ant/readable-stream/ponyfill';\n\nexport const getAsyncIterable = stream => {\n\tif (isReadableStream(stream, {checkOpen: false}) && nodeImports.on !== undefined) {\n\t\treturn getStreamIterable(stream);\n\t}\n\n\tif (typeof stream?.[Symbol.asyncIterator] === 'function') {\n\t\treturn stream;\n\t}\n\n\t// `ReadableStream[Symbol.asyncIterator]` support is missing in multiple browsers, so we ponyfill it\n\tif (toString.call(stream) === '[object ReadableStream]') {\n\t\treturn asyncIterator.call(stream);\n\t}\n\n\tthrow new TypeError('The first argument must be a Readable, a ReadableStream, or an async iterable.');\n};\n\nconst {toString} = Object.prototype;\n\n// The default iterable for Node.js streams does not allow for multiple readers at once, so we re-implement it\nconst getStreamIterable = async function * (stream) {\n\tconst controller = new AbortController();\n\tconst state = {};\n\thandleStreamEnd(stream, controller, state);\n\n\ttry {\n\t\tfor await (const [chunk] of nodeImports.on(stream, 'data', {signal: controller.signal})) {\n\t\t\tyield chunk;\n\t\t}\n\t} catch (error) {\n\t\t// Stream failure, for example due to `stream.destroy(error)`\n\t\tif (state.error !== undefined) {\n\t\t\tthrow state.error;\n\t\t// `error` event directly emitted on stream\n\t\t} else if (!controller.signal.aborted) {\n\t\t\tthrow error;\n\t\t// Otherwise, stream completed successfully\n\t\t}\n\t\t// The `finally` block also runs when the caller throws, for example due to the `maxBuffer` option\n\t} finally {\n\t\tstream.destroy();\n\t}\n};\n\nconst handleStreamEnd = async (stream, controller, state) => {\n\ttry {\n\t\tawait nodeImports.finished(stream, {\n\t\t\tcleanup: true,\n\t\t\treadable: true,\n\t\t\twritable: false,\n\t\t\terror: false,\n\t\t});\n\t} catch (error) {\n\t\tstate.error = error;\n\t} finally {\n\t\tcontroller.abort();\n\t}\n};\n\n// Loaded by the Node entrypoint, but not by the browser one.\n// This prevents using dynamic imports.\nexport const nodeImports = {};\n","import {getAsyncIterable} from './stream.js';\n\nexport const getStreamContents = async (stream, {init, convertChunk, getSize, truncateChunk, addChunk, getFinalChunk, finalize}, {maxBuffer = Number.POSITIVE_INFINITY} = {}) => {\n\tconst asyncIterable = getAsyncIterable(stream);\n\n\tconst state = init();\n\tstate.length = 0;\n\n\ttry {\n\t\tfor await (const chunk of asyncIterable) {\n\t\t\tconst chunkType = getChunkType(chunk);\n\t\t\tconst convertedChunk = convertChunk[chunkType](chunk, state);\n\t\t\tappendChunk({\n\t\t\t\tconvertedChunk,\n\t\t\t\tstate,\n\t\t\t\tgetSize,\n\t\t\t\ttruncateChunk,\n\t\t\t\taddChunk,\n\t\t\t\tmaxBuffer,\n\t\t\t});\n\t\t}\n\n\t\tappendFinalChunk({\n\t\t\tstate,\n\t\t\tconvertChunk,\n\t\t\tgetSize,\n\t\t\ttruncateChunk,\n\t\t\taddChunk,\n\t\t\tgetFinalChunk,\n\t\t\tmaxBuffer,\n\t\t});\n\t\treturn finalize(state);\n\t} catch (error) {\n\t\tconst normalizedError = typeof error === 'object' && error !== null ? error : new Error(error);\n\t\tnormalizedError.bufferedData = finalize(state);\n\t\tthrow normalizedError;\n\t}\n};\n\nconst appendFinalChunk = ({state, getSize, truncateChunk, addChunk, getFinalChunk, maxBuffer}) => {\n\tconst convertedChunk = getFinalChunk(state);\n\tif (convertedChunk !== undefined) {\n\t\tappendChunk({\n\t\t\tconvertedChunk,\n\t\t\tstate,\n\t\t\tgetSize,\n\t\t\ttruncateChunk,\n\t\t\taddChunk,\n\t\t\tmaxBuffer,\n\t\t});\n\t}\n};\n\nconst appendChunk = ({convertedChunk, state, getSize, truncateChunk, addChunk, maxBuffer}) => {\n\tconst chunkSize = getSize(convertedChunk);\n\tconst newLength = state.length + chunkSize;\n\n\tif (newLength <= maxBuffer) {\n\t\taddNewChunk(convertedChunk, state, addChunk, newLength);\n\t\treturn;\n\t}\n\n\tconst truncatedChunk = truncateChunk(convertedChunk, maxBuffer - state.length);\n\n\tif (truncatedChunk !== undefined) {\n\t\taddNewChunk(truncatedChunk, state, addChunk, maxBuffer);\n\t}\n\n\tthrow new MaxBufferError();\n};\n\nconst addNewChunk = (convertedChunk, state, addChunk, newLength) => {\n\tstate.contents = addChunk(convertedChunk, state, newLength);\n\tstate.length = newLength;\n};\n\nconst getChunkType = chunk => {\n\tconst typeOfChunk = typeof chunk;\n\n\tif (typeOfChunk === 'string') {\n\t\treturn 'string';\n\t}\n\n\tif (typeOfChunk !== 'object' || chunk === null) {\n\t\treturn 'others';\n\t}\n\n\tif (globalThis.Buffer?.isBuffer(chunk)) {\n\t\treturn 'buffer';\n\t}\n\n\tconst prototypeName = objectToString.call(chunk);\n\n\tif (prototypeName === '[object ArrayBuffer]') {\n\t\treturn 'arrayBuffer';\n\t}\n\n\tif (prototypeName === '[object DataView]') {\n\t\treturn 'dataView';\n\t}\n\n\tif (\n\t\tNumber.isInteger(chunk.byteLength)\n\t\t&& Number.isInteger(chunk.byteOffset)\n\t\t&& objectToString.call(chunk.buffer) === '[object ArrayBuffer]'\n\t) {\n\t\treturn 'typedArray';\n\t}\n\n\treturn 'others';\n};\n\nconst {toString: objectToString} = Object.prototype;\n\nexport class MaxBufferError extends Error {\n\tname = 'MaxBufferError';\n\n\tconstructor() {\n\t\tsuper('maxBuffer exceeded');\n\t}\n}\n","export const identity = value => value;\n\nexport const noop = () => undefined;\n\nexport const getContentsProperty = ({contents}) => contents;\n\nexport const throwObjectStream = chunk => {\n\tthrow new Error(`Streams in object mode are not supported: ${String(chunk)}`);\n};\n\nexport const getLengthProperty = convertedChunk => convertedChunk.length;\n","import {getStreamContents} from './contents.js';\nimport {identity, noop, getContentsProperty} from './utils.js';\n\nexport async function getStreamAsArray(stream, options) {\n\treturn getStreamContents(stream, arrayMethods, options);\n}\n\nconst initArray = () => ({contents: []});\n\nconst increment = () => 1;\n\nconst addArrayChunk = (convertedChunk, {contents}) => {\n\tcontents.push(convertedChunk);\n\treturn contents;\n};\n\nconst arrayMethods = {\n\tinit: initArray,\n\tconvertChunk: {\n\t\tstring: identity,\n\t\tbuffer: identity,\n\t\tarrayBuffer: identity,\n\t\tdataView: identity,\n\t\ttypedArray: identity,\n\t\tothers: identity,\n\t},\n\tgetSize: increment,\n\ttruncateChunk: noop,\n\taddChunk: addArrayChunk,\n\tgetFinalChunk: noop,\n\tfinalize: getContentsProperty,\n};\n","import {getStreamContents} from './contents.js';\nimport {noop, throwObjectStream, getLengthProperty} from './utils.js';\n\nexport async function getStreamAsArrayBuffer(stream, options) {\n\treturn getStreamContents(stream, arrayBufferMethods, options);\n}\n\nconst initArrayBuffer = () => ({contents: new ArrayBuffer(0)});\n\nconst useTextEncoder = chunk => textEncoder.encode(chunk);\nconst textEncoder = new TextEncoder();\n\nconst useUint8Array = chunk => new Uint8Array(chunk);\n\nconst useUint8ArrayWithOffset = chunk => new Uint8Array(chunk.buffer, chunk.byteOffset, chunk.byteLength);\n\nconst truncateArrayBufferChunk = (convertedChunk, chunkSize) => convertedChunk.slice(0, chunkSize);\n\n// `contents` is an increasingly growing `Uint8Array`.\nconst addArrayBufferChunk = (convertedChunk, {contents, length: previousLength}, length) => {\n\tconst newContents = hasArrayBufferResize() ? resizeArrayBuffer(contents, length) : resizeArrayBufferSlow(contents, length);\n\tnew Uint8Array(newContents).set(convertedChunk, previousLength);\n\treturn newContents;\n};\n\n// Without `ArrayBuffer.resize()`, `contents` size is always a power of 2.\n// This means its last bytes are zeroes (not stream data), which need to be\n// trimmed at the end with `ArrayBuffer.slice()`.\nconst resizeArrayBufferSlow = (contents, length) => {\n\tif (length <= contents.byteLength) {\n\t\treturn contents;\n\t}\n\n\tconst arrayBuffer = new ArrayBuffer(getNewContentsLength(length));\n\tnew Uint8Array(arrayBuffer).set(new Uint8Array(contents), 0);\n\treturn arrayBuffer;\n};\n\n// With `ArrayBuffer.resize()`, `contents` size matches exactly the size of\n// the stream data. It does not include extraneous zeroes to trim at the end.\n// The underlying `ArrayBuffer` does allocate a number of bytes that is a power\n// of 2, but those bytes are only visible after calling `ArrayBuffer.resize()`.\nconst resizeArrayBuffer = (contents, length) => {\n\tif (length <= contents.maxByteLength) {\n\t\tcontents.resize(length);\n\t\treturn contents;\n\t}\n\n\tconst arrayBuffer = new ArrayBuffer(length, {maxByteLength: getNewContentsLength(length)});\n\tnew Uint8Array(arrayBuffer).set(new Uint8Array(contents), 0);\n\treturn arrayBuffer;\n};\n\n// Retrieve the closest `length` that is both >= and a power of 2\nconst getNewContentsLength = length => SCALE_FACTOR ** Math.ceil(Math.log(length) / Math.log(SCALE_FACTOR));\n\nconst SCALE_FACTOR = 2;\n\nconst finalizeArrayBuffer = ({contents, length}) => hasArrayBufferResize() ? contents : contents.slice(0, length);\n\n// `ArrayBuffer.slice()` is slow. When `ArrayBuffer.resize()` is available\n// (Node >=20.0.0, Safari >=16.4 and Chrome), we can use it instead.\n// eslint-disable-next-line no-warning-comments\n// TODO: remove after dropping support for Node 20.\n// eslint-disable-next-line no-warning-comments\n// TODO: use `ArrayBuffer.transferToFixedLength()` instead once it is available\nconst hasArrayBufferResize = () => 'resize' in ArrayBuffer.prototype;\n\nconst arrayBufferMethods = {\n\tinit: initArrayBuffer,\n\tconvertChunk: {\n\t\tstring: useTextEncoder,\n\t\tbuffer: useUint8Array,\n\t\tarrayBuffer: useUint8Array,\n\t\tdataView: useUint8ArrayWithOffset,\n\t\ttypedArray: useUint8ArrayWithOffset,\n\t\tothers: throwObjectStream,\n\t},\n\tgetSize: getLengthProperty,\n\ttruncateChunk: truncateArrayBufferChunk,\n\taddChunk: addArrayBufferChunk,\n\tgetFinalChunk: noop,\n\tfinalize: finalizeArrayBuffer,\n};\n","import {getStreamContents} from './contents.js';\nimport {\n\tidentity,\n\tgetContentsProperty,\n\tthrowObjectStream,\n\tgetLengthProperty,\n} from './utils.js';\n\nexport async function getStreamAsString(stream, options) {\n\treturn getStreamContents(stream, stringMethods, options);\n}\n\nconst initString = () => ({contents: '', textDecoder: new TextDecoder()});\n\nconst useTextDecoder = (chunk, {textDecoder}) => textDecoder.decode(chunk, {stream: true});\n\nconst addStringChunk = (convertedChunk, {contents}) => contents + convertedChunk;\n\nconst truncateStringChunk = (convertedChunk, chunkSize) => convertedChunk.slice(0, chunkSize);\n\nconst getFinalStringChunk = ({textDecoder}) => {\n\tconst finalChunk = textDecoder.decode();\n\treturn finalChunk === '' ? undefined : finalChunk;\n};\n\nconst stringMethods = {\n\tinit: initString,\n\tconvertChunk: {\n\t\tstring: identity,\n\t\tbuffer: useTextDecoder,\n\t\tarrayBuffer: useTextDecoder,\n\t\tdataView: useTextDecoder,\n\t\ttypedArray: useTextDecoder,\n\t\tothers: throwObjectStream,\n\t},\n\tgetSize: getLengthProperty,\n\ttruncateChunk: truncateStringChunk,\n\taddChunk: addStringChunk,\n\tgetFinalChunk: getFinalStringChunk,\n\tfinalize: getContentsProperty,\n};\n","import {MaxBufferError} from 'get-stream';\nimport {getStreamName} from '../utils/standard-stream.js';\nimport {getFdSpecificValue} from '../arguments/specific.js';\n\n// When the `maxBuffer` option is hit, a MaxBufferError is thrown.\n// The stream is aborted, then specific information is kept for the error message.\nexport const handleMaxBuffer = ({error, stream, readableObjectMode, lines, encoding, fdNumber}) => {\n\tif (!(error instanceof MaxBufferError)) {\n\t\tthrow error;\n\t}\n\n\tif (fdNumber === 'all') {\n\t\treturn error;\n\t}\n\n\tconst unit = getMaxBufferUnit(readableObjectMode, lines, encoding);\n\terror.maxBufferInfo = {fdNumber, unit};\n\tstream.destroy();\n\tthrow error;\n};\n\nconst getMaxBufferUnit = (readableObjectMode, lines, encoding) => {\n\tif (readableObjectMode) {\n\t\treturn 'objects';\n\t}\n\n\tif (lines) {\n\t\treturn 'lines';\n\t}\n\n\tif (encoding === 'buffer') {\n\t\treturn 'bytes';\n\t}\n\n\treturn 'characters';\n};\n\n// Check the `maxBuffer` option with `result.ipcOutput`\nexport const checkIpcMaxBuffer = (subprocess, ipcOutput, maxBuffer) => {\n\tif (ipcOutput.length !== maxBuffer) {\n\t\treturn;\n\t}\n\n\tconst error = new MaxBufferError();\n\terror.maxBufferInfo = {fdNumber: 'ipc'};\n\tthrow error;\n};\n\n// Error message when `maxBuffer` is hit\nexport const getMaxBufferMessage = (error, maxBuffer) => {\n\tconst {streamName, threshold, unit} = getMaxBufferInfo(error, maxBuffer);\n\treturn `Command's ${streamName} was larger than ${threshold} ${unit}`;\n};\n\nconst getMaxBufferInfo = (error, maxBuffer) => {\n\tif (error?.maxBufferInfo === undefined) {\n\t\treturn {streamName: 'output', threshold: maxBuffer[1], unit: 'bytes'};\n\t}\n\n\tconst {maxBufferInfo: {fdNumber, unit}} = error;\n\tdelete error.maxBufferInfo;\n\n\tconst threshold = getFdSpecificValue(maxBuffer, fdNumber);\n\tif (fdNumber === 'ipc') {\n\t\treturn {streamName: 'IPC output', threshold, unit: 'messages'};\n\t}\n\n\treturn {streamName: getStreamName(fdNumber), threshold, unit};\n};\n\n// The only way to apply `maxBuffer` with `spawnSync()` is to use the native `maxBuffer` option Node.js provides.\n// However, this has multiple limitations, and cannot behave the exact same way as the async behavior.\n// When the `maxBuffer` is hit, a `ENOBUFS` error is thrown.\nexport const isMaxBufferSync = (resultError, output, maxBuffer) => resultError?.code === 'ENOBUFS'\n\t&& output !== null\n\t&& output.some(result => result !== null && result.length > getMaxBufferSync(maxBuffer));\n\n// When `maxBuffer` is hit, ensure the result is truncated\nexport const truncateMaxBufferSync = (result, isMaxBuffer, maxBuffer) => {\n\tif (!isMaxBuffer) {\n\t\treturn result;\n\t}\n\n\tconst maxBufferValue = getMaxBufferSync(maxBuffer);\n\treturn result.length > maxBufferValue ? result.slice(0, maxBufferValue) : result;\n};\n\n// `spawnSync()` does not allow differentiating `maxBuffer` per file descriptor, so we always use `stdout`\nexport const getMaxBufferSync = ([, stdoutMaxBuffer]) => stdoutMaxBuffer;\n","import {inspect} from 'node:util';\nimport stripFinalNewline from 'strip-final-newline';\nimport {isUint8Array, uint8ArrayToString} from '../utils/uint-array.js';\nimport {fixCwdError} from '../arguments/cwd.js';\nimport {escapeLines} from '../arguments/escape.js';\nimport {getMaxBufferMessage} from '../io/max-buffer.js';\nimport {getSignalDescription} from '../terminate/signal.js';\nimport {DiscardedError, isExecaError} from './final-error.js';\n\n// Computes `error.message`, `error.shortMessage` and `error.originalMessage`\nexport const createMessages = ({\n\tstdio,\n\tall,\n\tipcOutput,\n\toriginalError,\n\tsignal,\n\tsignalDescription,\n\texitCode,\n\tescapedCommand,\n\ttimedOut,\n\tisCanceled,\n\tisGracefullyCanceled,\n\tisMaxBuffer,\n\tisForcefullyTerminated,\n\tforceKillAfterDelay,\n\tkillSignal,\n\tmaxBuffer,\n\ttimeout,\n\tcwd,\n}) => {\n\tconst errorCode = originalError?.code;\n\tconst prefix = getErrorPrefix({\n\t\toriginalError,\n\t\ttimedOut,\n\t\ttimeout,\n\t\tisMaxBuffer,\n\t\tmaxBuffer,\n\t\terrorCode,\n\t\tsignal,\n\t\tsignalDescription,\n\t\texitCode,\n\t\tisCanceled,\n\t\tisGracefullyCanceled,\n\t\tisForcefullyTerminated,\n\t\tforceKillAfterDelay,\n\t\tkillSignal,\n\t});\n\tconst originalMessage = getOriginalMessage(originalError, cwd);\n\tconst suffix = originalMessage === undefined ? '' : `\\n${originalMessage}`;\n\tconst shortMessage = `${prefix}: ${escapedCommand}${suffix}`;\n\tconst messageStdio = all === undefined ? [stdio[2], stdio[1]] : [all];\n\tconst message = [\n\t\tshortMessage,\n\t\t...messageStdio,\n\t\t...stdio.slice(3),\n\t\tipcOutput.map(ipcMessage => serializeIpcMessage(ipcMessage)).join('\\n'),\n\t]\n\t\t.map(messagePart => escapeLines(stripFinalNewline(serializeMessagePart(messagePart))))\n\t\t.filter(Boolean)\n\t\t.join('\\n\\n');\n\treturn {originalMessage, shortMessage, message};\n};\n\nconst getErrorPrefix = ({\n\toriginalError,\n\ttimedOut,\n\ttimeout,\n\tisMaxBuffer,\n\tmaxBuffer,\n\terrorCode,\n\tsignal,\n\tsignalDescription,\n\texitCode,\n\tisCanceled,\n\tisGracefullyCanceled,\n\tisForcefullyTerminated,\n\tforceKillAfterDelay,\n\tkillSignal,\n}) => {\n\tconst forcefulSuffix = getForcefulSuffix(isForcefullyTerminated, forceKillAfterDelay);\n\n\tif (timedOut) {\n\t\treturn `Command timed out after ${timeout} milliseconds${forcefulSuffix}`;\n\t}\n\n\tif (isGracefullyCanceled) {\n\t\tif (signal === undefined) {\n\t\t\treturn `Command was gracefully canceled with exit code ${exitCode}`;\n\t\t}\n\n\t\treturn isForcefullyTerminated\n\t\t\t? `Command was gracefully canceled${forcefulSuffix}`\n\t\t\t: `Command was gracefully canceled with ${signal} (${signalDescription})`;\n\t}\n\n\tif (isCanceled) {\n\t\treturn `Command was canceled${forcefulSuffix}`;\n\t}\n\n\tif (isMaxBuffer) {\n\t\treturn `${getMaxBufferMessage(originalError, maxBuffer)}${forcefulSuffix}`;\n\t}\n\n\tif (errorCode !== undefined) {\n\t\treturn `Command failed with ${errorCode}${forcefulSuffix}`;\n\t}\n\n\tif (isForcefullyTerminated) {\n\t\treturn `Command was killed with ${killSignal} (${getSignalDescription(killSignal)})${forcefulSuffix}`;\n\t}\n\n\tif (signal !== undefined) {\n\t\treturn `Command was killed with ${signal} (${signalDescription})`;\n\t}\n\n\tif (exitCode !== undefined) {\n\t\treturn `Command failed with exit code ${exitCode}`;\n\t}\n\n\treturn 'Command failed';\n};\n\nconst getForcefulSuffix = (isForcefullyTerminated, forceKillAfterDelay) => isForcefullyTerminated\n\t? ` and was forcefully terminated after ${forceKillAfterDelay} milliseconds`\n\t: '';\n\nconst getOriginalMessage = (originalError, cwd) => {\n\tif (originalError instanceof DiscardedError) {\n\t\treturn;\n\t}\n\n\tconst originalMessage = isExecaError(originalError)\n\t\t? originalError.originalMessage\n\t\t: String(originalError?.message ?? originalError);\n\tconst escapedOriginalMessage = escapeLines(fixCwdError(originalMessage, cwd));\n\treturn escapedOriginalMessage === '' ? undefined : escapedOriginalMessage;\n};\n\nconst serializeIpcMessage = ipcMessage => typeof ipcMessage === 'string'\n\t? ipcMessage\n\t: inspect(ipcMessage);\n\nconst serializeMessagePart = messagePart => Array.isArray(messagePart)\n\t? messagePart.map(messageItem => stripFinalNewline(serializeMessageItem(messageItem))).filter(Boolean).join('\\n')\n\t: serializeMessageItem(messagePart);\n\nconst serializeMessageItem = messageItem => {\n\tif (typeof messageItem === 'string') {\n\t\treturn messageItem;\n\t}\n\n\tif (isUint8Array(messageItem)) {\n\t\treturn uint8ArrayToString(messageItem);\n\t}\n\n\treturn '';\n};\n","import {getSignalDescription} from '../terminate/signal.js';\nimport {getDurationMs} from './duration.js';\nimport {getFinalError} from './final-error.js';\nimport {createMessages} from './message.js';\n\n// Object returned on subprocess success\nexport const makeSuccessResult = ({\n\tcommand,\n\tescapedCommand,\n\tstdio,\n\tall,\n\tipcOutput,\n\toptions: {cwd},\n\tstartTime,\n}) => omitUndefinedProperties({\n\tcommand,\n\tescapedCommand,\n\tcwd,\n\tdurationMs: getDurationMs(startTime),\n\tfailed: false,\n\ttimedOut: false,\n\tisCanceled: false,\n\tisGracefullyCanceled: false,\n\tisTerminated: false,\n\tisMaxBuffer: false,\n\tisForcefullyTerminated: false,\n\texitCode: 0,\n\tstdout: stdio[1],\n\tstderr: stdio[2],\n\tall,\n\tstdio,\n\tipcOutput,\n\tpipedFrom: [],\n});\n\n// Object returned on subprocess failure before spawning\nexport const makeEarlyError = ({\n\terror,\n\tcommand,\n\tescapedCommand,\n\tfileDescriptors,\n\toptions,\n\tstartTime,\n\tisSync,\n}) => makeError({\n\terror,\n\tcommand,\n\tescapedCommand,\n\tstartTime,\n\ttimedOut: false,\n\tisCanceled: false,\n\tisGracefullyCanceled: false,\n\tisMaxBuffer: false,\n\tisForcefullyTerminated: false,\n\tstdio: Array.from({length: fileDescriptors.length}),\n\tipcOutput: [],\n\toptions,\n\tisSync,\n});\n\n// Object returned on subprocess failure\nexport const makeError = ({\n\terror: originalError,\n\tcommand,\n\tescapedCommand,\n\tstartTime,\n\ttimedOut,\n\tisCanceled,\n\tisGracefullyCanceled,\n\tisMaxBuffer,\n\tisForcefullyTerminated,\n\texitCode: rawExitCode,\n\tsignal: rawSignal,\n\tstdio,\n\tall,\n\tipcOutput,\n\toptions: {\n\t\ttimeoutDuration,\n\t\ttimeout = timeoutDuration,\n\t\tforceKillAfterDelay,\n\t\tkillSignal,\n\t\tcwd,\n\t\tmaxBuffer,\n\t},\n\tisSync,\n}) => {\n\tconst {exitCode, signal, signalDescription} = normalizeExitPayload(rawExitCode, rawSignal);\n\tconst {originalMessage, shortMessage, message} = createMessages({\n\t\tstdio,\n\t\tall,\n\t\tipcOutput,\n\t\toriginalError,\n\t\tsignal,\n\t\tsignalDescription,\n\t\texitCode,\n\t\tescapedCommand,\n\t\ttimedOut,\n\t\tisCanceled,\n\t\tisGracefullyCanceled,\n\t\tisMaxBuffer,\n\t\tisForcefullyTerminated,\n\t\tforceKillAfterDelay,\n\t\tkillSignal,\n\t\tmaxBuffer,\n\t\ttimeout,\n\t\tcwd,\n\t});\n\tconst error = getFinalError(originalError, message, isSync);\n\tObject.assign(error, getErrorProperties({\n\t\terror,\n\t\tcommand,\n\t\tescapedCommand,\n\t\tstartTime,\n\t\ttimedOut,\n\t\tisCanceled,\n\t\tisGracefullyCanceled,\n\t\tisMaxBuffer,\n\t\tisForcefullyTerminated,\n\t\texitCode,\n\t\tsignal,\n\t\tsignalDescription,\n\t\tstdio,\n\t\tall,\n\t\tipcOutput,\n\t\tcwd,\n\t\toriginalMessage,\n\t\tshortMessage,\n\t}));\n\treturn error;\n};\n\nconst getErrorProperties = ({\n\terror,\n\tcommand,\n\tescapedCommand,\n\tstartTime,\n\ttimedOut,\n\tisCanceled,\n\tisGracefullyCanceled,\n\tisMaxBuffer,\n\tisForcefullyTerminated,\n\texitCode,\n\tsignal,\n\tsignalDescription,\n\tstdio,\n\tall,\n\tipcOutput,\n\tcwd,\n\toriginalMessage,\n\tshortMessage,\n}) => omitUndefinedProperties({\n\tshortMessage,\n\toriginalMessage,\n\tcommand,\n\tescapedCommand,\n\tcwd,\n\tdurationMs: getDurationMs(startTime),\n\tfailed: true,\n\ttimedOut,\n\tisCanceled,\n\tisGracefullyCanceled,\n\tisTerminated: signal !== undefined,\n\tisMaxBuffer,\n\tisForcefullyTerminated,\n\texitCode,\n\tsignal,\n\tsignalDescription,\n\tcode: error.cause?.code,\n\tstdout: stdio[1],\n\tstderr: stdio[2],\n\tall,\n\tstdio,\n\tipcOutput,\n\tpipedFrom: [],\n});\n\nconst omitUndefinedProperties = result => Object.fromEntries(Object.entries(result).filter(([, value]) => value !== undefined));\n\n// `signal` and `exitCode` emitted on `subprocess.on('exit')` event can be `null`.\n// We normalize them to `undefined`\nconst normalizeExitPayload = (rawExitCode, rawSignal) => {\n\tconst exitCode = rawExitCode === null ? undefined : rawExitCode;\n\tconst signal = rawSignal === null ? undefined : rawSignal;\n\tconst signalDescription = signal === undefined ? undefined : getSignalDescription(rawSignal);\n\treturn {exitCode, signal, signalDescription};\n};\n","import prettyMs from 'pretty-ms';\nimport {isVerbose} from './values.js';\nimport {verboseLog} from './log.js';\nimport {logError} from './error.js';\n\n// When `verbose` is `short|full|custom`, print each command's completion, duration and error\nexport const logResult = (result, verboseInfo) => {\n\tif (!isVerbose(verboseInfo)) {\n\t\treturn;\n\t}\n\n\tlogError(result, verboseInfo);\n\tlogDuration(result, verboseInfo);\n};\n\nconst logDuration = (result, verboseInfo) => {\n\tconst verboseMessage = `(done in ${prettyMs(result.durationMs)})`;\n\tverboseLog({\n\t\ttype: 'duration',\n\t\tverboseMessage,\n\t\tverboseInfo,\n\t\tresult,\n\t});\n};\n","import {logResult} from '../verbose/complete.js';\n\n// Applies the `reject` option.\n// Also print the final log line with `verbose`.\nexport const handleResult = (result, verboseInfo, {reject}) => {\n\tlogResult(result, verboseInfo);\n\n\tif (result.failed && reject) {\n\t\tthrow result;\n\t}\n\n\treturn result;\n};\n","import {verboseLog} from './log.js';\n\n// When `verbose` is `short|full|custom`, print each command's error when it fails\nexport const logError = (result, verboseInfo) => {\n\tif (result.failed) {\n\t\tverboseLog({\n\t\t\ttype: 'error',\n\t\t\tverboseMessage: result.shortMessage,\n\t\t\tverboseInfo,\n\t\t\tresult,\n\t\t});\n\t}\n};\n","import {isStream as isNodeStream, isDuplexStream} from 'is-stream';\nimport isPlainObj from 'is-plain-obj';\nimport {isUint8Array} from '../utils/uint-array.js';\n\n// The `stdin`/`stdout`/`stderr` option can be of many types. This detects it.\nexport const getStdioItemType = (value, optionName) => {\n\tif (isAsyncGenerator(value)) {\n\t\treturn 'asyncGenerator';\n\t}\n\n\tif (isSyncGenerator(value)) {\n\t\treturn 'generator';\n\t}\n\n\tif (isUrl(value)) {\n\t\treturn 'fileUrl';\n\t}\n\n\tif (isFilePathObject(value)) {\n\t\treturn 'filePath';\n\t}\n\n\tif (isWebStream(value)) {\n\t\treturn 'webStream';\n\t}\n\n\tif (isNodeStream(value, {checkOpen: false})) {\n\t\treturn 'native';\n\t}\n\n\tif (isUint8Array(value)) {\n\t\treturn 'uint8Array';\n\t}\n\n\tif (isAsyncIterableObject(value)) {\n\t\treturn 'asyncIterable';\n\t}\n\n\tif (isIterableObject(value)) {\n\t\treturn 'iterable';\n\t}\n\n\tif (isTransformStream(value)) {\n\t\treturn getTransformStreamType({transform: value}, optionName);\n\t}\n\n\tif (isTransformOptions(value)) {\n\t\treturn getTransformObjectType(value, optionName);\n\t}\n\n\treturn 'native';\n};\n\nconst getTransformObjectType = (value, optionName) => {\n\tif (isDuplexStream(value.transform, {checkOpen: false})) {\n\t\treturn getDuplexType(value, optionName);\n\t}\n\n\tif (isTransformStream(value.transform)) {\n\t\treturn getTransformStreamType(value, optionName);\n\t}\n\n\treturn getGeneratorObjectType(value, optionName);\n};\n\nconst getDuplexType = (value, optionName) => {\n\tvalidateNonGeneratorType(value, optionName, 'Duplex stream');\n\treturn 'duplex';\n};\n\nconst getTransformStreamType = (value, optionName) => {\n\tvalidateNonGeneratorType(value, optionName, 'web TransformStream');\n\treturn 'webTransform';\n};\n\nconst validateNonGeneratorType = ({final, binary, objectMode}, optionName, typeName) => {\n\tcheckUndefinedOption(final, `${optionName}.final`, typeName);\n\tcheckUndefinedOption(binary, `${optionName}.binary`, typeName);\n\tcheckBooleanOption(objectMode, `${optionName}.objectMode`);\n};\n\nconst checkUndefinedOption = (value, optionName, typeName) => {\n\tif (value !== undefined) {\n\t\tthrow new TypeError(`The \\`${optionName}\\` option can only be defined when using a generator, not a ${typeName}.`);\n\t}\n};\n\nconst getGeneratorObjectType = ({transform, final, binary, objectMode}, optionName) => {\n\tif (transform !== undefined && !isGenerator(transform)) {\n\t\tthrow new TypeError(`The \\`${optionName}.transform\\` option must be a generator, a Duplex stream or a web TransformStream.`);\n\t}\n\n\tif (isDuplexStream(final, {checkOpen: false})) {\n\t\tthrow new TypeError(`The \\`${optionName}.final\\` option must not be a Duplex stream.`);\n\t}\n\n\tif (isTransformStream(final)) {\n\t\tthrow new TypeError(`The \\`${optionName}.final\\` option must not be a web TransformStream.`);\n\t}\n\n\tif (final !== undefined && !isGenerator(final)) {\n\t\tthrow new TypeError(`The \\`${optionName}.final\\` option must be a generator.`);\n\t}\n\n\tcheckBooleanOption(binary, `${optionName}.binary`);\n\tcheckBooleanOption(objectMode, `${optionName}.objectMode`);\n\n\treturn isAsyncGenerator(transform) || isAsyncGenerator(final) ? 'asyncGenerator' : 'generator';\n};\n\nconst checkBooleanOption = (value, optionName) => {\n\tif (value !== undefined && typeof value !== 'boolean') {\n\t\tthrow new TypeError(`The \\`${optionName}\\` option must use a boolean.`);\n\t}\n};\n\nconst isGenerator = value => isAsyncGenerator(value) || isSyncGenerator(value);\nexport const isAsyncGenerator = value => Object.prototype.toString.call(value) === '[object AsyncGeneratorFunction]';\nconst isSyncGenerator = value => Object.prototype.toString.call(value) === '[object GeneratorFunction]';\nconst isTransformOptions = value => isPlainObj(value)\n\t&& (value.transform !== undefined || value.final !== undefined);\n\nexport const isUrl = value => Object.prototype.toString.call(value) === '[object URL]';\nexport const isRegularUrl = value => isUrl(value) && value.protocol !== 'file:';\n\nconst isFilePathObject = value => isPlainObj(value)\n\t&& Object.keys(value).length === 1\n\t&& isFilePathString(value.file);\nexport const isFilePathString = file => typeof file === 'string';\n\nexport const isUnknownStdioString = (type, value) => type === 'native'\n\t&& typeof value === 'string'\n\t&& !KNOWN_STDIO_STRINGS.has(value);\nconst KNOWN_STDIO_STRINGS = new Set(['ipc', 'ignore', 'inherit', 'overlapped', 'pipe']);\n\nconst isReadableStream = value => Object.prototype.toString.call(value) === '[object ReadableStream]';\nexport const isWritableStream = value => Object.prototype.toString.call(value) === '[object WritableStream]';\nconst isWebStream = value => isReadableStream(value) || isWritableStream(value);\nconst isTransformStream = value => isReadableStream(value?.readable) && isWritableStream(value?.writable);\n\nconst isAsyncIterableObject = value => isObject(value) && typeof value[Symbol.asyncIterator] === 'function';\nconst isIterableObject = value => isObject(value) && typeof value[Symbol.iterator] === 'function';\nconst isObject = value => typeof value === 'object' && value !== null;\n\n// Types which modify `subprocess.std*`\nexport const TRANSFORM_TYPES = new Set(['generator', 'asyncGenerator', 'duplex', 'webTransform']);\n// Types which write to a file or a file descriptor\nexport const FILE_TYPES = new Set(['fileUrl', 'filePath', 'fileNumber']);\n// When two file descriptors of this type share the same target, we need to do some special logic\nexport const SPECIAL_DUPLICATE_TYPES_SYNC = new Set(['fileUrl', 'filePath']);\nexport const SPECIAL_DUPLICATE_TYPES = new Set([...SPECIAL_DUPLICATE_TYPES_SYNC, 'webStream', 'nodeStream']);\n// Do not allow two file descriptors of this type sharing the same target\nexport const FORBID_DUPLICATE_TYPES = new Set(['webTransform', 'duplex']);\n\n// Convert types to human-friendly strings for error messages\nexport const TYPE_TO_MESSAGE = {\n\tgenerator: 'a generator',\n\tasyncGenerator: 'an async generator',\n\tfileUrl: 'a file URL',\n\tfilePath: 'a file path string',\n\tfileNumber: 'a file descriptor number',\n\twebStream: 'a web stream',\n\tnodeStream: 'a Node.js stream',\n\twebTransform: 'a web TransformStream',\n\tduplex: 'a Duplex stream',\n\tnative: 'any value',\n\titerable: 'an iterable',\n\tasyncIterable: 'an async iterable',\n\tstring: 'a string',\n\tuint8Array: 'a Uint8Array',\n};\n","import {TRANSFORM_TYPES} from '../stdio/type.js';\n\n/*\nRetrieve the `objectMode`s of a single transform.\n`objectMode` determines the return value's type, i.e. the `readableObjectMode`.\nThe chunk argument's type is based on the previous generator's return value, i.e. the `writableObjectMode` is based on the previous `readableObjectMode`.\nThe last input's generator is read by `subprocess.stdin` which:\n- should not be in `objectMode` for performance reasons.\n- can only be strings, Buffers and Uint8Arrays.\nTherefore its `readableObjectMode` must be `false`.\nThe same applies to the first output's generator's `writableObjectMode`.\n*/\nexport const getTransformObjectModes = (objectMode, index, newTransforms, direction) => direction === 'output'\n\t? getOutputObjectModes(objectMode, index, newTransforms)\n\t: getInputObjectModes(objectMode, index, newTransforms);\n\nconst getOutputObjectModes = (objectMode, index, newTransforms) => {\n\tconst writableObjectMode = index !== 0 && newTransforms[index - 1].value.readableObjectMode;\n\tconst readableObjectMode = objectMode ?? writableObjectMode;\n\treturn {writableObjectMode, readableObjectMode};\n};\n\nconst getInputObjectModes = (objectMode, index, newTransforms) => {\n\tconst writableObjectMode = index === 0\n\t\t? objectMode === true\n\t\t: newTransforms[index - 1].value.readableObjectMode;\n\tconst readableObjectMode = index !== newTransforms.length - 1 && (objectMode ?? writableObjectMode);\n\treturn {writableObjectMode, readableObjectMode};\n};\n\n// Retrieve the `objectMode` of a file descriptor, e.g. `stdout` or `stderr`\nexport const getFdObjectMode = (stdioItems, direction) => {\n\tconst lastTransform = stdioItems.findLast(({type}) => TRANSFORM_TYPES.has(type));\n\tif (lastTransform === undefined) {\n\t\treturn false;\n\t}\n\n\treturn direction === 'input'\n\t\t? lastTransform.value.writableObjectMode\n\t\t: lastTransform.value.readableObjectMode;\n};\n","import isPlainObj from 'is-plain-obj';\nimport {BINARY_ENCODINGS} from '../arguments/encoding-option.js';\nimport {TRANSFORM_TYPES} from '../stdio/type.js';\nimport {getTransformObjectModes} from './object-mode.js';\n\n// Transforms generators/duplex/TransformStream can have multiple shapes.\n// This normalizes it and applies default values.\nexport const normalizeTransforms = (stdioItems, optionName, direction, options) => [\n\t...stdioItems.filter(({type}) => !TRANSFORM_TYPES.has(type)),\n\t...getTransforms(stdioItems, optionName, direction, options),\n];\n\nconst getTransforms = (stdioItems, optionName, direction, {encoding}) => {\n\tconst transforms = stdioItems.filter(({type}) => TRANSFORM_TYPES.has(type));\n\tconst newTransforms = Array.from({length: transforms.length});\n\n\tfor (const [index, stdioItem] of Object.entries(transforms)) {\n\t\tnewTransforms[index] = normalizeTransform({\n\t\t\tstdioItem,\n\t\t\tindex: Number(index),\n\t\t\tnewTransforms,\n\t\t\toptionName,\n\t\t\tdirection,\n\t\t\tencoding,\n\t\t});\n\t}\n\n\treturn sortTransforms(newTransforms, direction);\n};\n\nconst normalizeTransform = ({stdioItem, stdioItem: {type}, index, newTransforms, optionName, direction, encoding}) => {\n\tif (type === 'duplex') {\n\t\treturn normalizeDuplex({stdioItem, optionName});\n\t}\n\n\tif (type === 'webTransform') {\n\t\treturn normalizeTransformStream({\n\t\t\tstdioItem,\n\t\t\tindex,\n\t\t\tnewTransforms,\n\t\t\tdirection,\n\t\t});\n\t}\n\n\treturn normalizeGenerator({\n\t\tstdioItem,\n\t\tindex,\n\t\tnewTransforms,\n\t\tdirection,\n\t\tencoding,\n\t});\n};\n\nconst normalizeDuplex = ({\n\tstdioItem,\n\tstdioItem: {\n\t\tvalue: {\n\t\t\ttransform,\n\t\t\ttransform: {writableObjectMode, readableObjectMode},\n\t\t\tobjectMode = readableObjectMode,\n\t\t},\n\t},\n\toptionName,\n}) => {\n\tif (objectMode && !readableObjectMode) {\n\t\tthrow new TypeError(`The \\`${optionName}.objectMode\\` option can only be \\`true\\` if \\`new Duplex({objectMode: true})\\` is used.`);\n\t}\n\n\tif (!objectMode && readableObjectMode) {\n\t\tthrow new TypeError(`The \\`${optionName}.objectMode\\` option cannot be \\`false\\` if \\`new Duplex({objectMode: true})\\` is used.`);\n\t}\n\n\treturn {\n\t\t...stdioItem,\n\t\tvalue: {transform, writableObjectMode, readableObjectMode},\n\t};\n};\n\nconst normalizeTransformStream = ({stdioItem, stdioItem: {value}, index, newTransforms, direction}) => {\n\tconst {transform, objectMode} = isPlainObj(value) ? value : {transform: value};\n\tconst {writableObjectMode, readableObjectMode} = getTransformObjectModes(objectMode, index, newTransforms, direction);\n\treturn ({\n\t\t...stdioItem,\n\t\tvalue: {transform, writableObjectMode, readableObjectMode},\n\t});\n};\n\nconst normalizeGenerator = ({stdioItem, stdioItem: {value}, index, newTransforms, direction, encoding}) => {\n\tconst {\n\t\ttransform,\n\t\tfinal,\n\t\tbinary: binaryOption = false,\n\t\tpreserveNewlines = false,\n\t\tobjectMode,\n\t} = isPlainObj(value) ? value : {transform: value};\n\tconst binary = binaryOption || BINARY_ENCODINGS.has(encoding);\n\tconst {writableObjectMode, readableObjectMode} = getTransformObjectModes(objectMode, index, newTransforms, direction);\n\treturn {\n\t\t...stdioItem,\n\t\tvalue: {\n\t\t\ttransform,\n\t\t\tfinal,\n\t\t\tbinary,\n\t\t\tpreserveNewlines,\n\t\t\twritableObjectMode,\n\t\t\treadableObjectMode,\n\t\t},\n\t};\n};\n\nconst sortTransforms = (newTransforms, direction) => direction === 'input' ? newTransforms.reverse() : newTransforms;\n","import process from 'node:process';\nimport {\n\tisStream as isNodeStream,\n\tisReadableStream as isNodeReadableStream,\n\tisWritableStream as isNodeWritableStream,\n} from 'is-stream';\nimport {isWritableStream} from './type.js';\n\n// For `stdio[fdNumber]` beyond stdin/stdout/stderr, we need to guess whether the value passed is intended for inputs or outputs.\n// This allows us to know whether to pipe _into_ or _from_ the stream.\n// When `stdio[fdNumber]` is a single value, this guess is fairly straightforward.\n// However, when it is an array instead, we also need to make sure the different values are not incompatible with each other.\nexport const getStreamDirection = (stdioItems, fdNumber, optionName) => {\n\tconst directions = stdioItems.map(stdioItem => getStdioItemDirection(stdioItem, fdNumber));\n\n\tif (directions.includes('input') && directions.includes('output')) {\n\t\tthrow new TypeError(`The \\`${optionName}\\` option must not be an array of both readable and writable values.`);\n\t}\n\n\treturn directions.find(Boolean) ?? DEFAULT_DIRECTION;\n};\n\nconst getStdioItemDirection = ({type, value}, fdNumber) => KNOWN_DIRECTIONS[fdNumber] ?? guessStreamDirection[type](value);\n\n// `stdin`/`stdout`/`stderr` have a known direction\nconst KNOWN_DIRECTIONS = ['input', 'output', 'output'];\n\nconst anyDirection = () => undefined;\nconst alwaysInput = () => 'input';\n\n// `string` can only be added through the `input` option, i.e. does not need to be handled here\nconst guessStreamDirection = {\n\tgenerator: anyDirection,\n\tasyncGenerator: anyDirection,\n\tfileUrl: anyDirection,\n\tfilePath: anyDirection,\n\titerable: alwaysInput,\n\tasyncIterable: alwaysInput,\n\tuint8Array: alwaysInput,\n\twebStream: value => isWritableStream(value) ? 'output' : 'input',\n\tnodeStream(value) {\n\t\tif (!isNodeReadableStream(value, {checkOpen: false})) {\n\t\t\treturn 'output';\n\t\t}\n\n\t\treturn isNodeWritableStream(value, {checkOpen: false}) ? undefined : 'input';\n\t},\n\twebTransform: anyDirection,\n\tduplex: anyDirection,\n\tnative(value) {\n\t\tconst standardStreamDirection = getStandardStreamDirection(value);\n\t\tif (standardStreamDirection !== undefined) {\n\t\t\treturn standardStreamDirection;\n\t\t}\n\n\t\tif (isNodeStream(value, {checkOpen: false})) {\n\t\t\treturn guessStreamDirection.nodeStream(value);\n\t\t}\n\t},\n};\n\nconst getStandardStreamDirection = value => {\n\tif ([0, process.stdin].includes(value)) {\n\t\treturn 'input';\n\t}\n\n\tif ([1, 2, process.stdout, process.stderr].includes(value)) {\n\t\treturn 'output';\n\t}\n};\n\n// When ambiguous, we initially keep the direction as `undefined`.\n// This allows arrays of `stdio` values to resolve the ambiguity.\n// For example, `stdio[3]: DuplexStream` is ambiguous, but `stdio[3]: [DuplexStream, WritableStream]` is not.\n// When the ambiguity remains, we default to `output` since it is the most common use case for additional file descriptors.\nconst DEFAULT_DIRECTION = 'output';\n","import {STANDARD_STREAMS_ALIASES} from '../utils/standard-stream.js';\nimport {normalizeIpcStdioArray} from '../ipc/array.js';\nimport {isFullVerbose} from '../verbose/values.js';\n\n// Add support for `stdin`/`stdout`/`stderr` as an alias for `stdio`.\n// Also normalize the `stdio` option.\nexport const normalizeStdioOption = ({stdio, ipc, buffer, ...options}, verboseInfo, isSync) => {\n\tconst stdioArray = getStdioArray(stdio, options).map((stdioOption, fdNumber) => addDefaultValue(stdioOption, fdNumber));\n\treturn isSync\n\t\t? normalizeStdioSync(stdioArray, buffer, verboseInfo)\n\t\t: normalizeIpcStdioArray(stdioArray, ipc);\n};\n\nconst getStdioArray = (stdio, options) => {\n\tif (stdio === undefined) {\n\t\treturn STANDARD_STREAMS_ALIASES.map(alias => options[alias]);\n\t}\n\n\tif (hasAlias(options)) {\n\t\tthrow new Error(`It's not possible to provide \\`stdio\\` in combination with one of ${STANDARD_STREAMS_ALIASES.map(alias => `\\`${alias}\\``).join(', ')}`);\n\t}\n\n\tif (typeof stdio === 'string') {\n\t\treturn [stdio, stdio, stdio];\n\t}\n\n\tif (!Array.isArray(stdio)) {\n\t\tthrow new TypeError(`Expected \\`stdio\\` to be of type \\`string\\` or \\`Array\\`, got \\`${typeof stdio}\\``);\n\t}\n\n\tconst length = Math.max(stdio.length, STANDARD_STREAMS_ALIASES.length);\n\treturn Array.from({length}, (_, fdNumber) => stdio[fdNumber]);\n};\n\nconst hasAlias = options => STANDARD_STREAMS_ALIASES.some(alias => options[alias] !== undefined);\n\nconst addDefaultValue = (stdioOption, fdNumber) => {\n\tif (Array.isArray(stdioOption)) {\n\t\treturn stdioOption.map(item => addDefaultValue(item, fdNumber));\n\t}\n\n\tif (stdioOption === null || stdioOption === undefined) {\n\t\treturn fdNumber >= STANDARD_STREAMS_ALIASES.length ? 'ignore' : 'pipe';\n\t}\n\n\treturn stdioOption;\n};\n\n// Using `buffer: false` with synchronous methods implies `stdout`/`stderr`: `ignore`.\n// Unless the output is needed, e.g. due to `verbose: 'full'` or to redirecting to a file.\nconst normalizeStdioSync = (stdioArray, buffer, verboseInfo) => stdioArray.map((stdioOption, fdNumber) =>\n\t!buffer[fdNumber]\n\t&& fdNumber !== 0\n\t&& !isFullVerbose(verboseInfo, fdNumber)\n\t&& isOutputPipeOnly(stdioOption)\n\t\t? 'ignore'\n\t\t: stdioOption);\n\nconst isOutputPipeOnly = stdioOption => stdioOption === 'pipe'\n\t|| (Array.isArray(stdioOption) && stdioOption.every(item => item === 'pipe'));\n","import {readFileSync} from 'node:fs';\nimport tty from 'node:tty';\nimport {isStream as isNodeStream} from 'is-stream';\nimport {STANDARD_STREAMS} from '../utils/standard-stream.js';\nimport {bufferToUint8Array} from '../utils/uint-array.js';\nimport {serializeOptionValue} from '../arguments/fd-options.js';\n\n// When we use multiple `stdio` values for the same streams, we pass 'pipe' to `child_process.spawn()`.\n// We then emulate the piping done by core Node.js.\n// To do so, we transform the following values:\n// - Node.js streams are marked as `type: nodeStream`\n// - 'inherit' becomes `process.stdin|stdout|stderr`\n// - any file descriptor integer becomes `process.stdio[fdNumber]`\n// All of the above transformations tell Execa to perform manual piping.\nexport const handleNativeStream = ({stdioItem, stdioItem: {type}, isStdioArray, fdNumber, direction, isSync}) => {\n\tif (!isStdioArray || type !== 'native') {\n\t\treturn stdioItem;\n\t}\n\n\treturn isSync\n\t\t? handleNativeStreamSync({stdioItem, fdNumber, direction})\n\t\t: handleNativeStreamAsync({stdioItem, fdNumber});\n};\n\n// Synchronous methods use a different logic.\n// 'inherit', file descriptors and process.std* are handled by readFileSync()/writeFileSync().\nconst handleNativeStreamSync = ({stdioItem, stdioItem: {value, optionName}, fdNumber, direction}) => {\n\tconst targetFd = getTargetFd({\n\t\tvalue,\n\t\toptionName,\n\t\tfdNumber,\n\t\tdirection,\n\t});\n\tif (targetFd !== undefined) {\n\t\treturn targetFd;\n\t}\n\n\tif (isNodeStream(value, {checkOpen: false})) {\n\t\tthrow new TypeError(`The \\`${optionName}: Stream\\` option cannot both be an array and include a stream with synchronous methods.`);\n\t}\n\n\treturn stdioItem;\n};\n\nconst getTargetFd = ({value, optionName, fdNumber, direction}) => {\n\tconst targetFdNumber = getTargetFdNumber(value, fdNumber);\n\tif (targetFdNumber === undefined) {\n\t\treturn;\n\t}\n\n\tif (direction === 'output') {\n\t\treturn {type: 'fileNumber', value: targetFdNumber, optionName};\n\t}\n\n\tif (tty.isatty(targetFdNumber)) {\n\t\tthrow new TypeError(`The \\`${optionName}: ${serializeOptionValue(value)}\\` option is invalid: it cannot be a TTY with synchronous methods.`);\n\t}\n\n\treturn {type: 'uint8Array', value: bufferToUint8Array(readFileSync(targetFdNumber)), optionName};\n};\n\nconst getTargetFdNumber = (value, fdNumber) => {\n\tif (value === 'inherit') {\n\t\treturn fdNumber;\n\t}\n\n\tif (typeof value === 'number') {\n\t\treturn value;\n\t}\n\n\tconst standardStreamIndex = STANDARD_STREAMS.indexOf(value);\n\tif (standardStreamIndex !== -1) {\n\t\treturn standardStreamIndex;\n\t}\n};\n\nconst handleNativeStreamAsync = ({stdioItem, stdioItem: {value, optionName}, fdNumber}) => {\n\tif (value === 'inherit') {\n\t\treturn {type: 'nodeStream', value: getStandardStream(fdNumber, value, optionName), optionName};\n\t}\n\n\tif (typeof value === 'number') {\n\t\treturn {type: 'nodeStream', value: getStandardStream(value, value, optionName), optionName};\n\t}\n\n\tif (isNodeStream(value, {checkOpen: false})) {\n\t\treturn {type: 'nodeStream', value, optionName};\n\t}\n\n\treturn stdioItem;\n};\n\n// Node.js does not allow to easily retrieve file descriptors beyond stdin/stdout/stderr as streams.\n// - `fs.createReadStream()`/`fs.createWriteStream()` with the `fd` option do not work with character devices that use blocking reads/writes (such as interactive TTYs).\n// - Using a TCP `Socket` would work but be rather complex to implement.\n// Since this is an edge case, we simply throw an error message.\n// See https://github.com/sindresorhus/execa/pull/643#discussion_r1435905707\nconst getStandardStream = (fdNumber, value, optionName) => {\n\tconst standardStream = STANDARD_STREAMS[fdNumber];\n\n\tif (standardStream === undefined) {\n\t\tthrow new TypeError(`The \\`${optionName}: ${value}\\` option is invalid: no such standard stream.`);\n\t}\n\n\treturn standardStream;\n};\n","import {isReadableStream} from 'is-stream';\nimport {isUint8Array} from '../utils/uint-array.js';\nimport {isUrl, isFilePathString} from './type.js';\n\n// Append the `stdin` option with the `input` and `inputFile` options\nexport const handleInputOptions = ({input, inputFile}, fdNumber) => fdNumber === 0\n\t? [\n\t\t...handleInputOption(input),\n\t\t...handleInputFileOption(inputFile),\n\t]\n\t: [];\n\nconst handleInputOption = input => input === undefined ? [] : [{\n\ttype: getInputType(input),\n\tvalue: input,\n\toptionName: 'input',\n}];\n\nconst getInputType = input => {\n\tif (isReadableStream(input, {checkOpen: false})) {\n\t\treturn 'nodeStream';\n\t}\n\n\tif (typeof input === 'string') {\n\t\treturn 'string';\n\t}\n\n\tif (isUint8Array(input)) {\n\t\treturn 'uint8Array';\n\t}\n\n\tthrow new Error('The `input` option must be a string, a Uint8Array or a Node.js Readable stream.');\n};\n\nconst handleInputFileOption = inputFile => inputFile === undefined ? [] : [{\n\t...getInputFileType(inputFile),\n\toptionName: 'inputFile',\n}];\n\nconst getInputFileType = inputFile => {\n\tif (isUrl(inputFile)) {\n\t\treturn {type: 'fileUrl', value: inputFile};\n\t}\n\n\tif (isFilePathString(inputFile)) {\n\t\treturn {type: 'filePath', value: {file: inputFile}};\n\t}\n\n\tthrow new Error('The `inputFile` option must be a file path string or a file URL.');\n};\n","import {\n\tSPECIAL_DUPLICATE_TYPES_SYNC,\n\tSPECIAL_DUPLICATE_TYPES,\n\tFORBID_DUPLICATE_TYPES,\n\tTYPE_TO_MESSAGE,\n} from './type.js';\n\n// Duplicates in the same file descriptor is most likely an error.\n// However, this can be useful with generators.\nexport const filterDuplicates = stdioItems => stdioItems.filter((stdioItemOne, indexOne) =>\n\tstdioItems.every((stdioItemTwo, indexTwo) => stdioItemOne.value !== stdioItemTwo.value\n\t\t|| indexOne >= indexTwo\n\t\t|| stdioItemOne.type === 'generator'\n\t\t|| stdioItemOne.type === 'asyncGenerator'));\n\n// Check if two file descriptors are sharing the same target.\n// For example `{stdout: {file: './output.txt'}, stderr: {file: './output.txt'}}`.\nexport const getDuplicateStream = ({stdioItem: {type, value, optionName}, direction, fileDescriptors, isSync}) => {\n\tconst otherStdioItems = getOtherStdioItems(fileDescriptors, type);\n\tif (otherStdioItems.length === 0) {\n\t\treturn;\n\t}\n\n\tif (isSync) {\n\t\tvalidateDuplicateStreamSync({\n\t\t\totherStdioItems,\n\t\t\ttype,\n\t\t\tvalue,\n\t\t\toptionName,\n\t\t\tdirection,\n\t\t});\n\t\treturn;\n\t}\n\n\tif (SPECIAL_DUPLICATE_TYPES.has(type)) {\n\t\treturn getDuplicateStreamInstance({\n\t\t\totherStdioItems,\n\t\t\ttype,\n\t\t\tvalue,\n\t\t\toptionName,\n\t\t\tdirection,\n\t\t});\n\t}\n\n\tif (FORBID_DUPLICATE_TYPES.has(type)) {\n\t\tvalidateDuplicateTransform({\n\t\t\totherStdioItems,\n\t\t\ttype,\n\t\t\tvalue,\n\t\t\toptionName,\n\t\t});\n\t}\n};\n\n// Values shared by multiple file descriptors\nconst getOtherStdioItems = (fileDescriptors, type) => fileDescriptors\n\t.flatMap(({direction, stdioItems}) => stdioItems\n\t\t.filter(stdioItem => stdioItem.type === type)\n\t\t.map((stdioItem => ({...stdioItem, direction}))));\n\n// With `execaSync()`, do not allow setting a file path both in input and output\nconst validateDuplicateStreamSync = ({otherStdioItems, type, value, optionName, direction}) => {\n\tif (SPECIAL_DUPLICATE_TYPES_SYNC.has(type)) {\n\t\tgetDuplicateStreamInstance({\n\t\t\totherStdioItems,\n\t\t\ttype,\n\t\t\tvalue,\n\t\t\toptionName,\n\t\t\tdirection,\n\t\t});\n\t}\n};\n\n// When two file descriptors share the file or stream, we need to re-use the same underlying stream.\n// Otherwise, the stream would be closed twice when piping ends.\n// This is only an issue with output file descriptors.\n// This is not a problem with generator functions since those create a new instance for each file descriptor.\n// We also forbid input and output file descriptors sharing the same file or stream, since that does not make sense.\nconst getDuplicateStreamInstance = ({otherStdioItems, type, value, optionName, direction}) => {\n\tconst duplicateStdioItems = otherStdioItems.filter(stdioItem => hasSameValue(stdioItem, value));\n\tif (duplicateStdioItems.length === 0) {\n\t\treturn;\n\t}\n\n\tconst differentStdioItem = duplicateStdioItems.find(stdioItem => stdioItem.direction !== direction);\n\tthrowOnDuplicateStream(differentStdioItem, optionName, type);\n\n\treturn direction === 'output' ? duplicateStdioItems[0].stream : undefined;\n};\n\nconst hasSameValue = ({type, value}, secondValue) => {\n\tif (type === 'filePath') {\n\t\treturn value.file === secondValue.file;\n\t}\n\n\tif (type === 'fileUrl') {\n\t\treturn value.href === secondValue.href;\n\t}\n\n\treturn value === secondValue;\n};\n\n// We do not allow two file descriptors to share the same Duplex or TransformStream.\n// This is because those are set directly to `subprocess.std*`.\n// For example, this could result in `subprocess.stdout` and `subprocess.stderr` being the same value.\n// This means reading from either would get data from both stdout and stderr.\nconst validateDuplicateTransform = ({otherStdioItems, type, value, optionName}) => {\n\tconst duplicateStdioItem = otherStdioItems.find(({value: {transform}}) => transform === value.transform);\n\tthrowOnDuplicateStream(duplicateStdioItem, optionName, type);\n};\n\nconst throwOnDuplicateStream = (stdioItem, optionName, type) => {\n\tif (stdioItem !== undefined) {\n\t\tthrow new TypeError(`The \\`${stdioItem.optionName}\\` and \\`${optionName}\\` options must not target ${TYPE_TO_MESSAGE[type]} that is the same.`);\n\t}\n};\n","import {getStreamName, isStandardStream} from '../utils/standard-stream.js';\nimport {normalizeTransforms} from '../transform/normalize.js';\nimport {getFdObjectMode} from '../transform/object-mode.js';\nimport {\n\tgetStdioItemType,\n\tisRegularUrl,\n\tisUnknownStdioString,\n\tFILE_TYPES,\n} from './type.js';\nimport {getStreamDirection} from './direction.js';\nimport {normalizeStdioOption} from './stdio-option.js';\nimport {handleNativeStream} from './native.js';\nimport {handleInputOptions} from './input-option.js';\nimport {filterDuplicates, getDuplicateStream} from './duplicate.js';\n\n// Handle `input`, `inputFile`, `stdin`, `stdout` and `stderr` options, before spawning, in async/sync mode\n// They are converted into an array of `fileDescriptors`.\n// Each `fileDescriptor` is normalized, validated and contains all information necessary for further handling.\nexport const handleStdio = (addProperties, options, verboseInfo, isSync) => {\n\tconst stdio = normalizeStdioOption(options, verboseInfo, isSync);\n\tconst initialFileDescriptors = stdio.map((stdioOption, fdNumber) => getFileDescriptor({\n\t\tstdioOption,\n\t\tfdNumber,\n\t\toptions,\n\t\tisSync,\n\t}));\n\tconst fileDescriptors = getFinalFileDescriptors({\n\t\tinitialFileDescriptors,\n\t\taddProperties,\n\t\toptions,\n\t\tisSync,\n\t});\n\toptions.stdio = fileDescriptors.map(({stdioItems}) => forwardStdio(stdioItems));\n\treturn fileDescriptors;\n};\n\nconst getFileDescriptor = ({stdioOption, fdNumber, options, isSync}) => {\n\tconst optionName = getStreamName(fdNumber);\n\tconst {stdioItems: initialStdioItems, isStdioArray} = initializeStdioItems({\n\t\tstdioOption,\n\t\tfdNumber,\n\t\toptions,\n\t\toptionName,\n\t});\n\tconst direction = getStreamDirection(initialStdioItems, fdNumber, optionName);\n\tconst stdioItems = initialStdioItems.map(stdioItem => handleNativeStream({\n\t\tstdioItem,\n\t\tisStdioArray,\n\t\tfdNumber,\n\t\tdirection,\n\t\tisSync,\n\t}));\n\tconst normalizedStdioItems = normalizeTransforms(stdioItems, optionName, direction, options);\n\tconst objectMode = getFdObjectMode(normalizedStdioItems, direction);\n\tvalidateFileObjectMode(normalizedStdioItems, objectMode);\n\treturn {direction, objectMode, stdioItems: normalizedStdioItems};\n};\n\n// We make sure passing an array with a single item behaves the same as passing that item without an array.\n// This is what users would expect.\n// For example, `stdout: ['ignore']` behaves the same as `stdout: 'ignore'`.\nconst initializeStdioItems = ({stdioOption, fdNumber, options, optionName}) => {\n\tconst values = Array.isArray(stdioOption) ? stdioOption : [stdioOption];\n\tconst initialStdioItems = [\n\t\t...values.map(value => initializeStdioItem(value, optionName)),\n\t\t...handleInputOptions(options, fdNumber),\n\t];\n\n\tconst stdioItems = filterDuplicates(initialStdioItems);\n\tconst isStdioArray = stdioItems.length > 1;\n\tvalidateStdioArray(stdioItems, isStdioArray, optionName);\n\tvalidateStreams(stdioItems);\n\treturn {stdioItems, isStdioArray};\n};\n\nconst initializeStdioItem = (value, optionName) => ({\n\ttype: getStdioItemType(value, optionName),\n\tvalue,\n\toptionName,\n});\n\nconst validateStdioArray = (stdioItems, isStdioArray, optionName) => {\n\tif (stdioItems.length === 0) {\n\t\tthrow new TypeError(`The \\`${optionName}\\` option must not be an empty array.`);\n\t}\n\n\tif (!isStdioArray) {\n\t\treturn;\n\t}\n\n\tfor (const {value, optionName} of stdioItems) {\n\t\tif (INVALID_STDIO_ARRAY_OPTIONS.has(value)) {\n\t\t\tthrow new Error(`The \\`${optionName}\\` option must not include \\`${value}\\`.`);\n\t\t}\n\t}\n};\n\n// Using those `stdio` values together with others for the same stream does not make sense, so we make it fail.\n// However, we do allow it if the array has a single item.\nconst INVALID_STDIO_ARRAY_OPTIONS = new Set(['ignore', 'ipc']);\n\nconst validateStreams = stdioItems => {\n\tfor (const stdioItem of stdioItems) {\n\t\tvalidateFileStdio(stdioItem);\n\t}\n};\n\nconst validateFileStdio = ({type, value, optionName}) => {\n\tif (isRegularUrl(value)) {\n\t\tthrow new TypeError(`The \\`${optionName}: URL\\` option must use the \\`file:\\` scheme.\nFor example, you can use the \\`pathToFileURL()\\` method of the \\`url\\` core module.`);\n\t}\n\n\tif (isUnknownStdioString(type, value)) {\n\t\tthrow new TypeError(`The \\`${optionName}: { file: '...' }\\` option must be used instead of \\`${optionName}: '...'\\`.`);\n\t}\n};\n\nconst validateFileObjectMode = (stdioItems, objectMode) => {\n\tif (!objectMode) {\n\t\treturn;\n\t}\n\n\tconst fileStdioItem = stdioItems.find(({type}) => FILE_TYPES.has(type));\n\tif (fileStdioItem !== undefined) {\n\t\tthrow new TypeError(`The \\`${fileStdioItem.optionName}\\` option cannot use both files and transforms in objectMode.`);\n\t}\n};\n\n// Some `stdio` values require Execa to create streams.\n// For example, file paths create file read/write streams.\n// Those transformations are specified in `addProperties`, which is both direction-specific and type-specific.\nconst getFinalFileDescriptors = ({initialFileDescriptors, addProperties, options, isSync}) => {\n\tconst fileDescriptors = [];\n\n\ttry {\n\t\tfor (const fileDescriptor of initialFileDescriptors) {\n\t\t\tfileDescriptors.push(getFinalFileDescriptor({\n\t\t\t\tfileDescriptor,\n\t\t\t\tfileDescriptors,\n\t\t\t\taddProperties,\n\t\t\t\toptions,\n\t\t\t\tisSync,\n\t\t\t}));\n\t\t}\n\n\t\treturn fileDescriptors;\n\t} catch (error) {\n\t\tcleanupCustomStreams(fileDescriptors);\n\t\tthrow error;\n\t}\n};\n\nconst getFinalFileDescriptor = ({\n\tfileDescriptor: {direction, objectMode, stdioItems},\n\tfileDescriptors,\n\taddProperties,\n\toptions,\n\tisSync,\n}) => {\n\tconst finalStdioItems = stdioItems.map(stdioItem => addStreamProperties({\n\t\tstdioItem,\n\t\taddProperties,\n\t\tdirection,\n\t\toptions,\n\t\tfileDescriptors,\n\t\tisSync,\n\t}));\n\treturn {direction, objectMode, stdioItems: finalStdioItems};\n};\n\nconst addStreamProperties = ({stdioItem, addProperties, direction, options, fileDescriptors, isSync}) => {\n\tconst duplicateStream = getDuplicateStream({\n\t\tstdioItem,\n\t\tdirection,\n\t\tfileDescriptors,\n\t\tisSync,\n\t});\n\n\tif (duplicateStream !== undefined) {\n\t\treturn {...stdioItem, stream: duplicateStream};\n\t}\n\n\treturn {\n\t\t...stdioItem,\n\t\t...addProperties[direction][stdioItem.type](stdioItem, options),\n\t};\n};\n\n// The stream error handling is performed by the piping logic above, which cannot be performed before subprocess spawning.\n// If the subprocess spawning fails (e.g. due to an invalid command), the streams need to be manually destroyed.\n// We need to create those streams before subprocess spawning, in case their creation fails, e.g. when passing an invalid generator as argument.\n// Like this, an exception would be thrown, which would prevent spawning a subprocess.\nexport const cleanupCustomStreams = fileDescriptors => {\n\tfor (const {stdioItems} of fileDescriptors) {\n\t\tfor (const {stream} of stdioItems) {\n\t\t\tif (stream !== undefined && !isStandardStream(stream)) {\n\t\t\t\tstream.destroy();\n\t\t\t}\n\t\t}\n\t}\n};\n\n// When the `std*: Iterable | WebStream | URL | filePath`, `input` or `inputFile` option is used, we pipe to `subprocess.std*`.\n// When the `std*: Array` option is used, we emulate some of the native values ('inherit', Node.js stream and file descriptor integer). To do so, we also need to pipe to `subprocess.std*`.\n// Therefore the `std*` options must be either `pipe` or `overlapped`. Other values do not set `subprocess.std*`.\nconst forwardStdio = stdioItems => {\n\tif (stdioItems.length > 1) {\n\t\treturn stdioItems.some(({value}) => value === 'overlapped') ? 'overlapped' : 'pipe';\n\t}\n\n\tconst [{type, value}] = stdioItems;\n\treturn type === 'native' ? value : 'pipe';\n};\n","// The `ipc` option adds an `ipc` item to the `stdio` option\nexport const normalizeIpcStdioArray = (stdioArray, ipc) => ipc && !stdioArray.includes('ipc')\n\t? [...stdioArray, 'ipc']\n\t: stdioArray;\n","import {readFileSync} from 'node:fs';\nimport {bufferToUint8Array} from '../utils/uint-array.js';\nimport {handleStdio} from './handle.js';\nimport {TYPE_TO_MESSAGE} from './type.js';\n\n// Normalize `input`, `inputFile`, `stdin`, `stdout` and `stderr` options, before spawning, in sync mode\nexport const handleStdioSync = (options, verboseInfo) => handleStdio(addPropertiesSync, options, verboseInfo, true);\n\nconst forbiddenIfSync = ({type, optionName}) => {\n\tthrowInvalidSyncValue(optionName, TYPE_TO_MESSAGE[type]);\n};\n\nconst forbiddenNativeIfSync = ({optionName, value}) => {\n\tif (value === 'ipc' || value === 'overlapped') {\n\t\tthrowInvalidSyncValue(optionName, `\"${value}\"`);\n\t}\n\n\treturn {};\n};\n\nconst throwInvalidSyncValue = (optionName, value) => {\n\tthrow new TypeError(`The \\`${optionName}\\` option cannot be ${value} with synchronous methods.`);\n};\n\n// Create streams used internally for redirecting when using specific values for the `std*` options, in sync mode.\n// For example, `stdin: {file}` reads the file synchronously, then passes it as the `input` option.\nconst addProperties = {\n\tgenerator() {},\n\tasyncGenerator: forbiddenIfSync,\n\twebStream: forbiddenIfSync,\n\tnodeStream: forbiddenIfSync,\n\twebTransform: forbiddenIfSync,\n\tduplex: forbiddenIfSync,\n\tasyncIterable: forbiddenIfSync,\n\tnative: forbiddenNativeIfSync,\n};\n\nconst addPropertiesSync = {\n\tinput: {\n\t\t...addProperties,\n\t\tfileUrl: ({value}) => ({contents: [bufferToUint8Array(readFileSync(value))]}),\n\t\tfilePath: ({value: {file}}) => ({contents: [bufferToUint8Array(readFileSync(file))]}),\n\t\tfileNumber: forbiddenIfSync,\n\t\titerable: ({value}) => ({contents: [...value]}),\n\t\tstring: ({value}) => ({contents: [value]}),\n\t\tuint8Array: ({value}) => ({contents: [value]}),\n\t},\n\toutput: {\n\t\t...addProperties,\n\t\tfileUrl: ({value}) => ({path: value}),\n\t\tfilePath: ({value: {file}}) => ({path: file}),\n\t\tfileNumber: ({value}) => ({path: value}),\n\t\titerable: forbiddenIfSync,\n\t\tstring: forbiddenIfSync,\n\t\tuint8Array: forbiddenIfSync,\n\t},\n};\n","import stripFinalNewlineFunction from 'strip-final-newline';\n\n// Apply `stripFinalNewline` option, which applies to `result.stdout|stderr|all|stdio[*]`.\n// If the `lines` option is used, it is applied on each line, but using a different function.\nexport const stripNewline = (value, {stripFinalNewline}, fdNumber) => getStripFinalNewline(stripFinalNewline, fdNumber) && value !== undefined && !Array.isArray(value)\n\t? stripFinalNewlineFunction(value)\n\t: value;\n\n// Retrieve `stripFinalNewline` option value, including with `subprocess.all`\nexport const getStripFinalNewline = (stripFinalNewline, fdNumber) => fdNumber === 'all'\n\t? stripFinalNewline[1] || stripFinalNewline[2]\n\t: stripFinalNewline[fdNumber];\n","// Split chunks line-wise for generators passed to the `std*` options\nexport const getSplitLinesGenerator = (binary, preserveNewlines, skipped, state) => binary || skipped\n\t? undefined\n\t: initializeSplitLines(preserveNewlines, state);\n\n// Same but for synchronous methods\nexport const splitLinesSync = (chunk, preserveNewlines, objectMode) => objectMode\n\t? chunk.flatMap(item => splitLinesItemSync(item, preserveNewlines))\n\t: splitLinesItemSync(chunk, preserveNewlines);\n\nconst splitLinesItemSync = (chunk, preserveNewlines) => {\n\tconst {transform, final} = initializeSplitLines(preserveNewlines, {});\n\treturn [...transform(chunk), ...final()];\n};\n\nconst initializeSplitLines = (preserveNewlines, state) => {\n\tstate.previousChunks = '';\n\treturn {\n\t\ttransform: splitGenerator.bind(undefined, state, preserveNewlines),\n\t\tfinal: linesFinal.bind(undefined, state),\n\t};\n};\n\n// This imperative logic is much faster than using `String.split()` and uses very low memory.\nconst splitGenerator = function * (state, preserveNewlines, chunk) {\n\tif (typeof chunk !== 'string') {\n\t\tyield chunk;\n\t\treturn;\n\t}\n\n\tlet {previousChunks} = state;\n\tlet start = -1;\n\n\tfor (let end = 0; end < chunk.length; end += 1) {\n\t\tif (chunk[end] === '\\n') {\n\t\t\tconst newlineLength = getNewlineLength(chunk, end, preserveNewlines, state);\n\t\t\tlet line = chunk.slice(start + 1, end + 1 - newlineLength);\n\n\t\t\tif (previousChunks.length > 0) {\n\t\t\t\tline = concatString(previousChunks, line);\n\t\t\t\tpreviousChunks = '';\n\t\t\t}\n\n\t\t\tyield line;\n\t\t\tstart = end;\n\t\t}\n\t}\n\n\tif (start !== chunk.length - 1) {\n\t\tpreviousChunks = concatString(previousChunks, chunk.slice(start + 1));\n\t}\n\n\tstate.previousChunks = previousChunks;\n};\n\nconst getNewlineLength = (chunk, end, preserveNewlines, state) => {\n\tif (preserveNewlines) {\n\t\treturn 0;\n\t}\n\n\tstate.isWindowsNewline = end !== 0 && chunk[end - 1] === '\\r';\n\treturn state.isWindowsNewline ? 2 : 1;\n};\n\nconst linesFinal = function * ({previousChunks}) {\n\tif (previousChunks.length > 0) {\n\t\tyield previousChunks;\n\t}\n};\n\n// Unless `preserveNewlines: true` is used, we strip the newline of each line.\n// This re-adds them after the user `transform` code has run.\nexport const getAppendNewlineGenerator = ({binary, preserveNewlines, readableObjectMode, state}) => binary || preserveNewlines || readableObjectMode\n\t? undefined\n\t: {transform: appendNewlineGenerator.bind(undefined, state)};\n\nconst appendNewlineGenerator = function * ({isWindowsNewline = false}, chunk) {\n\tconst {unixNewline, windowsNewline, LF, concatBytes} = typeof chunk === 'string' ? linesStringInfo : linesUint8ArrayInfo;\n\n\tif (chunk.at(-1) === LF) {\n\t\tyield chunk;\n\t\treturn;\n\t}\n\n\tconst newline = isWindowsNewline ? windowsNewline : unixNewline;\n\tyield concatBytes(chunk, newline);\n};\n\nconst concatString = (firstChunk, secondChunk) => `${firstChunk}${secondChunk}`;\n\nconst linesStringInfo = {\n\twindowsNewline: '\\r\\n',\n\tunixNewline: '\\n',\n\tLF: '\\n',\n\tconcatBytes: concatString,\n};\n\nconst concatUint8Array = (firstChunk, secondChunk) => {\n\tconst chunk = new Uint8Array(firstChunk.length + secondChunk.length);\n\tchunk.set(firstChunk, 0);\n\tchunk.set(secondChunk, firstChunk.length);\n\treturn chunk;\n};\n\nconst linesUint8ArrayInfo = {\n\twindowsNewline: new Uint8Array([0x0D, 0x0A]),\n\tunixNewline: new Uint8Array([0x0A]),\n\tLF: 0x0A,\n\tconcatBytes: concatUint8Array,\n};\n","import {Buffer} from 'node:buffer';\nimport {isUint8Array} from '../utils/uint-array.js';\n\n// Validate the type of chunk argument passed to transform generators\nexport const getValidateTransformInput = (writableObjectMode, optionName) => writableObjectMode\n\t? undefined\n\t: validateStringTransformInput.bind(undefined, optionName);\n\nconst validateStringTransformInput = function * (optionName, chunk) {\n\tif (typeof chunk !== 'string' && !isUint8Array(chunk) && !Buffer.isBuffer(chunk)) {\n\t\tthrow new TypeError(`The \\`${optionName}\\` option's transform must use \"objectMode: true\" to receive as input: ${typeof chunk}.`);\n\t}\n\n\tyield chunk;\n};\n\n// Validate the type of the value returned by transform generators\nexport const getValidateTransformReturn = (readableObjectMode, optionName) => readableObjectMode\n\t? validateObjectTransformReturn.bind(undefined, optionName)\n\t: validateStringTransformReturn.bind(undefined, optionName);\n\nconst validateObjectTransformReturn = function * (optionName, chunk) {\n\tvalidateEmptyReturn(optionName, chunk);\n\tyield chunk;\n};\n\nconst validateStringTransformReturn = function * (optionName, chunk) {\n\tvalidateEmptyReturn(optionName, chunk);\n\n\tif (typeof chunk !== 'string' && !isUint8Array(chunk)) {\n\t\tthrow new TypeError(`The \\`${optionName}\\` option's function must yield a string or an Uint8Array, not ${typeof chunk}.`);\n\t}\n\n\tyield chunk;\n};\n\nconst validateEmptyReturn = (optionName, chunk) => {\n\tif (chunk === null || chunk === undefined) {\n\t\tthrow new TypeError(`The \\`${optionName}\\` option's function must not call \\`yield ${chunk}\\`.\nInstead, \\`yield\\` should either be called with a value, or not be called at all. For example:\n if (condition) { yield value; }`);\n\t}\n};\n","import {Buffer} from 'node:buffer';\nimport {StringDecoder} from 'node:string_decoder';\nimport {isUint8Array, bufferToUint8Array} from '../utils/uint-array.js';\n\n/*\nWhen using binary encodings, add an internal generator that converts chunks from `Buffer` to `string` or `Uint8Array`.\nChunks might be Buffer, Uint8Array or strings since:\n- `subprocess.stdout|stderr` emits Buffers\n- `subprocess.stdin.write()` accepts Buffer, Uint8Array or string\n- Previous generators might return Uint8Array or string\n\nHowever, those are converted to Buffer:\n- on writes: `Duplex.writable` `decodeStrings: true` default option\n- on reads: `Duplex.readable` `readableEncoding: null` default option\n*/\nexport const getEncodingTransformGenerator = (binary, encoding, skipped) => {\n\tif (skipped) {\n\t\treturn;\n\t}\n\n\tif (binary) {\n\t\treturn {transform: encodingUint8ArrayGenerator.bind(undefined, new TextEncoder())};\n\t}\n\n\tconst stringDecoder = new StringDecoder(encoding);\n\treturn {\n\t\ttransform: encodingStringGenerator.bind(undefined, stringDecoder),\n\t\tfinal: encodingStringFinal.bind(undefined, stringDecoder),\n\t};\n};\n\nconst encodingUint8ArrayGenerator = function * (textEncoder, chunk) {\n\tif (Buffer.isBuffer(chunk)) {\n\t\tyield bufferToUint8Array(chunk);\n\t} else if (typeof chunk === 'string') {\n\t\tyield textEncoder.encode(chunk);\n\t} else {\n\t\tyield chunk;\n\t}\n};\n\nconst encodingStringGenerator = function * (stringDecoder, chunk) {\n\tyield isUint8Array(chunk) ? stringDecoder.write(chunk) : chunk;\n};\n\nconst encodingStringFinal = function * (stringDecoder) {\n\tconst lastChunk = stringDecoder.end();\n\tif (lastChunk !== '') {\n\t\tyield lastChunk;\n\t}\n};\n","import {callbackify} from 'node:util';\n\n// Applies a series of generator functions asynchronously\nexport const pushChunks = callbackify(async (getChunks, state, getChunksArguments, transformStream) => {\n\tstate.currentIterable = getChunks(...getChunksArguments);\n\n\ttry {\n\t\tfor await (const chunk of state.currentIterable) {\n\t\t\ttransformStream.push(chunk);\n\t\t}\n\t} finally {\n\t\tdelete state.currentIterable;\n\t}\n});\n\n// For each new chunk, apply each `transform()` method\nexport const transformChunk = async function * (chunk, generators, index) {\n\tif (index === generators.length) {\n\t\tyield chunk;\n\t\treturn;\n\t}\n\n\tconst {transform = identityGenerator} = generators[index];\n\tfor await (const transformedChunk of transform(chunk)) {\n\t\tyield * transformChunk(transformedChunk, generators, index + 1);\n\t}\n};\n\n// At the end, apply each `final()` method, followed by the `transform()` method of the next transforms\nexport const finalChunks = async function * (generators) {\n\tfor (const [index, {final}] of Object.entries(generators)) {\n\t\tyield * generatorFinalChunks(final, Number(index), generators);\n\t}\n};\n\nconst generatorFinalChunks = async function * (final, index, generators) {\n\tif (final === undefined) {\n\t\treturn;\n\t}\n\n\tfor await (const finalChunk of final()) {\n\t\tyield * transformChunk(finalChunk, generators, index + 1);\n\t}\n};\n\n// Cancel any ongoing async generator when the Transform is destroyed, e.g. when the subprocess errors\nexport const destroyTransform = callbackify(async ({currentIterable}, error) => {\n\tif (currentIterable !== undefined) {\n\t\tawait (error ? currentIterable.throw(error) : currentIterable.return());\n\t\treturn;\n\t}\n\n\tif (error) {\n\t\tthrow error;\n\t}\n});\n\nconst identityGenerator = function * (chunk) {\n\tyield chunk;\n};\n","// Duplicate the code from `run-async.js` but as synchronous functions\nexport const pushChunksSync = (getChunksSync, getChunksArguments, transformStream, done) => {\n\ttry {\n\t\tfor (const chunk of getChunksSync(...getChunksArguments)) {\n\t\t\ttransformStream.push(chunk);\n\t\t}\n\n\t\tdone();\n\t} catch (error) {\n\t\tdone(error);\n\t}\n};\n\n// Run synchronous generators with `execaSync()`\nexport const runTransformSync = (generators, chunks) => [\n\t...chunks.flatMap(chunk => [...transformChunkSync(chunk, generators, 0)]),\n\t...finalChunksSync(generators),\n];\n\nexport const transformChunkSync = function * (chunk, generators, index) {\n\tif (index === generators.length) {\n\t\tyield chunk;\n\t\treturn;\n\t}\n\n\tconst {transform = identityGenerator} = generators[index];\n\tfor (const transformedChunk of transform(chunk)) {\n\t\tyield * transformChunkSync(transformedChunk, generators, index + 1);\n\t}\n};\n\nexport const finalChunksSync = function * (generators) {\n\tfor (const [index, {final}] of Object.entries(generators)) {\n\t\tyield * generatorFinalChunksSync(final, Number(index), generators);\n\t}\n};\n\nconst generatorFinalChunksSync = function * (final, index, generators) {\n\tif (final === undefined) {\n\t\treturn;\n\t}\n\n\tfor (const finalChunk of final()) {\n\t\tyield * transformChunkSync(finalChunk, generators, index + 1);\n\t}\n};\n\nconst identityGenerator = function * (chunk) {\n\tyield chunk;\n};\n","import {Transform, getDefaultHighWaterMark} from 'node:stream';\nimport {isAsyncGenerator} from '../stdio/type.js';\nimport {getSplitLinesGenerator, getAppendNewlineGenerator} from './split.js';\nimport {getValidateTransformInput, getValidateTransformReturn} from './validate.js';\nimport {getEncodingTransformGenerator} from './encoding-transform.js';\nimport {\n\tpushChunks,\n\ttransformChunk,\n\tfinalChunks,\n\tdestroyTransform,\n} from './run-async.js';\nimport {\n\tpushChunksSync,\n\ttransformChunkSync,\n\tfinalChunksSync,\n\trunTransformSync,\n} from './run-sync.js';\n\n/*\nGenerators can be used to transform/filter standard streams.\n\nGenerators have a simple syntax, yet allows all of the following:\n- Sharing `state` between chunks\n- Flushing logic, by using a `final` function\n- Asynchronous logic\n- Emitting multiple chunks from a single source chunk, even if spaced in time, by using multiple `yield`\n- Filtering, by using no `yield`\n\nTherefore, there is no need to allow Node.js or web transform streams.\n\nThe `highWaterMark` is kept as the default value, since this is what `subprocess.std*` uses.\n\nChunks are currently processed serially. We could add a `concurrency` option to parallelize in the future.\n\nTransform an array of generator functions into a `Transform` stream.\n`Duplex.from(generator)` cannot be used because it does not allow setting the `objectMode` and `highWaterMark`.\n*/\nexport const generatorToStream = ({\n\tvalue,\n\tvalue: {transform, final, writableObjectMode, readableObjectMode},\n\toptionName,\n}, {encoding}) => {\n\tconst state = {};\n\tconst generators = addInternalGenerators(value, encoding, optionName);\n\n\tconst transformAsync = isAsyncGenerator(transform);\n\tconst finalAsync = isAsyncGenerator(final);\n\tconst transformMethod = transformAsync\n\t\t? pushChunks.bind(undefined, transformChunk, state)\n\t\t: pushChunksSync.bind(undefined, transformChunkSync);\n\tconst finalMethod = transformAsync || finalAsync\n\t\t? pushChunks.bind(undefined, finalChunks, state)\n\t\t: pushChunksSync.bind(undefined, finalChunksSync);\n\tconst destroyMethod = transformAsync || finalAsync\n\t\t? destroyTransform.bind(undefined, state)\n\t\t: undefined;\n\n\tconst stream = new Transform({\n\t\twritableObjectMode,\n\t\twritableHighWaterMark: getDefaultHighWaterMark(writableObjectMode),\n\t\treadableObjectMode,\n\t\treadableHighWaterMark: getDefaultHighWaterMark(readableObjectMode),\n\t\ttransform(chunk, encoding, done) {\n\t\t\ttransformMethod([chunk, generators, 0], this, done);\n\t\t},\n\t\tflush(done) {\n\t\t\tfinalMethod([generators], this, done);\n\t\t},\n\t\tdestroy: destroyMethod,\n\t});\n\treturn {stream};\n};\n\n// Applies transform generators in sync mode\nexport const runGeneratorsSync = (chunks, stdioItems, encoding, isInput) => {\n\tconst generators = stdioItems.filter(({type}) => type === 'generator');\n\tconst reversedGenerators = isInput ? generators.reverse() : generators;\n\n\tfor (const {value, optionName} of reversedGenerators) {\n\t\tconst generators = addInternalGenerators(value, encoding, optionName);\n\t\tchunks = runTransformSync(generators, chunks);\n\t}\n\n\treturn chunks;\n};\n\n// Generators used internally to convert the chunk type, validate it, and split into lines\nconst addInternalGenerators = (\n\t{transform, final, binary, writableObjectMode, readableObjectMode, preserveNewlines},\n\tencoding,\n\toptionName,\n) => {\n\tconst state = {};\n\treturn [\n\t\t{transform: getValidateTransformInput(writableObjectMode, optionName)},\n\t\tgetEncodingTransformGenerator(binary, encoding, writableObjectMode),\n\t\tgetSplitLinesGenerator(binary, preserveNewlines, writableObjectMode, state),\n\t\t{transform, final},\n\t\t{transform: getValidateTransformReturn(readableObjectMode, optionName)},\n\t\tgetAppendNewlineGenerator({\n\t\t\tbinary,\n\t\t\tpreserveNewlines,\n\t\t\treadableObjectMode,\n\t\t\tstate,\n\t\t}),\n\t].filter(Boolean);\n};\n","import {runGeneratorsSync} from '../transform/generator.js';\nimport {joinToUint8Array, isUint8Array} from '../utils/uint-array.js';\nimport {TYPE_TO_MESSAGE} from '../stdio/type.js';\n\n// Apply `stdin`/`input`/`inputFile` options, before spawning, in sync mode, by converting it to the `input` option\nexport const addInputOptionsSync = (fileDescriptors, options) => {\n\tfor (const fdNumber of getInputFdNumbers(fileDescriptors)) {\n\t\taddInputOptionSync(fileDescriptors, fdNumber, options);\n\t}\n};\n\nconst getInputFdNumbers = fileDescriptors => new Set(Object.entries(fileDescriptors)\n\t.filter(([, {direction}]) => direction === 'input')\n\t.map(([fdNumber]) => Number(fdNumber)));\n\nconst addInputOptionSync = (fileDescriptors, fdNumber, options) => {\n\tconst {stdioItems} = fileDescriptors[fdNumber];\n\tconst allStdioItems = stdioItems.filter(({contents}) => contents !== undefined);\n\tif (allStdioItems.length === 0) {\n\t\treturn;\n\t}\n\n\tif (fdNumber !== 0) {\n\t\tconst [{type, optionName}] = allStdioItems;\n\t\tthrow new TypeError(`Only the \\`stdin\\` option, not \\`${optionName}\\`, can be ${TYPE_TO_MESSAGE[type]} with synchronous methods.`);\n\t}\n\n\tconst allContents = allStdioItems.map(({contents}) => contents);\n\tconst transformedContents = allContents.map(contents => applySingleInputGeneratorsSync(contents, stdioItems));\n\toptions.input = joinToUint8Array(transformedContents);\n};\n\nconst applySingleInputGeneratorsSync = (contents, stdioItems) => {\n\tconst newContents = runGeneratorsSync(contents, stdioItems, 'utf8', true);\n\tvalidateSerializable(newContents);\n\treturn joinToUint8Array(newContents);\n};\n\nconst validateSerializable = newContents => {\n\tconst invalidItem = newContents.find(item => typeof item !== 'string' && !isUint8Array(item));\n\tif (invalidItem !== undefined) {\n\t\tthrow new TypeError(`The \\`stdin\\` option is invalid: when passing objects as input, a transform must be used to serialize them to strings or Uint8Arrays: ${invalidItem}.`);\n\t}\n};\n","import {BINARY_ENCODINGS} from '../arguments/encoding-option.js';\nimport {TRANSFORM_TYPES} from '../stdio/type.js';\nimport {verboseLog, serializeVerboseMessage} from './log.js';\nimport {isFullVerbose} from './values.js';\n\n// `ignore` opts-out of `verbose` for a specific stream.\n// `ipc` cannot use piping.\n// `inherit` would result in double printing.\n// They can also lead to double printing when passing file descriptor integers or `process.std*`.\n// This only leaves with `pipe` and `overlapped`.\nexport const shouldLogOutput = ({stdioItems, encoding, verboseInfo, fdNumber}) => fdNumber !== 'all'\n\t&& isFullVerbose(verboseInfo, fdNumber)\n\t&& !BINARY_ENCODINGS.has(encoding)\n\t&& fdUsesVerbose(fdNumber)\n\t&& (stdioItems.some(({type, value}) => type === 'native' && PIPED_STDIO_VALUES.has(value))\n\t|| stdioItems.every(({type}) => TRANSFORM_TYPES.has(type)));\n\n// Printing input streams would be confusing.\n// Files and streams can produce big outputs, which we don't want to print.\n// We could print `stdio[3+]` but it often is redirected to files and streams, with the same issue.\n// So we only print stdout and stderr.\nconst fdUsesVerbose = fdNumber => fdNumber === 1 || fdNumber === 2;\n\nconst PIPED_STDIO_VALUES = new Set(['pipe', 'overlapped']);\n\n// `verbose: 'full'` printing logic with async methods\nexport const logLines = async (linesIterable, stream, fdNumber, verboseInfo) => {\n\tfor await (const line of linesIterable) {\n\t\tif (!isPipingStream(stream)) {\n\t\t\tlogLine(line, fdNumber, verboseInfo);\n\t\t}\n\t}\n};\n\n// `verbose: 'full'` printing logic with sync methods\nexport const logLinesSync = (linesArray, fdNumber, verboseInfo) => {\n\tfor (const line of linesArray) {\n\t\tlogLine(line, fdNumber, verboseInfo);\n\t}\n};\n\n// When `subprocess.stdout|stderr.pipe()` is called, `verbose` becomes a noop.\n// This prevents the following problems:\n// - `.pipe()` achieves the same result as using `stdout: 'inherit'`, `stdout: stream`, etc. which also make `verbose` a noop.\n// For example, `subprocess.stdout.pipe(process.stdin)` would print each line twice.\n// - When chaining subprocesses with `subprocess.pipe(otherSubprocess)`, only the last one should print its output.\n// Detecting whether `.pipe()` is impossible without monkey-patching it, so we use the following undocumented property.\n// This is not a critical behavior since changes of the following property would only make `verbose` more verbose.\nconst isPipingStream = stream => stream._readableState.pipes.length > 0;\n\n// When `verbose` is `full`, print stdout|stderr\nconst logLine = (line, fdNumber, verboseInfo) => {\n\tconst verboseMessage = serializeVerboseMessage(line);\n\tverboseLog({\n\t\ttype: 'output',\n\t\tverboseMessage,\n\t\tfdNumber,\n\t\tverboseInfo,\n\t});\n};\n","import {writeFileSync, appendFileSync} from 'node:fs';\nimport {shouldLogOutput, logLinesSync} from '../verbose/output.js';\nimport {runGeneratorsSync} from '../transform/generator.js';\nimport {splitLinesSync} from '../transform/split.js';\nimport {joinToString, joinToUint8Array, bufferToUint8Array} from '../utils/uint-array.js';\nimport {FILE_TYPES} from '../stdio/type.js';\nimport {truncateMaxBufferSync} from './max-buffer.js';\n\n// Apply `stdout`/`stderr` options, after spawning, in sync mode\nexport const transformOutputSync = ({fileDescriptors, syncResult: {output}, options, isMaxBuffer, verboseInfo}) => {\n\tif (output === null) {\n\t\treturn {output: Array.from({length: 3})};\n\t}\n\n\tconst state = {};\n\tconst outputFiles = new Set([]);\n\tconst transformedOutput = output.map((result, fdNumber) =>\n\t\ttransformOutputResultSync({\n\t\t\tresult,\n\t\t\tfileDescriptors,\n\t\t\tfdNumber,\n\t\t\tstate,\n\t\t\toutputFiles,\n\t\t\tisMaxBuffer,\n\t\t\tverboseInfo,\n\t\t}, options));\n\treturn {output: transformedOutput, ...state};\n};\n\nconst transformOutputResultSync = (\n\t{result, fileDescriptors, fdNumber, state, outputFiles, isMaxBuffer, verboseInfo},\n\t{buffer, encoding, lines, stripFinalNewline, maxBuffer},\n) => {\n\tif (result === null) {\n\t\treturn;\n\t}\n\n\tconst truncatedResult = truncateMaxBufferSync(result, isMaxBuffer, maxBuffer);\n\tconst uint8ArrayResult = bufferToUint8Array(truncatedResult);\n\tconst {stdioItems, objectMode} = fileDescriptors[fdNumber];\n\tconst chunks = runOutputGeneratorsSync([uint8ArrayResult], stdioItems, encoding, state);\n\tconst {serializedResult, finalResult = serializedResult} = serializeChunks({\n\t\tchunks,\n\t\tobjectMode,\n\t\tencoding,\n\t\tlines,\n\t\tstripFinalNewline,\n\t\tfdNumber,\n\t});\n\n\tlogOutputSync({\n\t\tserializedResult,\n\t\tfdNumber,\n\t\tstate,\n\t\tverboseInfo,\n\t\tencoding,\n\t\tstdioItems,\n\t\tobjectMode,\n\t});\n\n\tconst returnedResult = buffer[fdNumber] ? finalResult : undefined;\n\n\ttry {\n\t\tif (state.error === undefined) {\n\t\t\twriteToFiles(serializedResult, stdioItems, outputFiles);\n\t\t}\n\n\t\treturn returnedResult;\n\t} catch (error) {\n\t\tstate.error = error;\n\t\treturn returnedResult;\n\t}\n};\n\n// Applies transform generators to `stdout`/`stderr`\nconst runOutputGeneratorsSync = (chunks, stdioItems, encoding, state) => {\n\ttry {\n\t\treturn runGeneratorsSync(chunks, stdioItems, encoding, false);\n\t} catch (error) {\n\t\tstate.error = error;\n\t\treturn chunks;\n\t}\n};\n\n// The contents is converted to three stages:\n// - serializedResult: used when the target is a file path/URL or a file descriptor (including 'inherit')\n// - finalResult/returnedResult: returned as `result.std*`\nconst serializeChunks = ({chunks, objectMode, encoding, lines, stripFinalNewline, fdNumber}) => {\n\tif (objectMode) {\n\t\treturn {serializedResult: chunks};\n\t}\n\n\tif (encoding === 'buffer') {\n\t\treturn {serializedResult: joinToUint8Array(chunks)};\n\t}\n\n\tconst serializedResult = joinToString(chunks, encoding);\n\tif (lines[fdNumber]) {\n\t\treturn {serializedResult, finalResult: splitLinesSync(serializedResult, !stripFinalNewline[fdNumber], objectMode)};\n\t}\n\n\treturn {serializedResult};\n};\n\nconst logOutputSync = ({serializedResult, fdNumber, state, verboseInfo, encoding, stdioItems, objectMode}) => {\n\tif (!shouldLogOutput({\n\t\tstdioItems,\n\t\tencoding,\n\t\tverboseInfo,\n\t\tfdNumber,\n\t})) {\n\t\treturn;\n\t}\n\n\tconst linesArray = splitLinesSync(serializedResult, false, objectMode);\n\n\ttry {\n\t\tlogLinesSync(linesArray, fdNumber, verboseInfo);\n\t} catch (error) {\n\t\tstate.error ??= error;\n\t}\n};\n\n// When the `std*` target is a file path/URL or a file descriptor\nconst writeToFiles = (serializedResult, stdioItems, outputFiles) => {\n\tfor (const {path} of stdioItems.filter(({type}) => FILE_TYPES.has(type))) {\n\t\tconst pathString = typeof path === 'string' ? path : path.toString();\n\t\tif (outputFiles.has(pathString)) {\n\t\t\tappendFileSync(path, serializedResult);\n\t\t} else {\n\t\t\toutputFiles.add(pathString);\n\t\t\twriteFileSync(path, serializedResult);\n\t\t}\n\t}\n};\n","import {once} from 'node:events';\nimport {DiscardedError} from '../return/final-error.js';\n\n// If `error` is emitted before `spawn`, `exit` will never be emitted.\n// However, `error` might be emitted after `spawn`.\n// In that case, `exit` will still be emitted.\n// Since the `exit` event contains the signal name, we want to make sure we are listening for it.\n// This function also takes into account the following unlikely cases:\n// - `exit` being emitted in the same microtask as `spawn`\n// - `error` being emitted multiple times\nexport const waitForExit = async (subprocess, context) => {\n\tconst [exitCode, signal] = await waitForExitOrError(subprocess);\n\tcontext.isForcefullyTerminated ??= false;\n\treturn [exitCode, signal];\n};\n\nconst waitForExitOrError = async subprocess => {\n\tconst [spawnPayload, exitPayload] = await Promise.allSettled([\n\t\tonce(subprocess, 'spawn'),\n\t\tonce(subprocess, 'exit'),\n\t]);\n\n\tif (spawnPayload.status === 'rejected') {\n\t\treturn [];\n\t}\n\n\treturn exitPayload.status === 'rejected'\n\t\t? waitForSubprocessExit(subprocess)\n\t\t: exitPayload.value;\n};\n\nconst waitForSubprocessExit = async subprocess => {\n\ttry {\n\t\treturn await once(subprocess, 'exit');\n\t} catch {\n\t\treturn waitForSubprocessExit(subprocess);\n\t}\n};\n\n// Retrieve the final exit code and|or signal name\nexport const waitForSuccessfulExit = async exitPromise => {\n\tconst [exitCode, signal] = await exitPromise;\n\n\tif (!isSubprocessErrorExit(exitCode, signal) && isFailedExit(exitCode, signal)) {\n\t\tthrow new DiscardedError();\n\t}\n\n\treturn [exitCode, signal];\n};\n\n// When the subprocess fails due to an `error` event\nconst isSubprocessErrorExit = (exitCode, signal) => exitCode === undefined && signal === undefined;\n// When the subprocess fails due to a non-0 exit code or to a signal termination\nexport const isFailedExit = (exitCode, signal) => exitCode !== 0 || signal !== null;\n","import {DiscardedError} from '../return/final-error.js';\nimport {isMaxBufferSync} from '../io/max-buffer.js';\nimport {isFailedExit} from './exit-async.js';\n\n// Retrieve exit code, signal name and error information, with synchronous methods\nexport const getExitResultSync = ({error, status: exitCode, signal, output}, {maxBuffer}) => {\n\tconst resultError = getResultError(error, exitCode, signal);\n\tconst timedOut = resultError?.code === 'ETIMEDOUT';\n\tconst isMaxBuffer = isMaxBufferSync(resultError, output, maxBuffer);\n\treturn {\n\t\tresultError,\n\t\texitCode,\n\t\tsignal,\n\t\ttimedOut,\n\t\tisMaxBuffer,\n\t};\n};\n\nconst getResultError = (error, exitCode, signal) => {\n\tif (error !== undefined) {\n\t\treturn error;\n\t}\n\n\treturn isFailedExit(exitCode, signal) ? new DiscardedError() : undefined;\n};\n","import {spawnSync} from 'node:child_process';\nimport {handleCommand} from '../arguments/command.js';\nimport {normalizeOptions} from '../arguments/options.js';\nimport {makeError, makeEarlyError, makeSuccessResult} from '../return/result.js';\nimport {handleResult} from '../return/reject.js';\nimport {handleStdioSync} from '../stdio/handle-sync.js';\nimport {stripNewline} from '../io/strip-newline.js';\nimport {addInputOptionsSync} from '../io/input-sync.js';\nimport {transformOutputSync} from '../io/output-sync.js';\nimport {getMaxBufferSync} from '../io/max-buffer.js';\nimport {getAllSync} from '../resolve/all-sync.js';\nimport {getExitResultSync} from '../resolve/exit-sync.js';\n\n// Main shared logic for all sync methods: `execaSync()`, `$.sync()`\nexport const execaCoreSync = (rawFile, rawArguments, rawOptions) => {\n\tconst {file, commandArguments, command, escapedCommand, startTime, verboseInfo, options, fileDescriptors} = handleSyncArguments(rawFile, rawArguments, rawOptions);\n\tconst result = spawnSubprocessSync({\n\t\tfile,\n\t\tcommandArguments,\n\t\toptions,\n\t\tcommand,\n\t\tescapedCommand,\n\t\tverboseInfo,\n\t\tfileDescriptors,\n\t\tstartTime,\n\t});\n\treturn handleResult(result, verboseInfo, options);\n};\n\n// Compute arguments to pass to `child_process.spawnSync()`\nconst handleSyncArguments = (rawFile, rawArguments, rawOptions) => {\n\tconst {command, escapedCommand, startTime, verboseInfo} = handleCommand(rawFile, rawArguments, rawOptions);\n\tconst syncOptions = normalizeSyncOptions(rawOptions);\n\tconst {file, commandArguments, options} = normalizeOptions(rawFile, rawArguments, syncOptions);\n\tvalidateSyncOptions(options);\n\tconst fileDescriptors = handleStdioSync(options, verboseInfo);\n\treturn {\n\t\tfile,\n\t\tcommandArguments,\n\t\tcommand,\n\t\tescapedCommand,\n\t\tstartTime,\n\t\tverboseInfo,\n\t\toptions,\n\t\tfileDescriptors,\n\t};\n};\n\n// Options normalization logic specific to sync methods\nconst normalizeSyncOptions = options => options.node && !options.ipc ? {...options, ipc: false} : options;\n\n// Options validation logic specific to sync methods\nconst validateSyncOptions = ({ipc, ipcInput, detached, cancelSignal}) => {\n\tif (ipcInput) {\n\t\tthrowInvalidSyncOption('ipcInput');\n\t}\n\n\tif (ipc) {\n\t\tthrowInvalidSyncOption('ipc: true');\n\t}\n\n\tif (detached) {\n\t\tthrowInvalidSyncOption('detached: true');\n\t}\n\n\tif (cancelSignal) {\n\t\tthrowInvalidSyncOption('cancelSignal');\n\t}\n};\n\nconst throwInvalidSyncOption = value => {\n\tthrow new TypeError(`The \"${value}\" option cannot be used with synchronous methods.`);\n};\n\nconst spawnSubprocessSync = ({file, commandArguments, options, command, escapedCommand, verboseInfo, fileDescriptors, startTime}) => {\n\tconst syncResult = runSubprocessSync({\n\t\tfile,\n\t\tcommandArguments,\n\t\toptions,\n\t\tcommand,\n\t\tescapedCommand,\n\t\tfileDescriptors,\n\t\tstartTime,\n\t});\n\tif (syncResult.failed) {\n\t\treturn syncResult;\n\t}\n\n\tconst {resultError, exitCode, signal, timedOut, isMaxBuffer} = getExitResultSync(syncResult, options);\n\tconst {output, error = resultError} = transformOutputSync({\n\t\tfileDescriptors,\n\t\tsyncResult,\n\t\toptions,\n\t\tisMaxBuffer,\n\t\tverboseInfo,\n\t});\n\tconst stdio = output.map((stdioOutput, fdNumber) => stripNewline(stdioOutput, options, fdNumber));\n\tconst all = stripNewline(getAllSync(output, options), options, 'all');\n\treturn getSyncResult({\n\t\terror,\n\t\texitCode,\n\t\tsignal,\n\t\ttimedOut,\n\t\tisMaxBuffer,\n\t\tstdio,\n\t\tall,\n\t\toptions,\n\t\tcommand,\n\t\tescapedCommand,\n\t\tstartTime,\n\t});\n};\n\nconst runSubprocessSync = ({file, commandArguments, options, command, escapedCommand, fileDescriptors, startTime}) => {\n\ttry {\n\t\taddInputOptionsSync(fileDescriptors, options);\n\t\tconst normalizedOptions = normalizeSpawnSyncOptions(options);\n\t\treturn spawnSync(file, commandArguments, normalizedOptions);\n\t} catch (error) {\n\t\treturn makeEarlyError({\n\t\t\terror,\n\t\t\tcommand,\n\t\t\tescapedCommand,\n\t\t\tfileDescriptors,\n\t\t\toptions,\n\t\t\tstartTime,\n\t\t\tisSync: true,\n\t\t});\n\t}\n};\n\n// The `encoding` option is handled by Execa, not by `child_process.spawnSync()`\nconst normalizeSpawnSyncOptions = ({encoding, maxBuffer, ...options}) => ({...options, encoding: 'buffer', maxBuffer: getMaxBufferSync(maxBuffer)});\n\nconst getSyncResult = ({error, exitCode, signal, timedOut, isMaxBuffer, stdio, all, options, command, escapedCommand, startTime}) => error === undefined\n\t? makeSuccessResult({\n\t\tcommand,\n\t\tescapedCommand,\n\t\tstdio,\n\t\tall,\n\t\tipcOutput: [],\n\t\toptions,\n\t\tstartTime,\n\t})\n\t: makeError({\n\t\terror,\n\t\tcommand,\n\t\tescapedCommand,\n\t\ttimedOut,\n\t\tisCanceled: false,\n\t\tisGracefullyCanceled: false,\n\t\tisMaxBuffer,\n\t\tisForcefullyTerminated: false,\n\t\texitCode,\n\t\tsignal,\n\t\tstdio,\n\t\tall,\n\t\tipcOutput: [],\n\t\toptions,\n\t\tstartTime,\n\t\tisSync: true,\n\t});\n","import {isUint8Array, concatUint8Arrays} from '../utils/uint-array.js';\nimport {stripNewline} from '../io/strip-newline.js';\n\n// Retrieve `result.all` with synchronous methods\nexport const getAllSync = ([, stdout, stderr], options) => {\n\tif (!options.all) {\n\t\treturn;\n\t}\n\n\tif (stdout === undefined) {\n\t\treturn stderr;\n\t}\n\n\tif (stderr === undefined) {\n\t\treturn stdout;\n\t}\n\n\tif (Array.isArray(stdout)) {\n\t\treturn Array.isArray(stderr)\n\t\t\t? [...stdout, ...stderr]\n\t\t\t: [...stdout, stripNewline(stderr, options, 'all')];\n\t}\n\n\tif (Array.isArray(stderr)) {\n\t\treturn [stripNewline(stdout, options, 'all'), ...stderr];\n\t}\n\n\tif (isUint8Array(stdout) && isUint8Array(stderr)) {\n\t\treturn concatUint8Arrays([stdout, stderr]);\n\t}\n\n\treturn `${stdout}${stderr}`;\n};\n","import {once, on} from 'node:events';\nimport {\n\tvalidateIpcMethod,\n\tthrowOnEarlyDisconnect,\n\tdisconnect,\n\tgetStrictResponseError,\n} from './validation.js';\nimport {getIpcEmitter, isConnected} from './forward.js';\nimport {addReference, removeReference} from './reference.js';\n\n// Like `[sub]process.once('message')` but promise-based\nexport const getOneMessage = ({anyProcess, channel, isSubprocess, ipc}, {reference = true, filter} = {}) => {\n\tvalidateIpcMethod({\n\t\tmethodName: 'getOneMessage',\n\t\tisSubprocess,\n\t\tipc,\n\t\tisConnected: isConnected(anyProcess),\n\t});\n\n\treturn getOneMessageAsync({\n\t\tanyProcess,\n\t\tchannel,\n\t\tisSubprocess,\n\t\tfilter,\n\t\treference,\n\t});\n};\n\nconst getOneMessageAsync = async ({anyProcess, channel, isSubprocess, filter, reference}) => {\n\taddReference(channel, reference);\n\tconst ipcEmitter = getIpcEmitter(anyProcess, channel, isSubprocess);\n\tconst controller = new AbortController();\n\ttry {\n\t\treturn await Promise.race([\n\t\t\tgetMessage(ipcEmitter, filter, controller),\n\t\t\tthrowOnDisconnect(ipcEmitter, isSubprocess, controller),\n\t\t\tthrowOnStrictError(ipcEmitter, isSubprocess, controller),\n\t\t]);\n\t} catch (error) {\n\t\tdisconnect(anyProcess);\n\t\tthrow error;\n\t} finally {\n\t\tcontroller.abort();\n\t\tremoveReference(channel, reference);\n\t}\n};\n\nconst getMessage = async (ipcEmitter, filter, {signal}) => {\n\tif (filter === undefined) {\n\t\tconst [message] = await once(ipcEmitter, 'message', {signal});\n\t\treturn message;\n\t}\n\n\tfor await (const [message] of on(ipcEmitter, 'message', {signal})) {\n\t\tif (filter(message)) {\n\t\t\treturn message;\n\t\t}\n\t}\n};\n\nconst throwOnDisconnect = async (ipcEmitter, isSubprocess, {signal}) => {\n\tawait once(ipcEmitter, 'disconnect', {signal});\n\tthrowOnEarlyDisconnect(isSubprocess);\n};\n\nconst throwOnStrictError = async (ipcEmitter, isSubprocess, {signal}) => {\n\tconst [error] = await once(ipcEmitter, 'strict:error', {signal});\n\tthrow getStrictResponseError(error, isSubprocess);\n};\n","import {once, on} from 'node:events';\nimport {validateIpcMethod, disconnect, getStrictResponseError} from './validation.js';\nimport {getIpcEmitter, isConnected} from './forward.js';\nimport {addReference, removeReference} from './reference.js';\n\n// Like `[sub]process.on('message')` but promise-based\nexport const getEachMessage = ({anyProcess, channel, isSubprocess, ipc}, {reference = true} = {}) => loopOnMessages({\n\tanyProcess,\n\tchannel,\n\tisSubprocess,\n\tipc,\n\tshouldAwait: !isSubprocess,\n\treference,\n});\n\n// Same but used internally\nexport const loopOnMessages = ({anyProcess, channel, isSubprocess, ipc, shouldAwait, reference}) => {\n\tvalidateIpcMethod({\n\t\tmethodName: 'getEachMessage',\n\t\tisSubprocess,\n\t\tipc,\n\t\tisConnected: isConnected(anyProcess),\n\t});\n\n\taddReference(channel, reference);\n\tconst ipcEmitter = getIpcEmitter(anyProcess, channel, isSubprocess);\n\tconst controller = new AbortController();\n\tconst state = {};\n\tstopOnDisconnect(anyProcess, ipcEmitter, controller);\n\tabortOnStrictError({\n\t\tipcEmitter,\n\t\tisSubprocess,\n\t\tcontroller,\n\t\tstate,\n\t});\n\treturn iterateOnMessages({\n\t\tanyProcess,\n\t\tchannel,\n\t\tipcEmitter,\n\t\tisSubprocess,\n\t\tshouldAwait,\n\t\tcontroller,\n\t\tstate,\n\t\treference,\n\t});\n};\n\nconst stopOnDisconnect = async (anyProcess, ipcEmitter, controller) => {\n\ttry {\n\t\tawait once(ipcEmitter, 'disconnect', {signal: controller.signal});\n\t\tcontroller.abort();\n\t} catch {}\n};\n\nconst abortOnStrictError = async ({ipcEmitter, isSubprocess, controller, state}) => {\n\ttry {\n\t\tconst [error] = await once(ipcEmitter, 'strict:error', {signal: controller.signal});\n\t\tstate.error = getStrictResponseError(error, isSubprocess);\n\t\tcontroller.abort();\n\t} catch {}\n};\n\nconst iterateOnMessages = async function * ({anyProcess, channel, ipcEmitter, isSubprocess, shouldAwait, controller, state, reference}) {\n\ttry {\n\t\tfor await (const [message] of on(ipcEmitter, 'message', {signal: controller.signal})) {\n\t\t\tthrowIfStrictError(state);\n\t\t\tyield message;\n\t\t}\n\t} catch {\n\t\tthrowIfStrictError(state);\n\t} finally {\n\t\tcontroller.abort();\n\t\tremoveReference(channel, reference);\n\n\t\tif (!isSubprocess) {\n\t\t\tdisconnect(anyProcess);\n\t\t}\n\n\t\tif (shouldAwait) {\n\t\t\tawait anyProcess;\n\t\t}\n\t}\n};\n\nconst throwIfStrictError = ({error}) => {\n\tif (error) {\n\t\tthrow error;\n\t}\n};\n","import process from 'node:process';\nimport {sendMessage} from './send.js';\nimport {getOneMessage} from './get-one.js';\nimport {getEachMessage} from './get-each.js';\nimport {getCancelSignal} from './graceful.js';\n\n// Add promise-based IPC methods in current process\nexport const addIpcMethods = (subprocess, {ipc}) => {\n\tObject.assign(subprocess, getIpcMethods(subprocess, false, ipc));\n};\n\n// Get promise-based IPC in the subprocess\nexport const getIpcExport = () => {\n\tconst anyProcess = process;\n\tconst isSubprocess = true;\n\tconst ipc = process.channel !== undefined;\n\n\treturn {\n\t\t...getIpcMethods(anyProcess, isSubprocess, ipc),\n\t\tgetCancelSignal: getCancelSignal.bind(undefined, {\n\t\t\tanyProcess,\n\t\t\tchannel: anyProcess.channel,\n\t\t\tisSubprocess,\n\t\t\tipc,\n\t\t}),\n\t};\n};\n\n// Retrieve the `ipc` shared by both the current process and the subprocess\nconst getIpcMethods = (anyProcess, isSubprocess, ipc) => ({\n\tsendMessage: sendMessage.bind(undefined, {\n\t\tanyProcess,\n\t\tchannel: anyProcess.channel,\n\t\tisSubprocess,\n\t\tipc,\n\t}),\n\tgetOneMessage: getOneMessage.bind(undefined, {\n\t\tanyProcess,\n\t\tchannel: anyProcess.channel,\n\t\tisSubprocess,\n\t\tipc,\n\t}),\n\tgetEachMessage: getEachMessage.bind(undefined, {\n\t\tanyProcess,\n\t\tchannel: anyProcess.channel,\n\t\tisSubprocess,\n\t\tipc,\n\t}),\n});\n","import {ChildProcess} from 'node:child_process';\nimport {\n\tPassThrough,\n\tReadable,\n\tWritable,\n\tDuplex,\n} from 'node:stream';\nimport {cleanupCustomStreams} from '../stdio/handle.js';\nimport {makeEarlyError} from './result.js';\nimport {handleResult} from './reject.js';\n\n// When the subprocess fails to spawn.\n// We ensure the returned error is always both a promise and a subprocess.\nexport const handleEarlyError = ({error, command, escapedCommand, fileDescriptors, options, startTime, verboseInfo}) => {\n\tcleanupCustomStreams(fileDescriptors);\n\n\tconst subprocess = new ChildProcess();\n\tcreateDummyStreams(subprocess, fileDescriptors);\n\tObject.assign(subprocess, {readable, writable, duplex});\n\n\tconst earlyError = makeEarlyError({\n\t\terror,\n\t\tcommand,\n\t\tescapedCommand,\n\t\tfileDescriptors,\n\t\toptions,\n\t\tstartTime,\n\t\tisSync: false,\n\t});\n\tconst promise = handleDummyPromise(earlyError, verboseInfo, options);\n\treturn {subprocess, promise};\n};\n\nconst createDummyStreams = (subprocess, fileDescriptors) => {\n\tconst stdin = createDummyStream();\n\tconst stdout = createDummyStream();\n\tconst stderr = createDummyStream();\n\tconst extraStdio = Array.from({length: fileDescriptors.length - 3}, createDummyStream);\n\tconst all = createDummyStream();\n\tconst stdio = [stdin, stdout, stderr, ...extraStdio];\n\tObject.assign(subprocess, {\n\t\tstdin,\n\t\tstdout,\n\t\tstderr,\n\t\tall,\n\t\tstdio,\n\t});\n};\n\nconst createDummyStream = () => {\n\tconst stream = new PassThrough();\n\tstream.end();\n\treturn stream;\n};\n\nconst readable = () => new Readable({read() {}});\nconst writable = () => new Writable({write() {}});\nconst duplex = () => new Duplex({read() {}, write() {}});\n\nconst handleDummyPromise = async (error, verboseInfo, options) => handleResult(error, verboseInfo, options);\n","import {createReadStream, createWriteStream} from 'node:fs';\nimport {Buffer} from 'node:buffer';\nimport {Readable, Writable, Duplex} from 'node:stream';\nimport {generatorToStream} from '../transform/generator.js';\nimport {handleStdio} from './handle.js';\nimport {TYPE_TO_MESSAGE} from './type.js';\n\n// Handle `input`, `inputFile`, `stdin`, `stdout` and `stderr` options, before spawning, in async mode\nexport const handleStdioAsync = (options, verboseInfo) => handleStdio(addPropertiesAsync, options, verboseInfo, false);\n\nconst forbiddenIfAsync = ({type, optionName}) => {\n\tthrow new TypeError(`The \\`${optionName}\\` option cannot be ${TYPE_TO_MESSAGE[type]}.`);\n};\n\n// Create streams used internally for piping when using specific values for the `std*` options, in async mode.\n// For example, `stdout: {file}` creates a file stream, which is piped from/to.\nconst addProperties = {\n\tfileNumber: forbiddenIfAsync,\n\tgenerator: generatorToStream,\n\tasyncGenerator: generatorToStream,\n\tnodeStream: ({value}) => ({stream: value}),\n\twebTransform({value: {transform, writableObjectMode, readableObjectMode}}) {\n\t\tconst objectMode = writableObjectMode || readableObjectMode;\n\t\tconst stream = Duplex.fromWeb(transform, {objectMode});\n\t\treturn {stream};\n\t},\n\tduplex: ({value: {transform}}) => ({stream: transform}),\n\tnative() {},\n};\n\nconst addPropertiesAsync = {\n\tinput: {\n\t\t...addProperties,\n\t\tfileUrl: ({value}) => ({stream: createReadStream(value)}),\n\t\tfilePath: ({value: {file}}) => ({stream: createReadStream(file)}),\n\t\twebStream: ({value}) => ({stream: Readable.fromWeb(value)}),\n\t\titerable: ({value}) => ({stream: Readable.from(value)}),\n\t\tasyncIterable: ({value}) => ({stream: Readable.from(value)}),\n\t\tstring: ({value}) => ({stream: Readable.from(value)}),\n\t\tuint8Array: ({value}) => ({stream: Readable.from(Buffer.from(value))}),\n\t},\n\toutput: {\n\t\t...addProperties,\n\t\tfileUrl: ({value}) => ({stream: createWriteStream(value)}),\n\t\tfilePath: ({value: {file}}) => ({stream: createWriteStream(file)}),\n\t\twebStream: ({value}) => ({stream: Writable.fromWeb(value)}),\n\t\titerable: forbiddenIfAsync,\n\t\tasyncIterable: forbiddenIfAsync,\n\t\tstring: forbiddenIfAsync,\n\t\tuint8Array: forbiddenIfAsync,\n\t},\n};\n","import {finished} from 'node:stream/promises';\nimport {isStandardStream} from '../utils/standard-stream.js';\n\n// Similar to `Stream.pipeline(source, destination)`, but does not destroy standard streams\nexport const pipeStreams = (source, destination) => {\n\tsource.pipe(destination);\n\tonSourceFinish(source, destination);\n\tonDestinationFinish(source, destination);\n};\n\n// `source.pipe(destination)` makes `destination` end when `source` ends.\n// But it does not propagate aborts or errors. This function does it.\nconst onSourceFinish = async (source, destination) => {\n\tif (isStandardStream(source) || isStandardStream(destination)) {\n\t\treturn;\n\t}\n\n\ttry {\n\t\tawait finished(source, {cleanup: true, readable: true, writable: false});\n\t} catch {}\n\n\tendDestinationStream(destination);\n};\n\nexport const endDestinationStream = destination => {\n\tif (destination.writable) {\n\t\tdestination.end();\n\t}\n};\n\n// We do the same thing in the other direction as well.\nconst onDestinationFinish = async (source, destination) => {\n\tif (isStandardStream(source) || isStandardStream(destination)) {\n\t\treturn;\n\t}\n\n\ttry {\n\t\tawait finished(destination, {cleanup: true, readable: false, writable: true});\n\t} catch {}\n\n\tabortSourceStream(source);\n};\n\nexport const abortSourceStream = source => {\n\tif (source.readable) {\n\t\tsource.destroy();\n\t}\n};\n","import mergeStreams from '@sindresorhus/merge-streams';\nimport {isStandardStream} from '../utils/standard-stream.js';\nimport {incrementMaxListeners} from '../utils/max-listeners.js';\nimport {TRANSFORM_TYPES} from '../stdio/type.js';\nimport {pipeStreams} from './pipeline.js';\n\n// Handle `input`, `inputFile`, `stdin`, `stdout` and `stderr` options, after spawning, in async mode\n// When multiple input streams are used, we merge them to ensure the output stream ends only once each input stream has ended\nexport const pipeOutputAsync = (subprocess, fileDescriptors, controller) => {\n\tconst pipeGroups = new Map();\n\n\tfor (const [fdNumber, {stdioItems, direction}] of Object.entries(fileDescriptors)) {\n\t\tfor (const {stream} of stdioItems.filter(({type}) => TRANSFORM_TYPES.has(type))) {\n\t\t\tpipeTransform(subprocess, stream, direction, fdNumber);\n\t\t}\n\n\t\tfor (const {stream} of stdioItems.filter(({type}) => !TRANSFORM_TYPES.has(type))) {\n\t\t\tpipeStdioItem({\n\t\t\t\tsubprocess,\n\t\t\t\tstream,\n\t\t\t\tdirection,\n\t\t\t\tfdNumber,\n\t\t\t\tpipeGroups,\n\t\t\t\tcontroller,\n\t\t\t});\n\t\t}\n\t}\n\n\tfor (const [outputStream, inputStreams] of pipeGroups.entries()) {\n\t\tconst inputStream = inputStreams.length === 1 ? inputStreams[0] : mergeStreams(inputStreams);\n\t\tpipeStreams(inputStream, outputStream);\n\t}\n};\n\n// When using transforms, `subprocess.stdin|stdout|stderr|stdio` is directly mutated\nconst pipeTransform = (subprocess, stream, direction, fdNumber) => {\n\tif (direction === 'output') {\n\t\tpipeStreams(subprocess.stdio[fdNumber], stream);\n\t} else {\n\t\tpipeStreams(stream, subprocess.stdio[fdNumber]);\n\t}\n\n\tconst streamProperty = SUBPROCESS_STREAM_PROPERTIES[fdNumber];\n\tif (streamProperty !== undefined) {\n\t\tsubprocess[streamProperty] = stream;\n\t}\n\n\tsubprocess.stdio[fdNumber] = stream;\n};\n\nconst SUBPROCESS_STREAM_PROPERTIES = ['stdin', 'stdout', 'stderr'];\n\n// Most `std*` option values involve piping `subprocess.std*` to a stream.\n// The stream is either passed by the user or created internally.\nconst pipeStdioItem = ({subprocess, stream, direction, fdNumber, pipeGroups, controller}) => {\n\tif (stream === undefined) {\n\t\treturn;\n\t}\n\n\tsetStandardStreamMaxListeners(stream, controller);\n\n\tconst [inputStream, outputStream] = direction === 'output'\n\t\t? [stream, subprocess.stdio[fdNumber]]\n\t\t: [subprocess.stdio[fdNumber], stream];\n\tconst outputStreams = pipeGroups.get(inputStream) ?? [];\n\tpipeGroups.set(inputStream, [...outputStreams, outputStream]);\n};\n\n// Multiple subprocesses might be piping from/to `process.std*` at the same time.\n// This is not necessarily an error and should not print a `maxListeners` warning.\nconst setStandardStreamMaxListeners = (stream, {signal}) => {\n\tif (isStandardStream(stream)) {\n\t\tincrementMaxListeners(stream, MAX_LISTENERS_INCREMENT, signal);\n\t}\n};\n\n// `source.pipe(destination)` adds at most 1 listener for each event.\n// If `stdin` option is an array, the values might be combined with `merge-streams`.\n// That library also listens for `source` end, which adds 1 more listener.\nconst MAX_LISTENERS_INCREMENT = 2;\n","/**\n * This is not the set of all possible signals.\n *\n * It IS, however, the set of all signals that trigger\n * an exit on either Linux or BSD systems. Linux is a\n * superset of the signal names supported on BSD, and\n * the unknown signals just fail to register, so we can\n * catch that easily enough.\n *\n * Windows signals are a different set, since there are\n * signals that terminate Windows processes, but don't\n * terminate (or don't even exist) on Posix systems.\n *\n * Don't bother with SIGKILL. It's uncatchable, which\n * means that we can't fire any callbacks anyway.\n *\n * If a user does happen to register a handler on a non-\n * fatal signal like SIGWINCH or something, and then\n * exit, it'll end up firing `process.emit('exit')`, so\n * the handler will be fired anyway.\n *\n * SIGBUS, SIGFPE, SIGSEGV and SIGILL, when not raised\n * artificially, inherently leave the process in a\n * state from which it is not safe to try and enter JS\n * listeners.\n */\nexport const signals = [];\nsignals.push('SIGHUP', 'SIGINT', 'SIGTERM');\nif (process.platform !== 'win32') {\n signals.push('SIGALRM', 'SIGABRT', 'SIGVTALRM', 'SIGXCPU', 'SIGXFSZ', 'SIGUSR2', 'SIGTRAP', 'SIGSYS', 'SIGQUIT', 'SIGIOT'\n // should detect profiler and enable/disable accordingly.\n // see #21\n // 'SIGPROF'\n );\n}\nif (process.platform === 'linux') {\n signals.push('SIGIO', 'SIGPOLL', 'SIGPWR', 'SIGSTKFLT');\n}\n//# sourceMappingURL=signals.js.map","// Note: since nyc uses this module to output coverage, any lines\n// that are in the direct sync flow of nyc's outputCoverage are\n// ignored, since we can never get coverage for them.\n// grab a reference to node's real process object right away\nimport { signals } from './signals.js';\nexport { signals };\nconst processOk = (process) => !!process &&\n typeof process === 'object' &&\n typeof process.removeListener === 'function' &&\n typeof process.emit === 'function' &&\n typeof process.reallyExit === 'function' &&\n typeof process.listeners === 'function' &&\n typeof process.kill === 'function' &&\n typeof process.pid === 'number' &&\n typeof process.on === 'function';\nconst kExitEmitter = Symbol.for('signal-exit emitter');\nconst global = globalThis;\nconst ObjectDefineProperty = Object.defineProperty.bind(Object);\n// teeny special purpose ee\nclass Emitter {\n emitted = {\n afterExit: false,\n exit: false,\n };\n listeners = {\n afterExit: [],\n exit: [],\n };\n count = 0;\n id = Math.random();\n constructor() {\n if (global[kExitEmitter]) {\n return global[kExitEmitter];\n }\n ObjectDefineProperty(global, kExitEmitter, {\n value: this,\n writable: false,\n enumerable: false,\n configurable: false,\n });\n }\n on(ev, fn) {\n this.listeners[ev].push(fn);\n }\n removeListener(ev, fn) {\n const list = this.listeners[ev];\n const i = list.indexOf(fn);\n /* c8 ignore start */\n if (i === -1) {\n return;\n }\n /* c8 ignore stop */\n if (i === 0 && list.length === 1) {\n list.length = 0;\n }\n else {\n list.splice(i, 1);\n }\n }\n emit(ev, code, signal) {\n if (this.emitted[ev]) {\n return false;\n }\n this.emitted[ev] = true;\n let ret = false;\n for (const fn of this.listeners[ev]) {\n ret = fn(code, signal) === true || ret;\n }\n if (ev === 'exit') {\n ret = this.emit('afterExit', code, signal) || ret;\n }\n return ret;\n }\n}\nclass SignalExitBase {\n}\nconst signalExitWrap = (handler) => {\n return {\n onExit(cb, opts) {\n return handler.onExit(cb, opts);\n },\n load() {\n return handler.load();\n },\n unload() {\n return handler.unload();\n },\n };\n};\nclass SignalExitFallback extends SignalExitBase {\n onExit() {\n return () => { };\n }\n load() { }\n unload() { }\n}\nclass SignalExit extends SignalExitBase {\n // \"SIGHUP\" throws an `ENOSYS` error on Windows,\n // so use a supported signal instead\n /* c8 ignore start */\n #hupSig = process.platform === 'win32' ? 'SIGINT' : 'SIGHUP';\n /* c8 ignore stop */\n #emitter = new Emitter();\n #process;\n #originalProcessEmit;\n #originalProcessReallyExit;\n #sigListeners = {};\n #loaded = false;\n constructor(process) {\n super();\n this.#process = process;\n // { <signal>: <listener fn>, ... }\n this.#sigListeners = {};\n for (const sig of signals) {\n this.#sigListeners[sig] = () => {\n // If there are no other listeners, an exit is coming!\n // Simplest way: remove us and then re-send the signal.\n // We know that this will kill the process, so we can\n // safely emit now.\n const listeners = this.#process.listeners(sig);\n let { count } = this.#emitter;\n // This is a workaround for the fact that signal-exit v3 and signal\n // exit v4 are not aware of each other, and each will attempt to let\n // the other handle it, so neither of them do. To correct this, we\n // detect if we're the only handler *except* for previous versions\n // of signal-exit, and increment by the count of listeners it has\n // created.\n /* c8 ignore start */\n const p = process;\n if (typeof p.__signal_exit_emitter__ === 'object' &&\n typeof p.__signal_exit_emitter__.count === 'number') {\n count += p.__signal_exit_emitter__.count;\n }\n /* c8 ignore stop */\n if (listeners.length === count) {\n this.unload();\n const ret = this.#emitter.emit('exit', null, sig);\n /* c8 ignore start */\n const s = sig === 'SIGHUP' ? this.#hupSig : sig;\n if (!ret)\n process.kill(process.pid, s);\n /* c8 ignore stop */\n }\n };\n }\n this.#originalProcessReallyExit = process.reallyExit;\n this.#originalProcessEmit = process.emit;\n }\n onExit(cb, opts) {\n /* c8 ignore start */\n if (!processOk(this.#process)) {\n return () => { };\n }\n /* c8 ignore stop */\n if (this.#loaded === false) {\n this.load();\n }\n const ev = opts?.alwaysLast ? 'afterExit' : 'exit';\n this.#emitter.on(ev, cb);\n return () => {\n this.#emitter.removeListener(ev, cb);\n if (this.#emitter.listeners['exit'].length === 0 &&\n this.#emitter.listeners['afterExit'].length === 0) {\n this.unload();\n }\n };\n }\n load() {\n if (this.#loaded) {\n return;\n }\n this.#loaded = true;\n // This is the number of onSignalExit's that are in play.\n // It's important so that we can count the correct number of\n // listeners on signals, and don't wait for the other one to\n // handle it instead of us.\n this.#emitter.count += 1;\n for (const sig of signals) {\n try {\n const fn = this.#sigListeners[sig];\n if (fn)\n this.#process.on(sig, fn);\n }\n catch (_) { }\n }\n this.#process.emit = (ev, ...a) => {\n return this.#processEmit(ev, ...a);\n };\n this.#process.reallyExit = (code) => {\n return this.#processReallyExit(code);\n };\n }\n unload() {\n if (!this.#loaded) {\n return;\n }\n this.#loaded = false;\n signals.forEach(sig => {\n const listener = this.#sigListeners[sig];\n /* c8 ignore start */\n if (!listener) {\n throw new Error('Listener not defined for signal: ' + sig);\n }\n /* c8 ignore stop */\n try {\n this.#process.removeListener(sig, listener);\n /* c8 ignore start */\n }\n catch (_) { }\n /* c8 ignore stop */\n });\n this.#process.emit = this.#originalProcessEmit;\n this.#process.reallyExit = this.#originalProcessReallyExit;\n this.#emitter.count -= 1;\n }\n #processReallyExit(code) {\n /* c8 ignore start */\n if (!processOk(this.#process)) {\n return 0;\n }\n this.#process.exitCode = code || 0;\n /* c8 ignore stop */\n this.#emitter.emit('exit', this.#process.exitCode, null);\n return this.#originalProcessReallyExit.call(this.#process, this.#process.exitCode);\n }\n #processEmit(ev, ...args) {\n const og = this.#originalProcessEmit;\n if (ev === 'exit' && processOk(this.#process)) {\n if (typeof args[0] === 'number') {\n this.#process.exitCode = args[0];\n /* c8 ignore start */\n }\n /* c8 ignore start */\n const ret = og.call(this.#process, ev, ...args);\n /* c8 ignore start */\n this.#emitter.emit('exit', this.#process.exitCode, null);\n /* c8 ignore stop */\n return ret;\n }\n else {\n return og.call(this.#process, ev, ...args);\n }\n }\n}\nconst process = globalThis.process;\n// wrap so that we call the method on the actual handler, without\n// exporting it directly.\nexport const { \n/**\n * Called when the process is exiting, whether via signal, explicit\n * exit, or running out of stuff to do.\n *\n * If the global process object is not suitable for instrumentation,\n * then this will be a no-op.\n *\n * Returns a function that may be used to unload signal-exit.\n */\nonExit, \n/**\n * Load the listeners. Likely you never need to call this, unless\n * doing a rather deep integration with signal-exit functionality.\n * Mostly exposed for the benefit of testing.\n *\n * @internal\n */\nload, \n/**\n * Unload the listeners. Likely you never need to call this, unless\n * doing a rather deep integration with signal-exit functionality.\n * Mostly exposed for the benefit of testing.\n *\n * @internal\n */\nunload, } = signalExitWrap(processOk(process) ? new SignalExit(process) : new SignalExitFallback());\n//# sourceMappingURL=index.js.map","import {addAbortListener} from 'node:events';\nimport {onExit} from 'signal-exit';\n\n// If the `cleanup` option is used, call `subprocess.kill()` when the parent process exits\nexport const cleanupOnExit = (subprocess, {cleanup, detached}, {signal}) => {\n\tif (!cleanup || detached) {\n\t\treturn;\n\t}\n\n\tconst removeExitHandler = onExit(() => {\n\t\tsubprocess.kill();\n\t});\n\taddAbortListener(signal, () => {\n\t\tremoveExitHandler();\n\t});\n};\n","import {normalizeParameters} from '../methods/parameters.js';\nimport {getStartTime} from '../return/duration.js';\nimport {SUBPROCESS_OPTIONS, getToStream, getFromStream} from '../arguments/fd-options.js';\nimport {isDenoExecPath} from '../arguments/file-url.js';\n\n// Normalize and validate arguments passed to `source.pipe(destination)`\nexport const normalizePipeArguments = ({source, sourcePromise, boundOptions, createNested}, ...pipeArguments) => {\n\tconst startTime = getStartTime();\n\tconst {\n\t\tdestination,\n\t\tdestinationStream,\n\t\tdestinationError,\n\t\tfrom,\n\t\tunpipeSignal,\n\t} = getDestinationStream(boundOptions, createNested, pipeArguments);\n\tconst {sourceStream, sourceError} = getSourceStream(source, from);\n\tconst {options: sourceOptions, fileDescriptors} = SUBPROCESS_OPTIONS.get(source);\n\treturn {\n\t\tsourcePromise,\n\t\tsourceStream,\n\t\tsourceOptions,\n\t\tsourceError,\n\t\tdestination,\n\t\tdestinationStream,\n\t\tdestinationError,\n\t\tunpipeSignal,\n\t\tfileDescriptors,\n\t\tstartTime,\n\t};\n};\n\nconst getDestinationStream = (boundOptions, createNested, pipeArguments) => {\n\ttry {\n\t\tconst {\n\t\t\tdestination,\n\t\t\tpipeOptions: {from, to, unpipeSignal} = {},\n\t\t} = getDestination(boundOptions, createNested, ...pipeArguments);\n\t\tconst destinationStream = getToStream(destination, to);\n\t\treturn {\n\t\t\tdestination,\n\t\t\tdestinationStream,\n\t\t\tfrom,\n\t\t\tunpipeSignal,\n\t\t};\n\t} catch (error) {\n\t\treturn {destinationError: error};\n\t}\n};\n\n// Piping subprocesses can use three syntaxes:\n// - source.pipe('command', commandArguments, pipeOptionsOrDestinationOptions)\n// - source.pipe`command commandArgument` or source.pipe(pipeOptionsOrDestinationOptions)`command commandArgument`\n// - source.pipe(execa(...), pipeOptions)\nconst getDestination = (boundOptions, createNested, firstArgument, ...pipeArguments) => {\n\tif (Array.isArray(firstArgument)) {\n\t\tconst destination = createNested(mapDestinationArguments, boundOptions)(firstArgument, ...pipeArguments);\n\t\treturn {destination, pipeOptions: boundOptions};\n\t}\n\n\tif (typeof firstArgument === 'string' || firstArgument instanceof URL || isDenoExecPath(firstArgument)) {\n\t\tif (Object.keys(boundOptions).length > 0) {\n\t\t\tthrow new TypeError('Please use .pipe(\"file\", ..., options) or .pipe(execa(\"file\", ..., options)) instead of .pipe(options)(\"file\", ...).');\n\t\t}\n\n\t\tconst [rawFile, rawArguments, rawOptions] = normalizeParameters(firstArgument, ...pipeArguments);\n\t\tconst destination = createNested(mapDestinationArguments)(rawFile, rawArguments, rawOptions);\n\t\treturn {destination, pipeOptions: rawOptions};\n\t}\n\n\tif (SUBPROCESS_OPTIONS.has(firstArgument)) {\n\t\tif (Object.keys(boundOptions).length > 0) {\n\t\t\tthrow new TypeError('Please use .pipe(options)`command` or .pipe($(options)`command`) instead of .pipe(options)($`command`).');\n\t\t}\n\n\t\treturn {destination: firstArgument, pipeOptions: pipeArguments[0]};\n\t}\n\n\tthrow new TypeError(`The first argument must be a template string, an options object, or an Execa subprocess: ${firstArgument}`);\n};\n\n// Force `stdin: 'pipe'` with the destination subprocess\nconst mapDestinationArguments = ({options}) => ({options: {...options, stdin: 'pipe', piped: true}});\n\nconst getSourceStream = (source, from) => {\n\ttry {\n\t\tconst sourceStream = getFromStream(source, from);\n\t\treturn {sourceStream};\n\t} catch (error) {\n\t\treturn {sourceError: error};\n\t}\n};\n","import {makeEarlyError} from '../return/result.js';\nimport {abortSourceStream, endDestinationStream} from '../io/pipeline.js';\n\n// When passing invalid arguments to `source.pipe()`, throw asynchronously.\n// We also abort both subprocesses.\nexport const handlePipeArgumentsError = ({\n\tsourceStream,\n\tsourceError,\n\tdestinationStream,\n\tdestinationError,\n\tfileDescriptors,\n\tsourceOptions,\n\tstartTime,\n}) => {\n\tconst error = getPipeArgumentsError({\n\t\tsourceStream,\n\t\tsourceError,\n\t\tdestinationStream,\n\t\tdestinationError,\n\t});\n\tif (error !== undefined) {\n\t\tthrow createNonCommandError({\n\t\t\terror,\n\t\t\tfileDescriptors,\n\t\t\tsourceOptions,\n\t\t\tstartTime,\n\t\t});\n\t}\n};\n\nconst getPipeArgumentsError = ({sourceStream, sourceError, destinationStream, destinationError}) => {\n\tif (sourceError !== undefined && destinationError !== undefined) {\n\t\treturn destinationError;\n\t}\n\n\tif (destinationError !== undefined) {\n\t\tabortSourceStream(sourceStream);\n\t\treturn destinationError;\n\t}\n\n\tif (sourceError !== undefined) {\n\t\tendDestinationStream(destinationStream);\n\t\treturn sourceError;\n\t}\n};\n\n// Specific error return value when passing invalid arguments to `subprocess.pipe()` or when using `unpipeSignal`\nexport const createNonCommandError = ({error, fileDescriptors, sourceOptions, startTime}) => makeEarlyError({\n\terror,\n\tcommand: PIPE_COMMAND_MESSAGE,\n\tescapedCommand: PIPE_COMMAND_MESSAGE,\n\tfileDescriptors,\n\toptions: sourceOptions,\n\tstartTime,\n\tisSync: false,\n});\n\nconst PIPE_COMMAND_MESSAGE = 'source.pipe(destination)';\n","// Like Bash, we await both subprocesses. This is unlike some other shells which only await the destination subprocess.\n// Like Bash with the `pipefail` option, if either subprocess fails, the whole pipe fails.\n// Like Bash, if both subprocesses fail, we return the failure of the destination.\n// This ensures both subprocesses' errors are present, using `error.pipedFrom`.\nexport const waitForBothSubprocesses = async subprocessPromises => {\n\tconst [\n\t\t{status: sourceStatus, reason: sourceReason, value: sourceResult = sourceReason},\n\t\t{status: destinationStatus, reason: destinationReason, value: destinationResult = destinationReason},\n\t] = await subprocessPromises;\n\n\tif (!destinationResult.pipedFrom.includes(sourceResult)) {\n\t\tdestinationResult.pipedFrom.push(sourceResult);\n\t}\n\n\tif (destinationStatus === 'rejected') {\n\t\tthrow destinationResult;\n\t}\n\n\tif (sourceStatus === 'rejected') {\n\t\tthrow sourceResult;\n\t}\n\n\treturn destinationResult;\n};\n","import {finished} from 'node:stream/promises';\nimport mergeStreams from '@sindresorhus/merge-streams';\nimport {incrementMaxListeners} from '../utils/max-listeners.js';\nimport {pipeStreams} from '../io/pipeline.js';\n\n// The piping behavior is like Bash.\n// In particular, when one subprocess exits, the other is not terminated by a signal.\n// Instead, its stdout (for the source) or stdin (for the destination) closes.\n// If the subprocess uses it, it will make it error with SIGPIPE or EPIPE (for the source) or end (for the destination).\n// If it does not use it, it will continue running.\n// This allows for subprocesses to gracefully exit and lower the coupling between subprocesses.\nexport const pipeSubprocessStream = (sourceStream, destinationStream, maxListenersController) => {\n\tconst mergedStream = MERGED_STREAMS.has(destinationStream)\n\t\t? pipeMoreSubprocessStream(sourceStream, destinationStream)\n\t\t: pipeFirstSubprocessStream(sourceStream, destinationStream);\n\tincrementMaxListeners(sourceStream, SOURCE_LISTENERS_PER_PIPE, maxListenersController.signal);\n\tincrementMaxListeners(destinationStream, DESTINATION_LISTENERS_PER_PIPE, maxListenersController.signal);\n\tcleanupMergedStreamsMap(destinationStream);\n\treturn mergedStream;\n};\n\n// We use `merge-streams` to allow for multiple sources to pipe to the same destination.\nconst pipeFirstSubprocessStream = (sourceStream, destinationStream) => {\n\tconst mergedStream = mergeStreams([sourceStream]);\n\tpipeStreams(mergedStream, destinationStream);\n\tMERGED_STREAMS.set(destinationStream, mergedStream);\n\treturn mergedStream;\n};\n\nconst pipeMoreSubprocessStream = (sourceStream, destinationStream) => {\n\tconst mergedStream = MERGED_STREAMS.get(destinationStream);\n\tmergedStream.add(sourceStream);\n\treturn mergedStream;\n};\n\nconst cleanupMergedStreamsMap = async destinationStream => {\n\ttry {\n\t\tawait finished(destinationStream, {cleanup: true, readable: false, writable: true});\n\t} catch {}\n\n\tMERGED_STREAMS.delete(destinationStream);\n};\n\nconst MERGED_STREAMS = new WeakMap();\n\n// Number of listeners set up on `sourceStream` by each `sourceStream.pipe(destinationStream)`\n// Those are added by `merge-streams`\nconst SOURCE_LISTENERS_PER_PIPE = 2;\n// Number of listeners set up on `destinationStream` by each `sourceStream.pipe(destinationStream)`\n// Those are added by `finished()` in `cleanupMergedStreamsMap()`\nconst DESTINATION_LISTENERS_PER_PIPE = 1;\n","import {aborted} from 'node:util';\nimport {createNonCommandError} from './throw.js';\n\n// When passing an `unpipeSignal` option, abort piping when the signal is aborted.\n// However, do not terminate the subprocesses.\nexport const unpipeOnAbort = (unpipeSignal, unpipeContext) => unpipeSignal === undefined\n\t? []\n\t: [unpipeOnSignalAbort(unpipeSignal, unpipeContext)];\n\nconst unpipeOnSignalAbort = async (unpipeSignal, {sourceStream, mergedStream, fileDescriptors, sourceOptions, startTime}) => {\n\tawait aborted(unpipeSignal, sourceStream);\n\tawait mergedStream.remove(sourceStream);\n\tconst error = new Error('Pipe canceled by `unpipeSignal` option.');\n\tthrow createNonCommandError({\n\t\terror,\n\t\tfileDescriptors,\n\t\tsourceOptions,\n\t\tstartTime,\n\t});\n};\n","import isPlainObject from 'is-plain-obj';\nimport {normalizePipeArguments} from './pipe-arguments.js';\nimport {handlePipeArgumentsError} from './throw.js';\nimport {waitForBothSubprocesses} from './sequence.js';\nimport {pipeSubprocessStream} from './streaming.js';\nimport {unpipeOnAbort} from './abort.js';\n\n// Pipe a subprocess' `stdout`/`stderr`/`stdio` into another subprocess' `stdin`\nexport const pipeToSubprocess = (sourceInfo, ...pipeArguments) => {\n\tif (isPlainObject(pipeArguments[0])) {\n\t\treturn pipeToSubprocess.bind(undefined, {\n\t\t\t...sourceInfo,\n\t\t\tboundOptions: {...sourceInfo.boundOptions, ...pipeArguments[0]},\n\t\t});\n\t}\n\n\tconst {destination, ...normalizedInfo} = normalizePipeArguments(sourceInfo, ...pipeArguments);\n\tconst promise = handlePipePromise({...normalizedInfo, destination});\n\tpromise.pipe = pipeToSubprocess.bind(undefined, {\n\t\t...sourceInfo,\n\t\tsource: destination,\n\t\tsourcePromise: promise,\n\t\tboundOptions: {},\n\t});\n\treturn promise;\n};\n\n// Asynchronous logic when piping subprocesses\nconst handlePipePromise = async ({\n\tsourcePromise,\n\tsourceStream,\n\tsourceOptions,\n\tsourceError,\n\tdestination,\n\tdestinationStream,\n\tdestinationError,\n\tunpipeSignal,\n\tfileDescriptors,\n\tstartTime,\n}) => {\n\tconst subprocessPromises = getSubprocessPromises(sourcePromise, destination);\n\thandlePipeArgumentsError({\n\t\tsourceStream,\n\t\tsourceError,\n\t\tdestinationStream,\n\t\tdestinationError,\n\t\tfileDescriptors,\n\t\tsourceOptions,\n\t\tstartTime,\n\t});\n\tconst maxListenersController = new AbortController();\n\ttry {\n\t\tconst mergedStream = pipeSubprocessStream(sourceStream, destinationStream, maxListenersController);\n\t\treturn await Promise.race([\n\t\t\twaitForBothSubprocesses(subprocessPromises),\n\t\t\t...unpipeOnAbort(unpipeSignal, {\n\t\t\t\tsourceStream,\n\t\t\t\tmergedStream,\n\t\t\t\tsourceOptions,\n\t\t\t\tfileDescriptors,\n\t\t\t\tstartTime,\n\t\t\t}),\n\t\t]);\n\t} finally {\n\t\tmaxListenersController.abort();\n\t}\n};\n\n// `.pipe()` awaits the subprocess promises.\n// When invalid arguments are passed to `.pipe()`, we throw an error, which prevents awaiting them.\n// We need to ensure this does not create unhandled rejections.\nconst getSubprocessPromises = (sourcePromise, destination) => Promise.allSettled([sourcePromise, destination]);\n","import {on} from 'node:events';\nimport {getDefaultHighWaterMark} from 'node:stream';\nimport {getEncodingTransformGenerator} from '../transform/encoding-transform.js';\nimport {getSplitLinesGenerator} from '../transform/split.js';\nimport {transformChunkSync, finalChunksSync} from '../transform/run-sync.js';\n\n// Iterate over lines of `subprocess.stdout`, used by `subprocess.readable|duplex|iterable()`\nexport const iterateOnSubprocessStream = ({subprocessStdout, subprocess, binary, shouldEncode, encoding, preserveNewlines}) => {\n\tconst controller = new AbortController();\n\tstopReadingOnExit(subprocess, controller);\n\treturn iterateOnStream({\n\t\tstream: subprocessStdout,\n\t\tcontroller,\n\t\tbinary,\n\t\tshouldEncode: !subprocessStdout.readableObjectMode && shouldEncode,\n\t\tencoding,\n\t\tshouldSplit: !subprocessStdout.readableObjectMode,\n\t\tpreserveNewlines,\n\t});\n};\n\nconst stopReadingOnExit = async (subprocess, controller) => {\n\ttry {\n\t\tawait subprocess;\n\t} catch {} finally {\n\t\tcontroller.abort();\n\t}\n};\n\n// Iterate over lines of `subprocess.stdout`, used by `result.stdout` and the `verbose: 'full'` option.\n// Applies the `lines` and `encoding` options.\nexport const iterateForResult = ({stream, onStreamEnd, lines, encoding, stripFinalNewline, allMixed}) => {\n\tconst controller = new AbortController();\n\tstopReadingOnStreamEnd(onStreamEnd, controller, stream);\n\tconst objectMode = stream.readableObjectMode && !allMixed;\n\treturn iterateOnStream({\n\t\tstream,\n\t\tcontroller,\n\t\tbinary: encoding === 'buffer',\n\t\tshouldEncode: !objectMode,\n\t\tencoding,\n\t\tshouldSplit: !objectMode && lines,\n\t\tpreserveNewlines: !stripFinalNewline,\n\t});\n};\n\nconst stopReadingOnStreamEnd = async (onStreamEnd, controller, stream) => {\n\ttry {\n\t\tawait onStreamEnd;\n\t} catch {\n\t\tstream.destroy();\n\t} finally {\n\t\tcontroller.abort();\n\t}\n};\n\nconst iterateOnStream = ({stream, controller, binary, shouldEncode, encoding, shouldSplit, preserveNewlines}) => {\n\tconst onStdoutChunk = on(stream, 'data', {\n\t\tsignal: controller.signal,\n\t\thighWaterMark: HIGH_WATER_MARK,\n\t\t// Backward compatibility with older name for this option\n\t\t// See https://github.com/nodejs/node/pull/52080#discussion_r1525227861\n\t\t// @todo Remove after removing support for Node 21\n\t\thighWatermark: HIGH_WATER_MARK,\n\t});\n\treturn iterateOnData({\n\t\tonStdoutChunk,\n\t\tcontroller,\n\t\tbinary,\n\t\tshouldEncode,\n\t\tencoding,\n\t\tshouldSplit,\n\t\tpreserveNewlines,\n\t});\n};\n\nexport const DEFAULT_OBJECT_HIGH_WATER_MARK = getDefaultHighWaterMark(true);\n\n// The `highWaterMark` of `events.on()` is measured in number of events, not in bytes.\n// Not knowing the average amount of bytes per `data` event, we use the same heuristic as streams in objectMode, since they have the same issue.\n// Therefore, we use the value of `getDefaultHighWaterMark(true)`.\n// Note: this option does not exist on Node 18, but this is ok since the logic works without it. It just consumes more memory.\nconst HIGH_WATER_MARK = DEFAULT_OBJECT_HIGH_WATER_MARK;\n\nconst iterateOnData = async function * ({onStdoutChunk, controller, binary, shouldEncode, encoding, shouldSplit, preserveNewlines}) {\n\tconst generators = getGenerators({\n\t\tbinary,\n\t\tshouldEncode,\n\t\tencoding,\n\t\tshouldSplit,\n\t\tpreserveNewlines,\n\t});\n\n\ttry {\n\t\tfor await (const [chunk] of onStdoutChunk) {\n\t\t\tyield * transformChunkSync(chunk, generators, 0);\n\t\t}\n\t} catch (error) {\n\t\tif (!controller.signal.aborted) {\n\t\t\tthrow error;\n\t\t}\n\t} finally {\n\t\tyield * finalChunksSync(generators);\n\t}\n};\n\nconst getGenerators = ({binary, shouldEncode, encoding, shouldSplit, preserveNewlines}) => [\n\tgetEncodingTransformGenerator(binary, encoding, !shouldEncode),\n\tgetSplitLinesGenerator(binary, preserveNewlines, !shouldSplit, {}),\n].filter(Boolean);\n","import {setImmediate} from 'node:timers/promises';\nimport getStream, {getStreamAsArrayBuffer, getStreamAsArray} from 'get-stream';\nimport {isArrayBuffer} from '../utils/uint-array.js';\nimport {shouldLogOutput, logLines} from '../verbose/output.js';\nimport {iterateForResult} from './iterate.js';\nimport {handleMaxBuffer} from './max-buffer.js';\nimport {getStripFinalNewline} from './strip-newline.js';\n\n// Retrieve `result.stdout|stderr|all|stdio[*]`\nexport const getStreamOutput = async ({stream, onStreamEnd, fdNumber, encoding, buffer, maxBuffer, lines, allMixed, stripFinalNewline, verboseInfo, streamInfo}) => {\n\tconst logPromise = logOutputAsync({\n\t\tstream,\n\t\tonStreamEnd,\n\t\tfdNumber,\n\t\tencoding,\n\t\tallMixed,\n\t\tverboseInfo,\n\t\tstreamInfo,\n\t});\n\n\tif (!buffer) {\n\t\tawait Promise.all([resumeStream(stream), logPromise]);\n\t\treturn;\n\t}\n\n\tconst stripFinalNewlineValue = getStripFinalNewline(stripFinalNewline, fdNumber);\n\tconst iterable = iterateForResult({\n\t\tstream,\n\t\tonStreamEnd,\n\t\tlines,\n\t\tencoding,\n\t\tstripFinalNewline: stripFinalNewlineValue,\n\t\tallMixed,\n\t});\n\tconst [output] = await Promise.all([\n\t\tgetStreamContents({\n\t\t\tstream,\n\t\t\titerable,\n\t\t\tfdNumber,\n\t\t\tencoding,\n\t\t\tmaxBuffer,\n\t\t\tlines,\n\t\t}),\n\t\tlogPromise,\n\t]);\n\treturn output;\n};\n\nconst logOutputAsync = async ({stream, onStreamEnd, fdNumber, encoding, allMixed, verboseInfo, streamInfo: {fileDescriptors}}) => {\n\tif (!shouldLogOutput({\n\t\tstdioItems: fileDescriptors[fdNumber]?.stdioItems,\n\t\tencoding,\n\t\tverboseInfo,\n\t\tfdNumber,\n\t})) {\n\t\treturn;\n\t}\n\n\tconst linesIterable = iterateForResult({\n\t\tstream,\n\t\tonStreamEnd,\n\t\tlines: true,\n\t\tencoding,\n\t\tstripFinalNewline: true,\n\t\tallMixed,\n\t});\n\tawait logLines(linesIterable, stream, fdNumber, verboseInfo);\n};\n\n// When using `buffer: false`, users need to read `subprocess.stdout|stderr|all` right away\n// See https://github.com/sindresorhus/execa/issues/730 and https://github.com/sindresorhus/execa/pull/729#discussion_r1465496310\nconst resumeStream = async stream => {\n\tawait setImmediate();\n\tif (stream.readableFlowing === null) {\n\t\tstream.resume();\n\t}\n};\n\nconst getStreamContents = async ({stream, stream: {readableObjectMode}, iterable, fdNumber, encoding, maxBuffer, lines}) => {\n\ttry {\n\t\tif (readableObjectMode || lines) {\n\t\t\treturn await getStreamAsArray(iterable, {maxBuffer});\n\t\t}\n\n\t\tif (encoding === 'buffer') {\n\t\t\treturn new Uint8Array(await getStreamAsArrayBuffer(iterable, {maxBuffer}));\n\t\t}\n\n\t\treturn await getStream(iterable, {maxBuffer});\n\t} catch (error) {\n\t\treturn handleBufferedData(handleMaxBuffer({\n\t\t\terror,\n\t\t\tstream,\n\t\t\treadableObjectMode,\n\t\t\tlines,\n\t\t\tencoding,\n\t\t\tfdNumber,\n\t\t}));\n\t}\n};\n\n// On failure, `result.stdout|stderr|all` should contain the currently buffered stream\n// They are automatically closed and flushed by Node.js when the subprocess exits\n// When `buffer` is `false`, `streamPromise` is `undefined` and there is no buffered data to retrieve\nexport const getBufferedData = async streamPromise => {\n\ttry {\n\t\treturn await streamPromise;\n\t} catch (error) {\n\t\treturn handleBufferedData(error);\n\t}\n};\n\n// Ensure we are returning Uint8Arrays when using `encoding: 'buffer'`\nconst handleBufferedData = ({bufferedData}) => isArrayBuffer(bufferedData)\n\t? new Uint8Array(bufferedData)\n\t: bufferedData;\n","import {finished} from 'node:stream/promises';\n\n// Wraps `finished(stream)` to handle the following case:\n// - When the subprocess exits, Node.js automatically calls `subprocess.stdin.destroy()`, which we need to ignore.\n// - However, we still need to throw if `subprocess.stdin.destroy()` is called before subprocess exit.\nexport const waitForStream = async (stream, fdNumber, streamInfo, {isSameDirection, stopOnExit = false} = {}) => {\n\tconst state = handleStdinDestroy(stream, streamInfo);\n\tconst abortController = new AbortController();\n\ttry {\n\t\tawait Promise.race([\n\t\t\t...(stopOnExit ? [streamInfo.exitPromise] : []),\n\t\t\tfinished(stream, {cleanup: true, signal: abortController.signal}),\n\t\t]);\n\t} catch (error) {\n\t\tif (!state.stdinCleanedUp) {\n\t\t\thandleStreamError(error, fdNumber, streamInfo, isSameDirection);\n\t\t}\n\t} finally {\n\t\tabortController.abort();\n\t}\n};\n\n// If `subprocess.stdin` is destroyed before being fully written to, it is considered aborted and should throw an error.\n// This can happen for example when user called `subprocess.stdin.destroy()` before `subprocess.stdin.end()`.\n// However, Node.js calls `subprocess.stdin.destroy()` on exit for cleanup purposes.\n// https://github.com/nodejs/node/blob/0b4cdb4b42956cbd7019058e409e06700a199e11/lib/internal/child_process.js#L278\n// This is normal and should not throw an error.\n// Therefore, we need to differentiate between both situations to know whether to throw an error.\n// Unfortunately, events (`close`, `error`, `end`, `exit`) cannot be used because `.destroy()` can take an arbitrary amount of time.\n// For example, `stdin: 'pipe'` is implemented as a TCP socket, and its `.destroy()` method waits for TCP disconnection.\n// Therefore `.destroy()` might end before or after subprocess exit, based on OS speed and load.\n// The only way to detect this is to spy on `subprocess.stdin._destroy()` by wrapping it.\n// If `subprocess.exitCode` or `subprocess.signalCode` is set, it means `.destroy()` is being called by Node.js itself.\nconst handleStdinDestroy = (stream, {originalStreams: [originalStdin], subprocess}) => {\n\tconst state = {stdinCleanedUp: false};\n\tif (stream === originalStdin) {\n\t\tspyOnStdinDestroy(stream, subprocess, state);\n\t}\n\n\treturn state;\n};\n\nconst spyOnStdinDestroy = (subprocessStdin, subprocess, state) => {\n\tconst {_destroy} = subprocessStdin;\n\tsubprocessStdin._destroy = (...destroyArguments) => {\n\t\tsetStdinCleanedUp(subprocess, state);\n\t\t_destroy.call(subprocessStdin, ...destroyArguments);\n\t};\n};\n\nconst setStdinCleanedUp = ({exitCode, signalCode}, state) => {\n\tif (exitCode !== null || signalCode !== null) {\n\t\tstate.stdinCleanedUp = true;\n\t}\n};\n\n// We ignore EPIPEs on writable streams and aborts on readable streams since those can happen normally.\n// When one stream errors, the error is propagated to the other streams on the same file descriptor.\n// Those other streams might have a different direction due to the above.\n// When this happens, the direction of both the initial stream and the others should then be taken into account.\n// Therefore, we keep track of whether a stream error is currently propagating.\nconst handleStreamError = (error, fdNumber, streamInfo, isSameDirection) => {\n\tif (!shouldIgnoreStreamError(error, fdNumber, streamInfo, isSameDirection)) {\n\t\tthrow error;\n\t}\n};\n\nconst shouldIgnoreStreamError = (error, fdNumber, streamInfo, isSameDirection = true) => {\n\tif (streamInfo.propagating) {\n\t\treturn isStreamEpipe(error) || isStreamAbort(error);\n\t}\n\n\tstreamInfo.propagating = true;\n\treturn isInputFileDescriptor(streamInfo, fdNumber) === isSameDirection\n\t\t? isStreamEpipe(error)\n\t\t: isStreamAbort(error);\n};\n\n// Unfortunately, we cannot use the stream's class or properties to know whether it is readable or writable.\n// For example, `subprocess.stdin` is technically a Duplex, but can only be used as a writable.\n// Therefore, we need to use the file descriptor's direction (`stdin` is input, `stdout` is output, etc.).\n// However, while `subprocess.std*` and transforms follow that direction, any stream passed the `std*` option has the opposite direction.\n// For example, `subprocess.stdin` is a writable, but the `stdin` option is a readable.\nexport const isInputFileDescriptor = ({fileDescriptors}, fdNumber) => fdNumber !== 'all' && fileDescriptors[fdNumber].direction === 'input';\n\n// When `stream.destroy()` is called without an `error` argument, stream is aborted.\n// This is the only way to abort a readable stream, which can be useful in some instances.\n// Therefore, we ignore this error on readable streams.\nexport const isStreamAbort = error => error?.code === 'ERR_STREAM_PREMATURE_CLOSE';\n\n// When `stream.write()` is called but the underlying source has been closed, `EPIPE` is emitted.\n// When piping subprocesses, the source subprocess usually decides when to stop piping.\n// However, there are some instances when the destination does instead, such as `... | head -n1`.\n// It notifies the source by using `EPIPE`.\n// Therefore, we ignore this error on writable streams.\nconst isStreamEpipe = error => error?.code === 'EPIPE';\n","import {getStreamOutput} from '../io/contents.js';\nimport {waitForStream, isInputFileDescriptor} from './wait-stream.js';\n\n// Read the contents of `subprocess.std*` and|or wait for its completion\nexport const waitForStdioStreams = ({subprocess, encoding, buffer, maxBuffer, lines, stripFinalNewline, verboseInfo, streamInfo}) => subprocess.stdio.map((stream, fdNumber) => waitForSubprocessStream({\n\tstream,\n\tfdNumber,\n\tencoding,\n\tbuffer: buffer[fdNumber],\n\tmaxBuffer: maxBuffer[fdNumber],\n\tlines: lines[fdNumber],\n\tallMixed: false,\n\tstripFinalNewline,\n\tverboseInfo,\n\tstreamInfo,\n}));\n\n// Read the contents of `subprocess.std*` or `subprocess.all` and|or wait for its completion\nexport const waitForSubprocessStream = async ({stream, fdNumber, encoding, buffer, maxBuffer, lines, allMixed, stripFinalNewline, verboseInfo, streamInfo}) => {\n\tif (!stream) {\n\t\treturn;\n\t}\n\n\tconst onStreamEnd = waitForStream(stream, fdNumber, streamInfo);\n\tif (isInputFileDescriptor(streamInfo, fdNumber)) {\n\t\tawait onStreamEnd;\n\t\treturn;\n\t}\n\n\tconst [output] = await Promise.all([\n\t\tgetStreamOutput({\n\t\t\tstream,\n\t\t\tonStreamEnd,\n\t\t\tfdNumber,\n\t\t\tencoding,\n\t\t\tbuffer,\n\t\t\tmaxBuffer,\n\t\t\tlines,\n\t\t\tallMixed,\n\t\t\tstripFinalNewline,\n\t\t\tverboseInfo,\n\t\t\tstreamInfo,\n\t\t}),\n\t\tonStreamEnd,\n\t]);\n\treturn output;\n};\n","import mergeStreams from '@sindresorhus/merge-streams';\nimport {waitForSubprocessStream} from './stdio.js';\n\n// `all` interleaves `stdout` and `stderr`\nexport const makeAllStream = ({stdout, stderr}, {all}) => all && (stdout || stderr)\n\t? mergeStreams([stdout, stderr].filter(Boolean))\n\t: undefined;\n\n// Read the contents of `subprocess.all` and|or wait for its completion\nexport const waitForAllStream = ({subprocess, encoding, buffer, maxBuffer, lines, stripFinalNewline, verboseInfo, streamInfo}) => waitForSubprocessStream({\n\t...getAllStream(subprocess, buffer),\n\tfdNumber: 'all',\n\tencoding,\n\tmaxBuffer: maxBuffer[1] + maxBuffer[2],\n\tlines: lines[1] || lines[2],\n\tallMixed: getAllMixed(subprocess),\n\tstripFinalNewline,\n\tverboseInfo,\n\tstreamInfo,\n});\n\nconst getAllStream = ({stdout, stderr, all}, [, bufferStdout, bufferStderr]) => {\n\tconst buffer = bufferStdout || bufferStderr;\n\tif (!buffer) {\n\t\treturn {stream: all, buffer};\n\t}\n\n\tif (!bufferStdout) {\n\t\treturn {stream: stderr, buffer};\n\t}\n\n\tif (!bufferStderr) {\n\t\treturn {stream: stdout, buffer};\n\t}\n\n\treturn {stream: all, buffer};\n};\n\n// When `subprocess.stdout` is in objectMode but not `subprocess.stderr` (or the opposite), we need to use both:\n// - `getStreamAsArray()` for the chunks in objectMode, to return as an array without changing each chunk\n// - `getStreamAsArrayBuffer()` or `getStream()` for the chunks not in objectMode, to convert them from Buffers to string or Uint8Array\n// We do this by emulating the Buffer -> string|Uint8Array conversion performed by `get-stream` with our own, which is identical.\nconst getAllMixed = ({all, stdout, stderr}) => all\n\t&& stdout\n\t&& stderr\n\t&& stdout.readableObjectMode !== stderr.readableObjectMode;\n","import {verboseLog, serializeVerboseMessage} from './log.js';\nimport {isFullVerbose} from './values.js';\n\n// When `verbose` is `'full'`, print IPC messages from the subprocess\nexport const shouldLogIpc = verboseInfo => isFullVerbose(verboseInfo, 'ipc');\n\nexport const logIpcOutput = (message, verboseInfo) => {\n\tconst verboseMessage = serializeVerboseMessage(message);\n\tverboseLog({\n\t\ttype: 'ipc',\n\t\tverboseMessage,\n\t\tfdNumber: 'ipc',\n\t\tverboseInfo,\n\t});\n};\n","import {checkIpcMaxBuffer} from '../io/max-buffer.js';\nimport {shouldLogIpc, logIpcOutput} from '../verbose/ipc.js';\nimport {getFdSpecificValue} from '../arguments/specific.js';\nimport {loopOnMessages} from './get-each.js';\n\n// Iterate through IPC messages sent by the subprocess\nexport const waitForIpcOutput = async ({\n\tsubprocess,\n\tbuffer: bufferArray,\n\tmaxBuffer: maxBufferArray,\n\tipc,\n\tipcOutput,\n\tverboseInfo,\n}) => {\n\tif (!ipc) {\n\t\treturn ipcOutput;\n\t}\n\n\tconst isVerbose = shouldLogIpc(verboseInfo);\n\tconst buffer = getFdSpecificValue(bufferArray, 'ipc');\n\tconst maxBuffer = getFdSpecificValue(maxBufferArray, 'ipc');\n\n\tfor await (const message of loopOnMessages({\n\t\tanyProcess: subprocess,\n\t\tchannel: subprocess.channel,\n\t\tisSubprocess: false,\n\t\tipc,\n\t\tshouldAwait: false,\n\t\treference: true,\n\t})) {\n\t\tif (buffer) {\n\t\t\tcheckIpcMaxBuffer(subprocess, ipcOutput, maxBuffer);\n\t\t\tipcOutput.push(message);\n\t\t}\n\n\t\tif (isVerbose) {\n\t\t\tlogIpcOutput(message, verboseInfo);\n\t\t}\n\t}\n\n\treturn ipcOutput;\n};\n\nexport const getBufferedIpcOutput = async (ipcOutputPromise, ipcOutput) => {\n\tawait Promise.allSettled([ipcOutputPromise]);\n\treturn ipcOutput;\n};\n","import {once} from 'node:events';\nimport {isStream as isNodeStream} from 'is-stream';\nimport {throwOnTimeout} from '../terminate/timeout.js';\nimport {throwOnCancel} from '../terminate/cancel.js';\nimport {throwOnGracefulCancel} from '../terminate/graceful.js';\nimport {isStandardStream} from '../utils/standard-stream.js';\nimport {TRANSFORM_TYPES} from '../stdio/type.js';\nimport {getBufferedData} from '../io/contents.js';\nimport {waitForIpcOutput, getBufferedIpcOutput} from '../ipc/buffer-messages.js';\nimport {sendIpcInput} from '../ipc/ipc-input.js';\nimport {waitForAllStream} from './all-async.js';\nimport {waitForStdioStreams} from './stdio.js';\nimport {waitForExit, waitForSuccessfulExit} from './exit-async.js';\nimport {waitForStream} from './wait-stream.js';\n\n// Retrieve result of subprocess: exit code, signal, error, streams (stdout/stderr/all)\nexport const waitForSubprocessResult = async ({\n\tsubprocess,\n\toptions: {\n\t\tencoding,\n\t\tbuffer,\n\t\tmaxBuffer,\n\t\tlines,\n\t\ttimeoutDuration: timeout,\n\t\tcancelSignal,\n\t\tgracefulCancel,\n\t\tforceKillAfterDelay,\n\t\tstripFinalNewline,\n\t\tipc,\n\t\tipcInput,\n\t},\n\tcontext,\n\tverboseInfo,\n\tfileDescriptors,\n\toriginalStreams,\n\tonInternalError,\n\tcontroller,\n}) => {\n\tconst exitPromise = waitForExit(subprocess, context);\n\tconst streamInfo = {\n\t\toriginalStreams,\n\t\tfileDescriptors,\n\t\tsubprocess,\n\t\texitPromise,\n\t\tpropagating: false,\n\t};\n\n\tconst stdioPromises = waitForStdioStreams({\n\t\tsubprocess,\n\t\tencoding,\n\t\tbuffer,\n\t\tmaxBuffer,\n\t\tlines,\n\t\tstripFinalNewline,\n\t\tverboseInfo,\n\t\tstreamInfo,\n\t});\n\tconst allPromise = waitForAllStream({\n\t\tsubprocess,\n\t\tencoding,\n\t\tbuffer,\n\t\tmaxBuffer,\n\t\tlines,\n\t\tstripFinalNewline,\n\t\tverboseInfo,\n\t\tstreamInfo,\n\t});\n\tconst ipcOutput = [];\n\tconst ipcOutputPromise = waitForIpcOutput({\n\t\tsubprocess,\n\t\tbuffer,\n\t\tmaxBuffer,\n\t\tipc,\n\t\tipcOutput,\n\t\tverboseInfo,\n\t});\n\tconst originalPromises = waitForOriginalStreams(originalStreams, subprocess, streamInfo);\n\tconst customStreamsEndPromises = waitForCustomStreamsEnd(fileDescriptors, streamInfo);\n\n\ttry {\n\t\treturn await Promise.race([\n\t\t\tPromise.all([\n\t\t\t\t{},\n\t\t\t\twaitForSuccessfulExit(exitPromise),\n\t\t\t\tPromise.all(stdioPromises),\n\t\t\t\tallPromise,\n\t\t\t\tipcOutputPromise,\n\t\t\t\tsendIpcInput(subprocess, ipcInput),\n\t\t\t\t...originalPromises,\n\t\t\t\t...customStreamsEndPromises,\n\t\t\t]),\n\t\t\tonInternalError,\n\t\t\tthrowOnSubprocessError(subprocess, controller),\n\t\t\t...throwOnTimeout(subprocess, timeout, context, controller),\n\t\t\t...throwOnCancel({\n\t\t\t\tsubprocess,\n\t\t\t\tcancelSignal,\n\t\t\t\tgracefulCancel,\n\t\t\t\tcontext,\n\t\t\t\tcontroller,\n\t\t\t}),\n\t\t\t...throwOnGracefulCancel({\n\t\t\t\tsubprocess,\n\t\t\t\tcancelSignal,\n\t\t\t\tgracefulCancel,\n\t\t\t\tforceKillAfterDelay,\n\t\t\t\tcontext,\n\t\t\t\tcontroller,\n\t\t\t}),\n\t\t]);\n\t} catch (error) {\n\t\tcontext.terminationReason ??= 'other';\n\t\treturn Promise.all([\n\t\t\t{error},\n\t\t\texitPromise,\n\t\t\tPromise.all(stdioPromises.map(stdioPromise => getBufferedData(stdioPromise))),\n\t\t\tgetBufferedData(allPromise),\n\t\t\tgetBufferedIpcOutput(ipcOutputPromise, ipcOutput),\n\t\t\tPromise.allSettled(originalPromises),\n\t\t\tPromise.allSettled(customStreamsEndPromises),\n\t\t]);\n\t}\n};\n\n// Transforms replace `subprocess.std*`, which means they are not exposed to users.\n// However, we still want to wait for their completion.\nconst waitForOriginalStreams = (originalStreams, subprocess, streamInfo) =>\n\toriginalStreams.map((stream, fdNumber) => stream === subprocess.stdio[fdNumber]\n\t\t? undefined\n\t\t: waitForStream(stream, fdNumber, streamInfo));\n\n// Some `stdin`/`stdout`/`stderr` options create a stream, e.g. when passing a file path.\n// The `.pipe()` method automatically ends that stream when `subprocess` ends.\n// This makes sure we wait for the completion of those streams, in order to catch any error.\nconst waitForCustomStreamsEnd = (fileDescriptors, streamInfo) => fileDescriptors.flatMap(({stdioItems}, fdNumber) => stdioItems\n\t.filter(({value, stream = value}) => isNodeStream(stream, {checkOpen: false}) && !isStandardStream(stream))\n\t.map(({type, value, stream = value}) => waitForStream(stream, fdNumber, streamInfo, {\n\t\tisSameDirection: TRANSFORM_TYPES.has(type),\n\t\tstopOnExit: type === 'native',\n\t})));\n\n// Fails when the subprocess emits an `error` event\nconst throwOnSubprocessError = async (subprocess, {signal}) => {\n\tconst [error] = await once(subprocess, 'error', {signal});\n\tthrow error;\n};\n","import {createDeferred} from '../utils/deferred.js';\n\n// When using multiple `.readable()`/`.writable()`/`.duplex()`, `final` and `destroy` should wait for other streams\nexport const initializeConcurrentStreams = () => ({\n\treadableDestroy: new WeakMap(),\n\twritableFinal: new WeakMap(),\n\twritableDestroy: new WeakMap(),\n});\n\n// Each file descriptor + `waitName` has its own array of promises.\n// Each promise is a single `.readable()`/`.writable()`/`.duplex()` call.\nexport const addConcurrentStream = (concurrentStreams, stream, waitName) => {\n\tconst weakMap = concurrentStreams[waitName];\n\tif (!weakMap.has(stream)) {\n\t\tweakMap.set(stream, []);\n\t}\n\n\tconst promises = weakMap.get(stream);\n\tconst promise = createDeferred();\n\tpromises.push(promise);\n\tconst resolve = promise.resolve.bind(promise);\n\treturn {resolve, promises};\n};\n\n// Wait for other streams, but stop waiting when subprocess ends\nexport const waitForConcurrentStreams = async ({resolve, promises}, subprocess) => {\n\tresolve();\n\tconst [isSubprocessExit] = await Promise.race([\n\t\tPromise.allSettled([true, subprocess]),\n\t\tPromise.all([false, ...promises]),\n\t]);\n\treturn !isSubprocessExit;\n};\n","import {finished} from 'node:stream/promises';\nimport {isStreamAbort} from '../resolve/wait-stream.js';\n\nexport const safeWaitForSubprocessStdin = async subprocessStdin => {\n\tif (subprocessStdin === undefined) {\n\t\treturn;\n\t}\n\n\ttry {\n\t\tawait waitForSubprocessStdin(subprocessStdin);\n\t} catch {}\n};\n\nexport const safeWaitForSubprocessStdout = async subprocessStdout => {\n\tif (subprocessStdout === undefined) {\n\t\treturn;\n\t}\n\n\ttry {\n\t\tawait waitForSubprocessStdout(subprocessStdout);\n\t} catch {}\n};\n\nexport const waitForSubprocessStdin = async subprocessStdin => {\n\tawait finished(subprocessStdin, {cleanup: true, readable: false, writable: true});\n};\n\nexport const waitForSubprocessStdout = async subprocessStdout => {\n\tawait finished(subprocessStdout, {cleanup: true, readable: true, writable: false});\n};\n\n// When `readable` or `writable` aborts/errors, awaits the subprocess, for the reason mentioned above\nexport const waitForSubprocess = async (subprocess, error) => {\n\tawait subprocess;\n\tif (error) {\n\t\tthrow error;\n\t}\n};\n\nexport const destroyOtherStream = (stream, isOpen, error) => {\n\tif (error && !isStreamAbort(error)) {\n\t\tstream.destroy(error);\n\t} else if (isOpen) {\n\t\tstream.destroy();\n\t}\n};\n","import {Readable} from 'node:stream';\nimport {callbackify} from 'node:util';\nimport {BINARY_ENCODINGS} from '../arguments/encoding-option.js';\nimport {getFromStream} from '../arguments/fd-options.js';\nimport {iterateOnSubprocessStream, DEFAULT_OBJECT_HIGH_WATER_MARK} from '../io/iterate.js';\nimport {createDeferred} from '../utils/deferred.js';\nimport {addConcurrentStream, waitForConcurrentStreams} from './concurrent.js';\nimport {\n\tsafeWaitForSubprocessStdin,\n\twaitForSubprocessStdout,\n\twaitForSubprocess,\n\tdestroyOtherStream,\n} from './shared.js';\n\n// Create a `Readable` stream that forwards from `stdout` and awaits the subprocess\nexport const createReadable = ({subprocess, concurrentStreams, encoding}, {from, binary: binaryOption = true, preserveNewlines = true} = {}) => {\n\tconst binary = binaryOption || BINARY_ENCODINGS.has(encoding);\n\tconst {subprocessStdout, waitReadableDestroy} = getSubprocessStdout(subprocess, from, concurrentStreams);\n\tconst {readableEncoding, readableObjectMode, readableHighWaterMark} = getReadableOptions(subprocessStdout, binary);\n\tconst {read, onStdoutDataDone} = getReadableMethods({\n\t\tsubprocessStdout,\n\t\tsubprocess,\n\t\tbinary,\n\t\tencoding,\n\t\tpreserveNewlines,\n\t});\n\tconst readable = new Readable({\n\t\tread,\n\t\tdestroy: callbackify(onReadableDestroy.bind(undefined, {subprocessStdout, subprocess, waitReadableDestroy})),\n\t\thighWaterMark: readableHighWaterMark,\n\t\tobjectMode: readableObjectMode,\n\t\tencoding: readableEncoding,\n\t});\n\tonStdoutFinished({\n\t\tsubprocessStdout,\n\t\tonStdoutDataDone,\n\t\treadable,\n\t\tsubprocess,\n\t});\n\treturn readable;\n};\n\n// Retrieve `stdout` (or other stream depending on `from`)\nexport const getSubprocessStdout = (subprocess, from, concurrentStreams) => {\n\tconst subprocessStdout = getFromStream(subprocess, from);\n\tconst waitReadableDestroy = addConcurrentStream(concurrentStreams, subprocessStdout, 'readableDestroy');\n\treturn {subprocessStdout, waitReadableDestroy};\n};\n\nexport const getReadableOptions = ({readableEncoding, readableObjectMode, readableHighWaterMark}, binary) => binary\n\t? {readableEncoding, readableObjectMode, readableHighWaterMark}\n\t: {readableEncoding, readableObjectMode: true, readableHighWaterMark: DEFAULT_OBJECT_HIGH_WATER_MARK};\n\nexport const getReadableMethods = ({subprocessStdout, subprocess, binary, encoding, preserveNewlines}) => {\n\tconst onStdoutDataDone = createDeferred();\n\tconst onStdoutData = iterateOnSubprocessStream({\n\t\tsubprocessStdout,\n\t\tsubprocess,\n\t\tbinary,\n\t\tshouldEncode: !binary,\n\t\tencoding,\n\t\tpreserveNewlines,\n\t});\n\n\treturn {\n\t\tread() {\n\t\t\tonRead(this, onStdoutData, onStdoutDataDone);\n\t\t},\n\t\tonStdoutDataDone,\n\t};\n};\n\n// Forwards data from `stdout` to `readable`\nconst onRead = async (readable, onStdoutData, onStdoutDataDone) => {\n\ttry {\n\t\tconst {value, done} = await onStdoutData.next();\n\t\tif (done) {\n\t\t\tonStdoutDataDone.resolve();\n\t\t} else {\n\t\t\treadable.push(value);\n\t\t}\n\t} catch {}\n};\n\n// When `subprocess.stdout` ends/aborts/errors, do the same on `readable`.\n// Await the subprocess, for the same reason as above.\nexport const onStdoutFinished = async ({subprocessStdout, onStdoutDataDone, readable, subprocess, subprocessStdin}) => {\n\ttry {\n\t\tawait waitForSubprocessStdout(subprocessStdout);\n\t\tawait subprocess;\n\t\tawait safeWaitForSubprocessStdin(subprocessStdin);\n\t\tawait onStdoutDataDone;\n\n\t\tif (readable.readable) {\n\t\t\treadable.push(null);\n\t\t}\n\t} catch (error) {\n\t\tawait safeWaitForSubprocessStdin(subprocessStdin);\n\t\tdestroyOtherReadable(readable, error);\n\t}\n};\n\n// When `readable` aborts/errors, do the same on `subprocess.stdout`\nexport const onReadableDestroy = async ({subprocessStdout, subprocess, waitReadableDestroy}, error) => {\n\tif (await waitForConcurrentStreams(waitReadableDestroy, subprocess)) {\n\t\tdestroyOtherReadable(subprocessStdout, error);\n\t\tawait waitForSubprocess(subprocess, error);\n\t}\n};\n\nconst destroyOtherReadable = (stream, error) => {\n\tdestroyOtherStream(stream, stream.readable, error);\n};\n","import {Writable} from 'node:stream';\nimport {callbackify} from 'node:util';\nimport {getToStream} from '../arguments/fd-options.js';\nimport {addConcurrentStream, waitForConcurrentStreams} from './concurrent.js';\nimport {\n\tsafeWaitForSubprocessStdout,\n\twaitForSubprocessStdin,\n\twaitForSubprocess,\n\tdestroyOtherStream,\n} from './shared.js';\n\n// Create a `Writable` stream that forwards to `stdin` and awaits the subprocess\nexport const createWritable = ({subprocess, concurrentStreams}, {to} = {}) => {\n\tconst {subprocessStdin, waitWritableFinal, waitWritableDestroy} = getSubprocessStdin(subprocess, to, concurrentStreams);\n\tconst writable = new Writable({\n\t\t...getWritableMethods(subprocessStdin, subprocess, waitWritableFinal),\n\t\tdestroy: callbackify(onWritableDestroy.bind(undefined, {\n\t\t\tsubprocessStdin,\n\t\t\tsubprocess,\n\t\t\twaitWritableFinal,\n\t\t\twaitWritableDestroy,\n\t\t})),\n\t\thighWaterMark: subprocessStdin.writableHighWaterMark,\n\t\tobjectMode: subprocessStdin.writableObjectMode,\n\t});\n\tonStdinFinished(subprocessStdin, writable);\n\treturn writable;\n};\n\n// Retrieve `stdin` (or other stream depending on `to`)\nexport const getSubprocessStdin = (subprocess, to, concurrentStreams) => {\n\tconst subprocessStdin = getToStream(subprocess, to);\n\tconst waitWritableFinal = addConcurrentStream(concurrentStreams, subprocessStdin, 'writableFinal');\n\tconst waitWritableDestroy = addConcurrentStream(concurrentStreams, subprocessStdin, 'writableDestroy');\n\treturn {subprocessStdin, waitWritableFinal, waitWritableDestroy};\n};\n\nexport const getWritableMethods = (subprocessStdin, subprocess, waitWritableFinal) => ({\n\twrite: onWrite.bind(undefined, subprocessStdin),\n\tfinal: callbackify(onWritableFinal.bind(undefined, subprocessStdin, subprocess, waitWritableFinal)),\n});\n\n// Forwards data from `writable` to `stdin`\nconst onWrite = (subprocessStdin, chunk, encoding, done) => {\n\tif (subprocessStdin.write(chunk, encoding)) {\n\t\tdone();\n\t} else {\n\t\tsubprocessStdin.once('drain', done);\n\t}\n};\n\n// Ensures that the writable `final` and readable `end` events awaits the subprocess.\n// Like this, any subprocess failure is propagated as a stream `error` event, instead of being lost.\n// The user does not need to `await` the subprocess anymore, but now needs to await the stream completion or error.\n// When multiple writables are targeting the same stream, they wait for each other, unless the subprocess ends first.\nconst onWritableFinal = async (subprocessStdin, subprocess, waitWritableFinal) => {\n\tif (await waitForConcurrentStreams(waitWritableFinal, subprocess)) {\n\t\tif (subprocessStdin.writable) {\n\t\t\tsubprocessStdin.end();\n\t\t}\n\n\t\tawait subprocess;\n\t}\n};\n\n// When `subprocess.stdin` ends/aborts/errors, do the same on `writable`.\nexport const onStdinFinished = async (subprocessStdin, writable, subprocessStdout) => {\n\ttry {\n\t\tawait waitForSubprocessStdin(subprocessStdin);\n\t\tif (writable.writable) {\n\t\t\twritable.end();\n\t\t}\n\t} catch (error) {\n\t\tawait safeWaitForSubprocessStdout(subprocessStdout);\n\t\tdestroyOtherWritable(writable, error);\n\t}\n};\n\n// When `writable` aborts/errors, do the same on `subprocess.stdin`\nexport const onWritableDestroy = async ({subprocessStdin, subprocess, waitWritableFinal, waitWritableDestroy}, error) => {\n\tawait waitForConcurrentStreams(waitWritableFinal, subprocess);\n\tif (await waitForConcurrentStreams(waitWritableDestroy, subprocess)) {\n\t\tdestroyOtherWritable(subprocessStdin, error);\n\t\tawait waitForSubprocess(subprocess, error);\n\t}\n};\n\nconst destroyOtherWritable = (stream, error) => {\n\tdestroyOtherStream(stream, stream.writable, error);\n};\n","import {Duplex} from 'node:stream';\nimport {callbackify} from 'node:util';\nimport {BINARY_ENCODINGS} from '../arguments/encoding-option.js';\nimport {\n\tgetSubprocessStdout,\n\tgetReadableOptions,\n\tgetReadableMethods,\n\tonStdoutFinished,\n\tonReadableDestroy,\n} from './readable.js';\nimport {\n\tgetSubprocessStdin,\n\tgetWritableMethods,\n\tonStdinFinished,\n\tonWritableDestroy,\n} from './writable.js';\n\n// Create a `Duplex` stream combining both `subprocess.readable()` and `subprocess.writable()`\nexport const createDuplex = ({subprocess, concurrentStreams, encoding}, {from, to, binary: binaryOption = true, preserveNewlines = true} = {}) => {\n\tconst binary = binaryOption || BINARY_ENCODINGS.has(encoding);\n\tconst {subprocessStdout, waitReadableDestroy} = getSubprocessStdout(subprocess, from, concurrentStreams);\n\tconst {subprocessStdin, waitWritableFinal, waitWritableDestroy} = getSubprocessStdin(subprocess, to, concurrentStreams);\n\tconst {readableEncoding, readableObjectMode, readableHighWaterMark} = getReadableOptions(subprocessStdout, binary);\n\tconst {read, onStdoutDataDone} = getReadableMethods({\n\t\tsubprocessStdout,\n\t\tsubprocess,\n\t\tbinary,\n\t\tencoding,\n\t\tpreserveNewlines,\n\t});\n\tconst duplex = new Duplex({\n\t\tread,\n\t\t...getWritableMethods(subprocessStdin, subprocess, waitWritableFinal),\n\t\tdestroy: callbackify(onDuplexDestroy.bind(undefined, {\n\t\t\tsubprocessStdout,\n\t\t\tsubprocessStdin,\n\t\t\tsubprocess,\n\t\t\twaitReadableDestroy,\n\t\t\twaitWritableFinal,\n\t\t\twaitWritableDestroy,\n\t\t})),\n\t\treadableHighWaterMark,\n\t\twritableHighWaterMark: subprocessStdin.writableHighWaterMark,\n\t\treadableObjectMode,\n\t\twritableObjectMode: subprocessStdin.writableObjectMode,\n\t\tencoding: readableEncoding,\n\t});\n\tonStdoutFinished({\n\t\tsubprocessStdout,\n\t\tonStdoutDataDone,\n\t\treadable: duplex,\n\t\tsubprocess,\n\t\tsubprocessStdin,\n\t});\n\tonStdinFinished(subprocessStdin, duplex, subprocessStdout);\n\treturn duplex;\n};\n\nconst onDuplexDestroy = async ({subprocessStdout, subprocessStdin, subprocess, waitReadableDestroy, waitWritableFinal, waitWritableDestroy}, error) => {\n\tawait Promise.all([\n\t\tonReadableDestroy({subprocessStdout, subprocess, waitReadableDestroy}, error),\n\t\tonWritableDestroy({\n\t\t\tsubprocessStdin,\n\t\t\tsubprocess,\n\t\t\twaitWritableFinal,\n\t\t\twaitWritableDestroy,\n\t\t}, error),\n\t]);\n};\n","import {BINARY_ENCODINGS} from '../arguments/encoding-option.js';\nimport {getFromStream} from '../arguments/fd-options.js';\nimport {iterateOnSubprocessStream} from '../io/iterate.js';\n\n// Convert the subprocess to an async iterable\nexport const createIterable = (subprocess, encoding, {\n\tfrom,\n\tbinary: binaryOption = false,\n\tpreserveNewlines = false,\n} = {}) => {\n\tconst binary = binaryOption || BINARY_ENCODINGS.has(encoding);\n\tconst subprocessStdout = getFromStream(subprocess, from);\n\tconst onStdoutData = iterateOnSubprocessStream({\n\t\tsubprocessStdout,\n\t\tsubprocess,\n\t\tbinary,\n\t\tshouldEncode: true,\n\t\tencoding,\n\t\tpreserveNewlines,\n\t});\n\treturn iterateOnStdoutData(onStdoutData, subprocessStdout, subprocess);\n};\n\nconst iterateOnStdoutData = async function * (onStdoutData, subprocessStdout, subprocess) {\n\ttry {\n\t\tyield * onStdoutData;\n\t} finally {\n\t\tif (subprocessStdout.readable) {\n\t\t\tsubprocessStdout.destroy();\n\t\t}\n\n\t\tawait subprocess;\n\t}\n};\n","import {initializeConcurrentStreams} from './concurrent.js';\nimport {createReadable} from './readable.js';\nimport {createWritable} from './writable.js';\nimport {createDuplex} from './duplex.js';\nimport {createIterable} from './iterable.js';\n\n// Add methods to convert the subprocess to a stream or iterable\nexport const addConvertedStreams = (subprocess, {encoding}) => {\n\tconst concurrentStreams = initializeConcurrentStreams();\n\tsubprocess.readable = createReadable.bind(undefined, {subprocess, concurrentStreams, encoding});\n\tsubprocess.writable = createWritable.bind(undefined, {subprocess, concurrentStreams});\n\tsubprocess.duplex = createDuplex.bind(undefined, {subprocess, concurrentStreams, encoding});\n\tsubprocess.iterable = createIterable.bind(undefined, subprocess, encoding);\n\tsubprocess[Symbol.asyncIterator] = createIterable.bind(undefined, subprocess, encoding, {});\n};\n","// The return value is a mixin of `subprocess` and `Promise`\nexport const mergePromise = (subprocess, promise) => {\n\tfor (const [property, descriptor] of descriptors) {\n\t\tconst value = descriptor.value.bind(promise);\n\t\tReflect.defineProperty(subprocess, property, {...descriptor, value});\n\t}\n};\n\n// eslint-disable-next-line unicorn/prefer-top-level-await\nconst nativePromisePrototype = (async () => {})().constructor.prototype;\n\nconst descriptors = ['then', 'catch', 'finally'].map(property => [\n\tproperty,\n\tReflect.getOwnPropertyDescriptor(nativePromisePrototype, property),\n]);\n","import {setMaxListeners} from 'node:events';\nimport {spawn} from 'node:child_process';\nimport {MaxBufferError} from 'get-stream';\nimport {handleCommand} from '../arguments/command.js';\nimport {normalizeOptions} from '../arguments/options.js';\nimport {SUBPROCESS_OPTIONS} from '../arguments/fd-options.js';\nimport {addIpcMethods} from '../ipc/methods.js';\nimport {makeError, makeSuccessResult} from '../return/result.js';\nimport {handleResult} from '../return/reject.js';\nimport {handleEarlyError} from '../return/early-error.js';\nimport {handleStdioAsync} from '../stdio/handle-async.js';\nimport {stripNewline} from '../io/strip-newline.js';\nimport {pipeOutputAsync} from '../io/output-async.js';\nimport {subprocessKill} from '../terminate/kill.js';\nimport {cleanupOnExit} from '../terminate/cleanup.js';\nimport {pipeToSubprocess} from '../pipe/setup.js';\nimport {makeAllStream} from '../resolve/all-async.js';\nimport {waitForSubprocessResult} from '../resolve/wait-subprocess.js';\nimport {addConvertedStreams} from '../convert/add.js';\nimport {createDeferred} from '../utils/deferred.js';\nimport {mergePromise} from './promise.js';\n\n// Main shared logic for all async methods: `execa()`, `$`, `execaNode()`\nexport const execaCoreAsync = (rawFile, rawArguments, rawOptions, createNested) => {\n\tconst {file, commandArguments, command, escapedCommand, startTime, verboseInfo, options, fileDescriptors} = handleAsyncArguments(rawFile, rawArguments, rawOptions);\n\tconst {subprocess, promise} = spawnSubprocessAsync({\n\t\tfile,\n\t\tcommandArguments,\n\t\toptions,\n\t\tstartTime,\n\t\tverboseInfo,\n\t\tcommand,\n\t\tescapedCommand,\n\t\tfileDescriptors,\n\t});\n\tsubprocess.pipe = pipeToSubprocess.bind(undefined, {\n\t\tsource: subprocess,\n\t\tsourcePromise: promise,\n\t\tboundOptions: {},\n\t\tcreateNested,\n\t});\n\tmergePromise(subprocess, promise);\n\tSUBPROCESS_OPTIONS.set(subprocess, {options, fileDescriptors});\n\treturn subprocess;\n};\n\n// Compute arguments to pass to `child_process.spawn()`\nconst handleAsyncArguments = (rawFile, rawArguments, rawOptions) => {\n\tconst {command, escapedCommand, startTime, verboseInfo} = handleCommand(rawFile, rawArguments, rawOptions);\n\tconst {file, commandArguments, options: normalizedOptions} = normalizeOptions(rawFile, rawArguments, rawOptions);\n\tconst options = handleAsyncOptions(normalizedOptions);\n\tconst fileDescriptors = handleStdioAsync(options, verboseInfo);\n\treturn {\n\t\tfile,\n\t\tcommandArguments,\n\t\tcommand,\n\t\tescapedCommand,\n\t\tstartTime,\n\t\tverboseInfo,\n\t\toptions,\n\t\tfileDescriptors,\n\t};\n};\n\n// Options normalization logic specific to async methods.\n// Prevent passing the `timeout` option directly to `child_process.spawn()`.\nconst handleAsyncOptions = ({timeout, signal, ...options}) => {\n\tif (signal !== undefined) {\n\t\tthrow new TypeError('The \"signal\" option has been renamed to \"cancelSignal\" instead.');\n\t}\n\n\treturn {...options, timeoutDuration: timeout};\n};\n\nconst spawnSubprocessAsync = ({file, commandArguments, options, startTime, verboseInfo, command, escapedCommand, fileDescriptors}) => {\n\tlet subprocess;\n\ttry {\n\t\tsubprocess = spawn(file, commandArguments, options);\n\t} catch (error) {\n\t\treturn handleEarlyError({\n\t\t\terror,\n\t\t\tcommand,\n\t\t\tescapedCommand,\n\t\t\tfileDescriptors,\n\t\t\toptions,\n\t\t\tstartTime,\n\t\t\tverboseInfo,\n\t\t});\n\t}\n\n\tconst controller = new AbortController();\n\tsetMaxListeners(Number.POSITIVE_INFINITY, controller.signal);\n\n\tconst originalStreams = [...subprocess.stdio];\n\tpipeOutputAsync(subprocess, fileDescriptors, controller);\n\tcleanupOnExit(subprocess, options, controller);\n\n\tconst context = {};\n\tconst onInternalError = createDeferred();\n\tsubprocess.kill = subprocessKill.bind(undefined, {\n\t\tkill: subprocess.kill.bind(subprocess),\n\t\toptions,\n\t\tonInternalError,\n\t\tcontext,\n\t\tcontroller,\n\t});\n\tsubprocess.all = makeAllStream(subprocess, options);\n\taddConvertedStreams(subprocess, options);\n\taddIpcMethods(subprocess, options);\n\n\tconst promise = handlePromise({\n\t\tsubprocess,\n\t\toptions,\n\t\tstartTime,\n\t\tverboseInfo,\n\t\tfileDescriptors,\n\t\toriginalStreams,\n\t\tcommand,\n\t\tescapedCommand,\n\t\tcontext,\n\t\tonInternalError,\n\t\tcontroller,\n\t});\n\treturn {subprocess, promise};\n};\n\n// Asynchronous logic, as opposed to the previous logic which can be run synchronously, i.e. can be returned to user right away\nconst handlePromise = async ({subprocess, options, startTime, verboseInfo, fileDescriptors, originalStreams, command, escapedCommand, context, onInternalError, controller}) => {\n\tconst [\n\t\terrorInfo,\n\t\t[exitCode, signal],\n\t\tstdioResults,\n\t\tallResult,\n\t\tipcOutput,\n\t] = await waitForSubprocessResult({\n\t\tsubprocess,\n\t\toptions,\n\t\tcontext,\n\t\tverboseInfo,\n\t\tfileDescriptors,\n\t\toriginalStreams,\n\t\tonInternalError,\n\t\tcontroller,\n\t});\n\tcontroller.abort();\n\tonInternalError.resolve();\n\n\tconst stdio = stdioResults.map((stdioResult, fdNumber) => stripNewline(stdioResult, options, fdNumber));\n\tconst all = stripNewline(allResult, options, 'all');\n\tconst result = getAsyncResult({\n\t\terrorInfo,\n\t\texitCode,\n\t\tsignal,\n\t\tstdio,\n\t\tall,\n\t\tipcOutput,\n\t\tcontext,\n\t\toptions,\n\t\tcommand,\n\t\tescapedCommand,\n\t\tstartTime,\n\t});\n\treturn handleResult(result, verboseInfo, options);\n};\n\nconst getAsyncResult = ({errorInfo, exitCode, signal, stdio, all, ipcOutput, context, options, command, escapedCommand, startTime}) => 'error' in errorInfo\n\t? makeError({\n\t\terror: errorInfo.error,\n\t\tcommand,\n\t\tescapedCommand,\n\t\ttimedOut: context.terminationReason === 'timeout',\n\t\tisCanceled: context.terminationReason === 'cancel' || context.terminationReason === 'gracefulCancel',\n\t\tisGracefullyCanceled: context.terminationReason === 'gracefulCancel',\n\t\tisMaxBuffer: errorInfo.error instanceof MaxBufferError,\n\t\tisForcefullyTerminated: context.isForcefullyTerminated,\n\t\texitCode,\n\t\tsignal,\n\t\tstdio,\n\t\tall,\n\t\tipcOutput,\n\t\toptions,\n\t\tstartTime,\n\t\tisSync: false,\n\t})\n\t: makeSuccessResult({\n\t\tcommand,\n\t\tescapedCommand,\n\t\tstdio,\n\t\tall,\n\t\tipcOutput,\n\t\toptions,\n\t\tstartTime,\n\t});\n","import isPlainObject from 'is-plain-obj';\nimport {FD_SPECIFIC_OPTIONS} from '../arguments/specific.js';\n\n// Deep merge specific options like `env`. Shallow merge the other ones.\nexport const mergeOptions = (boundOptions, options) => {\n\tconst newOptions = Object.fromEntries(\n\t\tObject.entries(options).map(([optionName, optionValue]) => [\n\t\t\toptionName,\n\t\t\tmergeOption(optionName, boundOptions[optionName], optionValue),\n\t\t]),\n\t);\n\treturn {...boundOptions, ...newOptions};\n};\n\nconst mergeOption = (optionName, boundOptionValue, optionValue) => {\n\tif (DEEP_OPTIONS.has(optionName) && isPlainObject(boundOptionValue) && isPlainObject(optionValue)) {\n\t\treturn {...boundOptionValue, ...optionValue};\n\t}\n\n\treturn optionValue;\n};\n\nconst DEEP_OPTIONS = new Set(['env', ...FD_SPECIFIC_OPTIONS]);\n","import isPlainObject from 'is-plain-obj';\nimport {normalizeParameters} from './parameters.js';\nimport {isTemplateString, parseTemplates} from './template.js';\nimport {execaCoreSync} from './main-sync.js';\nimport {execaCoreAsync} from './main-async.js';\nimport {mergeOptions} from './bind.js';\n\n// Wraps every exported methods to provide the following features:\n// - template string syntax: execa`command argument`\n// - options binding: boundExeca = execa(options)\n// - optional argument/options: execa(file), execa(file, args), execa(file, options), execa(file, args, options)\n// `mapArguments()` and `setBoundExeca()` allows for method-specific logic.\nexport const createExeca = (mapArguments, boundOptions, deepOptions, setBoundExeca) => {\n\tconst createNested = (mapArguments, boundOptions, setBoundExeca) => createExeca(mapArguments, boundOptions, deepOptions, setBoundExeca);\n\tconst boundExeca = (...execaArguments) => callBoundExeca({\n\t\tmapArguments,\n\t\tdeepOptions,\n\t\tboundOptions,\n\t\tsetBoundExeca,\n\t\tcreateNested,\n\t}, ...execaArguments);\n\n\tif (setBoundExeca !== undefined) {\n\t\tsetBoundExeca(boundExeca, createNested, boundOptions);\n\t}\n\n\treturn boundExeca;\n};\n\nconst callBoundExeca = ({mapArguments, deepOptions = {}, boundOptions = {}, setBoundExeca, createNested}, firstArgument, ...nextArguments) => {\n\tif (isPlainObject(firstArgument)) {\n\t\treturn createNested(mapArguments, mergeOptions(boundOptions, firstArgument), setBoundExeca);\n\t}\n\n\tconst {file, commandArguments, options, isSync} = parseArguments({\n\t\tmapArguments,\n\t\tfirstArgument,\n\t\tnextArguments,\n\t\tdeepOptions,\n\t\tboundOptions,\n\t});\n\treturn isSync\n\t\t? execaCoreSync(file, commandArguments, options)\n\t\t: execaCoreAsync(file, commandArguments, options, createNested);\n};\n\nconst parseArguments = ({mapArguments, firstArgument, nextArguments, deepOptions, boundOptions}) => {\n\tconst callArguments = isTemplateString(firstArgument)\n\t\t? parseTemplates(firstArgument, nextArguments)\n\t\t: [firstArgument, ...nextArguments];\n\tconst [initialFile, initialArguments, initialOptions] = normalizeParameters(...callArguments);\n\tconst mergedOptions = mergeOptions(mergeOptions(deepOptions, boundOptions), initialOptions);\n\tconst {\n\t\tfile = initialFile,\n\t\tcommandArguments = initialArguments,\n\t\toptions = mergedOptions,\n\t\tisSync = false,\n\t} = mapArguments({file: initialFile, commandArguments: initialArguments, options: mergedOptions});\n\treturn {\n\t\tfile,\n\t\tcommandArguments,\n\t\toptions,\n\t\tisSync,\n\t};\n};\n","// Main logic for `execaCommand()`\nexport const mapCommandAsync = ({file, commandArguments}) => parseCommand(file, commandArguments);\n\n// Main logic for `execaCommandSync()`\nexport const mapCommandSync = ({file, commandArguments}) => ({...parseCommand(file, commandArguments), isSync: true});\n\n// Convert `execaCommand(command)` into `execa(file, ...commandArguments)`\nconst parseCommand = (command, unusedArguments) => {\n\tif (unusedArguments.length > 0) {\n\t\tthrow new TypeError(`The command and its arguments must be passed as a single string: ${command} ${unusedArguments}.`);\n\t}\n\n\tconst [file, ...commandArguments] = parseCommandString(command);\n\treturn {file, commandArguments};\n};\n\n// Convert `command` string into an array of file or arguments to pass to $`${...fileOrCommandArguments}`\nexport const parseCommandString = command => {\n\tif (typeof command !== 'string') {\n\t\tthrow new TypeError(`The command must be a string: ${String(command)}.`);\n\t}\n\n\tconst trimmedCommand = command.trim();\n\tif (trimmedCommand === '') {\n\t\treturn [];\n\t}\n\n\tconst tokens = [];\n\tfor (const token of trimmedCommand.split(SPACES_REGEXP)) {\n\t\t// Allow spaces to be escaped by a backslash if not meant as a delimiter\n\t\tconst previousToken = tokens.at(-1);\n\t\tif (previousToken && previousToken.endsWith('\\\\')) {\n\t\t\t// Merge previous token with current one\n\t\t\ttokens[tokens.length - 1] = `${previousToken.slice(0, -1)} ${token}`;\n\t\t} else {\n\t\t\ttokens.push(token);\n\t\t}\n\t}\n\n\treturn tokens;\n};\n\nconst SPACES_REGEXP = / +/g;\n","// Sets `$.sync` and `$.s`\nexport const setScriptSync = (boundExeca, createNested, boundOptions) => {\n\tboundExeca.sync = createNested(mapScriptSync, boundOptions);\n\tboundExeca.s = boundExeca.sync;\n};\n\n// Main logic for `$`\nexport const mapScriptAsync = ({options}) => getScriptOptions(options);\n\n// Main logic for `$.sync`\nconst mapScriptSync = ({options}) => ({...getScriptOptions(options), isSync: true});\n\n// `$` is like `execa` but with script-friendly options: `{stdin: 'inherit', preferLocal: true}`\nconst getScriptOptions = options => ({options: {...getScriptStdinOption(options), ...options}});\n\nconst getScriptStdinOption = ({input, inputFile, stdio}) => input === undefined && inputFile === undefined && stdio === undefined\n\t? {stdin: 'inherit'}\n\t: {};\n\n// When using $(...).pipe(...), most script-friendly options should apply to both commands.\n// However, some options (like `stdin: 'inherit'`) would create issues with piping, i.e. cannot be deep.\nexport const deepScriptOptions = {preferLocal: true};\n","import {createExeca} from './lib/methods/create.js';\nimport {mapCommandAsync, mapCommandSync} from './lib/methods/command.js';\nimport {mapNode} from './lib/methods/node.js';\nimport {mapScriptAsync, setScriptSync, deepScriptOptions} from './lib/methods/script.js';\nimport {getIpcExport} from './lib/ipc/methods.js';\n\nexport {parseCommandString} from './lib/methods/command.js';\nexport {ExecaError, ExecaSyncError} from './lib/return/final-error.js';\n\nexport const execa = createExeca(() => ({}));\nexport const execaSync = createExeca(() => ({isSync: true}));\nexport const execaCommand = createExeca(mapCommandAsync);\nexport const execaCommandSync = createExeca(mapCommandSync);\nexport const execaNode = createExeca(mapNode);\nexport const $ = createExeca(mapScriptAsync, {}, deepScriptOptions, setScriptSync);\n\nconst {\n\tsendMessage,\n\tgetOneMessage,\n\tgetEachMessage,\n\tgetCancelSignal,\n} = getIpcExport();\nexport {\n\tsendMessage,\n\tgetOneMessage,\n\tgetEachMessage,\n\tgetCancelSignal,\n};\n","\"use strict\";\n/**\n * This is the Posix implementation of isexe, which uses the file\n * mode and uid/gid values.\n *\n * @module\n */\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.sync = exports.isexe = void 0;\nconst fs_1 = require(\"fs\");\nconst promises_1 = require(\"fs/promises\");\n/**\n * Determine whether a path is executable according to the mode and\n * current (or specified) user and group IDs.\n */\nconst isexe = async (path, options = {}) => {\n const { ignoreErrors = false } = options;\n try {\n return checkStat(await (0, promises_1.stat)(path), options);\n }\n catch (e) {\n const er = e;\n if (ignoreErrors || er.code === 'EACCES')\n return false;\n throw er;\n }\n};\nexports.isexe = isexe;\n/**\n * Synchronously determine whether a path is executable according to\n * the mode and current (or specified) user and group IDs.\n */\nconst sync = (path, options = {}) => {\n const { ignoreErrors = false } = options;\n try {\n return checkStat((0, fs_1.statSync)(path), options);\n }\n catch (e) {\n const er = e;\n if (ignoreErrors || er.code === 'EACCES')\n return false;\n throw er;\n }\n};\nexports.sync = sync;\nconst checkStat = (stat, options) => stat.isFile() && checkMode(stat, options);\nconst checkMode = (stat, options) => {\n const myUid = options.uid ?? process.getuid?.();\n const myGroups = options.groups ?? process.getgroups?.() ?? [];\n const myGid = options.gid ?? process.getgid?.() ?? myGroups[0];\n if (myUid === undefined || myGid === undefined) {\n throw new Error('cannot get uid or gid');\n }\n const groups = new Set([myGid, ...myGroups]);\n const mod = stat.mode;\n const uid = stat.uid;\n const gid = stat.gid;\n const u = parseInt('100', 8);\n const g = parseInt('010', 8);\n const o = parseInt('001', 8);\n const ug = u | g;\n return !!(mod & o ||\n (mod & g && groups.has(gid)) ||\n (mod & u && uid === myUid) ||\n (mod & ug && myUid === 0));\n};\n//# sourceMappingURL=posix.js.map","\"use strict\";\n/**\n * This is the Windows implementation of isexe, which uses the file\n * extension and PATHEXT setting.\n *\n * @module\n */\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.sync = exports.isexe = void 0;\nconst fs_1 = require(\"fs\");\nconst promises_1 = require(\"fs/promises\");\n/**\n * Determine whether a path is executable based on the file extension\n * and PATHEXT environment variable (or specified pathExt option)\n */\nconst isexe = async (path, options = {}) => {\n const { ignoreErrors = false } = options;\n try {\n return checkStat(await (0, promises_1.stat)(path), path, options);\n }\n catch (e) {\n const er = e;\n if (ignoreErrors || er.code === 'EACCES')\n return false;\n throw er;\n }\n};\nexports.isexe = isexe;\n/**\n * Synchronously determine whether a path is executable based on the file\n * extension and PATHEXT environment variable (or specified pathExt option)\n */\nconst sync = (path, options = {}) => {\n const { ignoreErrors = false } = options;\n try {\n return checkStat((0, fs_1.statSync)(path), path, options);\n }\n catch (e) {\n const er = e;\n if (ignoreErrors || er.code === 'EACCES')\n return false;\n throw er;\n }\n};\nexports.sync = sync;\nconst checkPathExt = (path, options) => {\n const { pathExt = process.env.PATHEXT || '' } = options;\n const peSplit = pathExt.split(';');\n if (peSplit.indexOf('') !== -1) {\n return true;\n }\n for (let i = 0; i < peSplit.length; i++) {\n const p = peSplit[i].toLowerCase();\n const ext = path.substring(path.length - p.length).toLowerCase();\n if (p && ext === p) {\n return true;\n }\n }\n return false;\n};\nconst checkStat = (stat, path, options) => stat.isFile() && checkPathExt(path, options);\n//# sourceMappingURL=win32.js.map","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\n//# sourceMappingURL=options.js.map","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n var desc = Object.getOwnPropertyDescriptor(m, k);\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\n desc = { enumerable: true, get: function() { return m[k]; } };\n }\n Object.defineProperty(o, k2, desc);\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __exportStar = (this && this.__exportStar) || function(m, exports) {\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.sync = exports.isexe = exports.posix = exports.win32 = void 0;\nconst posix = __importStar(require(\"./posix.js\"));\nexports.posix = posix;\nconst win32 = __importStar(require(\"./win32.js\"));\nexports.win32 = win32;\n__exportStar(require(\"./options.js\"), exports);\nconst platform = process.env._ISEXE_TEST_PLATFORM_ || process.platform;\nconst impl = platform === 'win32' ? win32 : posix;\n/**\n * Determine whether a path is executable on the current platform.\n */\nexports.isexe = impl.isexe;\n/**\n * Synchronously determine whether a path is executable on the\n * current platform.\n */\nexports.sync = impl.sync;\n//# sourceMappingURL=index.js.map","const { isexe, sync: isexeSync } = require('isexe')\nconst { join, delimiter, sep, posix } = require('path')\n\nconst isWindows = process.platform === 'win32'\n\n// used to check for slashed in commands passed in. always checks for the posix\n// seperator on all platforms, and checks for the current separator when not on\n// a posix platform. don't use the isWindows check for this since that is mocked\n// in tests but we still need the code to actually work when called. that is also\n// why it is ignored from coverage.\n/* istanbul ignore next */\nconst rSlash = new RegExp(`[${posix.sep}${sep === posix.sep ? '' : sep}]`.replace(/(\\\\)/g, '\\\\$1'))\nconst rRel = new RegExp(`^\\\\.${rSlash.source}`)\n\nconst getNotFoundError = (cmd) =>\n Object.assign(new Error(`not found: ${cmd}`), { code: 'ENOENT' })\n\nconst getPathInfo = (cmd, {\n path: optPath = process.env.PATH,\n pathExt: optPathExt = process.env.PATHEXT,\n delimiter: optDelimiter = delimiter,\n}) => {\n // If it has a slash, then we don't bother searching the pathenv.\n // just check the file itself, and that's it.\n const pathEnv = cmd.match(rSlash) ? [''] : [\n // windows always checks the cwd first\n ...(isWindows ? [process.cwd()] : []),\n ...(optPath || /* istanbul ignore next: very unusual */ '').split(optDelimiter),\n ]\n\n if (isWindows) {\n const pathExtExe = optPathExt ||\n ['.EXE', '.CMD', '.BAT', '.COM'].join(optDelimiter)\n const pathExt = pathExtExe.split(optDelimiter).flatMap((item) => [item, item.toLowerCase()])\n if (cmd.includes('.') && pathExt[0] !== '') {\n pathExt.unshift('')\n }\n return { pathEnv, pathExt, pathExtExe }\n }\n\n return { pathEnv, pathExt: [''] }\n}\n\nconst getPathPart = (raw, cmd) => {\n const pathPart = /^\".*\"$/.test(raw) ? raw.slice(1, -1) : raw\n const prefix = !pathPart && rRel.test(cmd) ? cmd.slice(0, 2) : ''\n return prefix + join(pathPart, cmd)\n}\n\nconst which = async (cmd, opt = {}) => {\n const { pathEnv, pathExt, pathExtExe } = getPathInfo(cmd, opt)\n const found = []\n\n for (const envPart of pathEnv) {\n const p = getPathPart(envPart, cmd)\n\n for (const ext of pathExt) {\n const withExt = p + ext\n const is = await isexe(withExt, { pathExt: pathExtExe, ignoreErrors: true })\n if (is) {\n if (!opt.all) {\n return withExt\n }\n found.push(withExt)\n }\n }\n }\n\n if (opt.all && found.length) {\n return found\n }\n\n if (opt.nothrow) {\n return null\n }\n\n throw getNotFoundError(cmd)\n}\n\nconst whichSync = (cmd, opt = {}) => {\n const { pathEnv, pathExt, pathExtExe } = getPathInfo(cmd, opt)\n const found = []\n\n for (const pathEnvPart of pathEnv) {\n const p = getPathPart(pathEnvPart, cmd)\n\n for (const ext of pathExt) {\n const withExt = p + ext\n const is = isexeSync(withExt, { pathExt: pathExtExe, ignoreErrors: true })\n if (is) {\n if (!opt.all) {\n return withExt\n }\n found.push(withExt)\n }\n }\n }\n\n if (opt.all && found.length) {\n return found\n }\n\n if (opt.nothrow) {\n return null\n }\n\n throw getNotFoundError(cmd)\n}\n\nmodule.exports = which\nwhich.sync = whichSync\n","const { isexe, sync: isexeSync } = require('isexe')\nconst { join, delimiter, sep, posix } = require('path')\n\nconst isWindows = process.platform === 'win32'\n\n// used to check for slashed in commands passed in. always checks for the posix\n// seperator on all platforms, and checks for the current separator when not on\n// a posix platform. don't use the isWindows check for this since that is mocked\n// in tests but we still need the code to actually work when called. that is also\n// why it is ignored from coverage.\n/* istanbul ignore next */\nconst rSlash = new RegExp(`[${posix.sep}${sep === posix.sep ? '' : sep}]`.replace(/(\\\\)/g, '\\\\$1'))\nconst rRel = new RegExp(`^\\\\.${rSlash.source}`)\n\nconst getNotFoundError = (cmd) =>\n Object.assign(new Error(`not found: ${cmd}`), { code: 'ENOENT' })\n\nconst getPathInfo = (cmd, {\n path: optPath = process.env.PATH,\n pathExt: optPathExt = process.env.PATHEXT,\n delimiter: optDelimiter = delimiter,\n}) => {\n // If it has a slash, then we don't bother searching the pathenv.\n // just check the file itself, and that's it.\n const pathEnv = cmd.match(rSlash) ? [''] : [\n // windows always checks the cwd first\n ...(isWindows ? [process.cwd()] : []),\n ...(optPath || /* istanbul ignore next: very unusual */ '').split(optDelimiter),\n ]\n\n if (isWindows) {\n const pathExtExe = optPathExt ||\n ['.EXE', '.CMD', '.BAT', '.COM'].join(optDelimiter)\n const pathExt = pathExtExe.split(optDelimiter).flatMap((item) => [item, item.toLowerCase()])\n if (cmd.includes('.') && pathExt[0] !== '') {\n pathExt.unshift('')\n }\n return { pathEnv, pathExt, pathExtExe }\n }\n\n return { pathEnv, pathExt: [''] }\n}\n\nconst getPathPart = (raw, cmd) => {\n const pathPart = /^\".*\"$/.test(raw) ? raw.slice(1, -1) : raw\n const prefix = !pathPart && rRel.test(cmd) ? cmd.slice(0, 2) : ''\n return prefix + join(pathPart, cmd)\n}\n\nconst which = async (cmd, opt = {}) => {\n const { pathEnv, pathExt, pathExtExe } = getPathInfo(cmd, opt)\n const found = []\n\n for (const envPart of pathEnv) {\n const p = getPathPart(envPart, cmd)\n\n for (const ext of pathExt) {\n const withExt = p + ext\n const is = await isexe(withExt, { pathExt: pathExtExe, ignoreErrors: true })\n if (is) {\n if (!opt.all) {\n return withExt\n }\n found.push(withExt)\n }\n }\n }\n\n if (opt.all && found.length) {\n return found\n }\n\n if (opt.nothrow) {\n return null\n }\n\n throw getNotFoundError(cmd)\n}\n\nconst whichSync = (cmd, opt = {}) => {\n const { pathEnv, pathExt, pathExtExe } = getPathInfo(cmd, opt)\n const found = []\n\n for (const pathEnvPart of pathEnv) {\n const p = getPathPart(pathEnvPart, cmd)\n\n for (const ext of pathExt) {\n const withExt = p + ext\n const is = isexeSync(withExt, { pathExt: pathExtExe, ignoreErrors: true })\n if (is) {\n if (!opt.all) {\n return withExt\n }\n found.push(withExt)\n }\n }\n }\n\n if (opt.all && found.length) {\n return found\n }\n\n if (opt.nothrow) {\n return null\n }\n\n throw getNotFoundError(cmd)\n}\n\nmodule.exports = which\nwhich.sync = whichSync\n","import process from 'node:process';\nimport path from 'node:path';\nimport {fileURLToPath} from 'node:url';\nimport pathKey from 'path-key';\n\nexport const npmRunPath = ({\n\tcwd = process.cwd(),\n\tpath: pathOption = process.env[pathKey()],\n\tpreferLocal = true,\n\texecPath = process.execPath,\n\taddExecPath = true,\n} = {}) => {\n\tconst cwdString = cwd instanceof URL ? fileURLToPath(cwd) : cwd;\n\tconst cwdPath = path.resolve(cwdString);\n\tconst result = [];\n\n\tif (preferLocal) {\n\t\tapplyPreferLocal(result, cwdPath);\n\t}\n\n\tif (addExecPath) {\n\t\tapplyExecPath(result, execPath, cwdPath);\n\t}\n\n\treturn [...result, pathOption].join(path.delimiter);\n};\n\nconst applyPreferLocal = (result, cwdPath) => {\n\tlet previous;\n\n\twhile (previous !== cwdPath) {\n\t\tresult.push(path.join(cwdPath, 'node_modules/.bin'));\n\t\tprevious = cwdPath;\n\t\tcwdPath = path.resolve(cwdPath, '..');\n\t}\n};\n\n// Ensure the running `node` binary is used\nconst applyExecPath = (result, execPath, cwdPath) => {\n\tconst execPathString = execPath instanceof URL ? fileURLToPath(execPath) : execPath;\n\tresult.push(path.resolve(cwdPath, execPathString, '..'));\n};\n\nexport const npmRunPathEnv = ({env = process.env, ...options} = {}) => {\n\tenv = {...env};\n\n\tconst pathName = pathKey({env});\n\toptions.path = env[pathName];\n\tenv[pathName] = npmRunPath(options);\n\n\treturn env;\n};\n","const copyProperty = (to, from, property, ignoreNonConfigurable) => {\n\t// `Function#length` should reflect the parameters of `to` not `from` since we keep its body.\n\t// `Function#prototype` is non-writable and non-configurable so can never be modified.\n\tif (property === 'length' || property === 'prototype') {\n\t\treturn;\n\t}\n\n\t// `Function#arguments` and `Function#caller` should not be copied. They were reported to be present in `Reflect.ownKeys` for some devices in React Native (#41), so we explicitly ignore them here.\n\tif (property === 'arguments' || property === 'caller') {\n\t\treturn;\n\t}\n\n\tconst toDescriptor = Object.getOwnPropertyDescriptor(to, property);\n\tconst fromDescriptor = Object.getOwnPropertyDescriptor(from, property);\n\n\tif (!canCopyProperty(toDescriptor, fromDescriptor) && ignoreNonConfigurable) {\n\t\treturn;\n\t}\n\n\tObject.defineProperty(to, property, fromDescriptor);\n};\n\n// `Object.defineProperty()` throws if the property exists, is not configurable and either:\n// - one its descriptors is changed\n// - it is non-writable and its value is changed\nconst canCopyProperty = function (toDescriptor, fromDescriptor) {\n\treturn toDescriptor === undefined || toDescriptor.configurable || (\n\t\ttoDescriptor.writable === fromDescriptor.writable &&\n\t\ttoDescriptor.enumerable === fromDescriptor.enumerable &&\n\t\ttoDescriptor.configurable === fromDescriptor.configurable &&\n\t\t(toDescriptor.writable || toDescriptor.value === fromDescriptor.value)\n\t);\n};\n\nconst changePrototype = (to, from) => {\n\tconst fromPrototype = Object.getPrototypeOf(from);\n\tif (fromPrototype === Object.getPrototypeOf(to)) {\n\t\treturn;\n\t}\n\n\tObject.setPrototypeOf(to, fromPrototype);\n};\n\nconst wrappedToString = (withName, fromBody) => `/* Wrapped ${withName}*/\\n${fromBody}`;\n\nconst toStringDescriptor = Object.getOwnPropertyDescriptor(Function.prototype, 'toString');\nconst toStringName = Object.getOwnPropertyDescriptor(Function.prototype.toString, 'name');\n\n// We call `from.toString()` early (not lazily) to ensure `from` can be garbage collected.\n// We use `bind()` instead of a closure for the same reason.\n// Calling `from.toString()` early also allows caching it in case `to.toString()` is called several times.\nconst changeToString = (to, from, name) => {\n\tconst withName = name === '' ? '' : `with ${name.trim()}() `;\n\tconst newToString = wrappedToString.bind(null, withName, from.toString());\n\t// Ensure `to.toString.toString` is non-enumerable and has the same `same`\n\tObject.defineProperty(newToString, 'name', toStringName);\n\tObject.defineProperty(to, 'toString', {...toStringDescriptor, value: newToString});\n};\n\nexport default function mimicFunction(to, from, {ignoreNonConfigurable = false} = {}) {\n\tconst {name} = to;\n\n\tfor (const property of Reflect.ownKeys(from)) {\n\t\tcopyProperty(to, from, property, ignoreNonConfigurable);\n\t}\n\n\tchangePrototype(to, from);\n\tchangeToString(to, from, name);\n\n\treturn to;\n}\n","import mimicFunction from 'mimic-fn';\n\nconst calledFunctions = new WeakMap();\n\nconst onetime = (function_, options = {}) => {\n\tif (typeof function_ !== 'function') {\n\t\tthrow new TypeError('Expected a function');\n\t}\n\n\tlet returnValue;\n\tlet callCount = 0;\n\tconst functionName = function_.displayName || function_.name || '<anonymous>';\n\n\tconst onetime = function (...arguments_) {\n\t\tcalledFunctions.set(onetime, ++callCount);\n\n\t\tif (callCount === 1) {\n\t\t\treturnValue = function_.apply(this, arguments_);\n\t\t\tfunction_ = null;\n\t\t} else if (options.throw === true) {\n\t\t\tthrow new Error(`Function \\`${functionName}\\` can only be called once`);\n\t\t}\n\n\t\treturn returnValue;\n\t};\n\n\tmimicFunction(onetime, function_);\n\tcalledFunctions.set(onetime, callCount);\n\n\treturn onetime;\n};\n\nonetime.callCount = function_ => {\n\tif (!calledFunctions.has(function_)) {\n\t\tthrow new Error(`The given function \\`${function_.name}\\` is not wrapped by the \\`onetime\\` package`);\n\t}\n\n\treturn calledFunctions.get(function_);\n};\n\nexport default onetime;\n","\nexport const getRealtimeSignals=()=>{\nconst length=SIGRTMAX-SIGRTMIN+1;\nreturn Array.from({length},getRealtimeSignal);\n};\n\nconst getRealtimeSignal=(value,index)=>({\nname:`SIGRT${index+1}`,\nnumber:SIGRTMIN+index,\naction:\"terminate\",\ndescription:\"Application-specific signal (realtime)\",\nstandard:\"posix\"\n});\n\nconst SIGRTMIN=34;\nexport const SIGRTMAX=64;","\n\nexport const SIGNALS=[\n{\nname:\"SIGHUP\",\nnumber:1,\naction:\"terminate\",\ndescription:\"Terminal closed\",\nstandard:\"posix\"\n},\n{\nname:\"SIGINT\",\nnumber:2,\naction:\"terminate\",\ndescription:\"User interruption with CTRL-C\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGQUIT\",\nnumber:3,\naction:\"core\",\ndescription:\"User interruption with CTRL-\\\\\",\nstandard:\"posix\"\n},\n{\nname:\"SIGILL\",\nnumber:4,\naction:\"core\",\ndescription:\"Invalid machine instruction\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGTRAP\",\nnumber:5,\naction:\"core\",\ndescription:\"Debugger breakpoint\",\nstandard:\"posix\"\n},\n{\nname:\"SIGABRT\",\nnumber:6,\naction:\"core\",\ndescription:\"Aborted\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGIOT\",\nnumber:6,\naction:\"core\",\ndescription:\"Aborted\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGBUS\",\nnumber:7,\naction:\"core\",\ndescription:\n\"Bus error due to misaligned, non-existing address or paging error\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGEMT\",\nnumber:7,\naction:\"terminate\",\ndescription:\"Command should be emulated but is not implemented\",\nstandard:\"other\"\n},\n{\nname:\"SIGFPE\",\nnumber:8,\naction:\"core\",\ndescription:\"Floating point arithmetic error\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGKILL\",\nnumber:9,\naction:\"terminate\",\ndescription:\"Forced termination\",\nstandard:\"posix\",\nforced:true\n},\n{\nname:\"SIGUSR1\",\nnumber:10,\naction:\"terminate\",\ndescription:\"Application-specific signal\",\nstandard:\"posix\"\n},\n{\nname:\"SIGSEGV\",\nnumber:11,\naction:\"core\",\ndescription:\"Segmentation fault\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGUSR2\",\nnumber:12,\naction:\"terminate\",\ndescription:\"Application-specific signal\",\nstandard:\"posix\"\n},\n{\nname:\"SIGPIPE\",\nnumber:13,\naction:\"terminate\",\ndescription:\"Broken pipe or socket\",\nstandard:\"posix\"\n},\n{\nname:\"SIGALRM\",\nnumber:14,\naction:\"terminate\",\ndescription:\"Timeout or timer\",\nstandard:\"posix\"\n},\n{\nname:\"SIGTERM\",\nnumber:15,\naction:\"terminate\",\ndescription:\"Termination\",\nstandard:\"ansi\"\n},\n{\nname:\"SIGSTKFLT\",\nnumber:16,\naction:\"terminate\",\ndescription:\"Stack is empty or overflowed\",\nstandard:\"other\"\n},\n{\nname:\"SIGCHLD\",\nnumber:17,\naction:\"ignore\",\ndescription:\"Child process terminated, paused or unpaused\",\nstandard:\"posix\"\n},\n{\nname:\"SIGCLD\",\nnumber:17,\naction:\"ignore\",\ndescription:\"Child process terminated, paused or unpaused\",\nstandard:\"other\"\n},\n{\nname:\"SIGCONT\",\nnumber:18,\naction:\"unpause\",\ndescription:\"Unpaused\",\nstandard:\"posix\",\nforced:true\n},\n{\nname:\"SIGSTOP\",\nnumber:19,\naction:\"pause\",\ndescription:\"Paused\",\nstandard:\"posix\",\nforced:true\n},\n{\nname:\"SIGTSTP\",\nnumber:20,\naction:\"pause\",\ndescription:\"Paused using CTRL-Z or \\\"suspend\\\"\",\nstandard:\"posix\"\n},\n{\nname:\"SIGTTIN\",\nnumber:21,\naction:\"pause\",\ndescription:\"Background process cannot read terminal input\",\nstandard:\"posix\"\n},\n{\nname:\"SIGBREAK\",\nnumber:21,\naction:\"terminate\",\ndescription:\"User interruption with CTRL-BREAK\",\nstandard:\"other\"\n},\n{\nname:\"SIGTTOU\",\nnumber:22,\naction:\"pause\",\ndescription:\"Background process cannot write to terminal output\",\nstandard:\"posix\"\n},\n{\nname:\"SIGURG\",\nnumber:23,\naction:\"ignore\",\ndescription:\"Socket received out-of-band data\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGXCPU\",\nnumber:24,\naction:\"core\",\ndescription:\"Process timed out\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGXFSZ\",\nnumber:25,\naction:\"core\",\ndescription:\"File too big\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGVTALRM\",\nnumber:26,\naction:\"terminate\",\ndescription:\"Timeout or timer\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGPROF\",\nnumber:27,\naction:\"terminate\",\ndescription:\"Timeout or timer\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGWINCH\",\nnumber:28,\naction:\"ignore\",\ndescription:\"Terminal window size changed\",\nstandard:\"bsd\"\n},\n{\nname:\"SIGIO\",\nnumber:29,\naction:\"terminate\",\ndescription:\"I/O is available\",\nstandard:\"other\"\n},\n{\nname:\"SIGPOLL\",\nnumber:29,\naction:\"terminate\",\ndescription:\"Watched event\",\nstandard:\"other\"\n},\n{\nname:\"SIGINFO\",\nnumber:29,\naction:\"ignore\",\ndescription:\"Request for process information\",\nstandard:\"other\"\n},\n{\nname:\"SIGPWR\",\nnumber:30,\naction:\"terminate\",\ndescription:\"Device running out of power\",\nstandard:\"systemv\"\n},\n{\nname:\"SIGSYS\",\nnumber:31,\naction:\"core\",\ndescription:\"Invalid system call\",\nstandard:\"other\"\n},\n{\nname:\"SIGUNUSED\",\nnumber:31,\naction:\"terminate\",\ndescription:\"Invalid system call\",\nstandard:\"other\"\n}];","import{constants}from\"node:os\";\n\nimport{SIGNALS}from\"./core.js\";\nimport{getRealtimeSignals}from\"./realtime.js\";\n\n\n\nexport const getSignals=()=>{\nconst realtimeSignals=getRealtimeSignals();\nconst signals=[...SIGNALS,...realtimeSignals].map(normalizeSignal);\nreturn signals;\n};\n\n\n\n\n\n\n\nconst normalizeSignal=({\nname,\nnumber:defaultNumber,\ndescription,\naction,\nforced=false,\nstandard\n})=>{\nconst{\nsignals:{[name]:constantSignal}\n}=constants;\nconst supported=constantSignal!==undefined;\nconst number=supported?constantSignal:defaultNumber;\nreturn{name,number,description,supported,action,forced,standard};\n};","import{constants}from\"node:os\";\n\nimport{SIGRTMAX}from\"./realtime.js\";\nimport{getSignals}from\"./signals.js\";\n\n\n\nconst getSignalsByName=()=>{\nconst signals=getSignals();\nreturn Object.fromEntries(signals.map(getSignalByName));\n};\n\nconst getSignalByName=({\nname,\nnumber,\ndescription,\nsupported,\naction,\nforced,\nstandard\n})=>[name,{name,number,description,supported,action,forced,standard}];\n\nexport const signalsByName=getSignalsByName();\n\n\n\n\nconst getSignalsByNumber=()=>{\nconst signals=getSignals();\nconst length=SIGRTMAX+1;\nconst signalsA=Array.from({length},(value,number)=>\ngetSignalByNumber(number,signals));\n\nreturn Object.assign({},...signalsA);\n};\n\nconst getSignalByNumber=(number,signals)=>{\nconst signal=findSignalByNumber(number,signals);\n\nif(signal===undefined){\nreturn{};\n}\n\nconst{name,description,supported,action,forced,standard}=signal;\nreturn{\n[number]:{\nname,\nnumber,\ndescription,\nsupported,\naction,\nforced,\nstandard\n}\n};\n};\n\n\n\nconst findSignalByNumber=(number,signals)=>{\nconst signal=signals.find(({name})=>constants.signals[name]===number);\n\nif(signal!==undefined){\nreturn signal;\n}\n\nreturn signals.find((signalA)=>signalA.number===number);\n};\n\nexport const signalsByNumber=getSignalsByNumber();","import process from 'node:process';\nimport {signalsByName} from 'human-signals';\n\nconst getErrorPrefix = ({timedOut, timeout, errorCode, signal, signalDescription, exitCode, isCanceled}) => {\n\tif (timedOut) {\n\t\treturn `timed out after ${timeout} milliseconds`;\n\t}\n\n\tif (isCanceled) {\n\t\treturn 'was canceled';\n\t}\n\n\tif (errorCode !== undefined) {\n\t\treturn `failed with ${errorCode}`;\n\t}\n\n\tif (signal !== undefined) {\n\t\treturn `was killed with ${signal} (${signalDescription})`;\n\t}\n\n\tif (exitCode !== undefined) {\n\t\treturn `failed with exit code ${exitCode}`;\n\t}\n\n\treturn 'failed';\n};\n\nexport const makeError = ({\n\tstdout,\n\tstderr,\n\tall,\n\terror,\n\tsignal,\n\texitCode,\n\tcommand,\n\tescapedCommand,\n\ttimedOut,\n\tisCanceled,\n\tkilled,\n\tparsed: {options: {timeout, cwd = process.cwd()}},\n}) => {\n\t// `signal` and `exitCode` emitted on `spawned.on('exit')` event can be `null`.\n\t// We normalize them to `undefined`\n\texitCode = exitCode === null ? undefined : exitCode;\n\tsignal = signal === null ? undefined : signal;\n\tconst signalDescription = signal === undefined ? undefined : signalsByName[signal].description;\n\n\tconst errorCode = error && error.code;\n\n\tconst prefix = getErrorPrefix({timedOut, timeout, errorCode, signal, signalDescription, exitCode, isCanceled});\n\tconst execaMessage = `Command ${prefix}: ${command}`;\n\tconst isError = Object.prototype.toString.call(error) === '[object Error]';\n\tconst shortMessage = isError ? `${execaMessage}\\n${error.message}` : execaMessage;\n\tconst message = [shortMessage, stderr, stdout].filter(Boolean).join('\\n');\n\n\tif (isError) {\n\t\terror.originalMessage = error.message;\n\t\terror.message = message;\n\t} else {\n\t\terror = new Error(message);\n\t}\n\n\terror.shortMessage = shortMessage;\n\terror.command = command;\n\terror.escapedCommand = escapedCommand;\n\terror.exitCode = exitCode;\n\terror.signal = signal;\n\terror.signalDescription = signalDescription;\n\terror.stdout = stdout;\n\terror.stderr = stderr;\n\terror.cwd = cwd;\n\n\tif (all !== undefined) {\n\t\terror.all = all;\n\t}\n\n\tif ('bufferedData' in error) {\n\t\tdelete error.bufferedData;\n\t}\n\n\terror.failed = true;\n\terror.timedOut = Boolean(timedOut);\n\terror.isCanceled = isCanceled;\n\terror.killed = killed && !timedOut;\n\n\treturn error;\n};\n","const aliases = ['stdin', 'stdout', 'stderr'];\n\nconst hasAlias = options => aliases.some(alias => options[alias] !== undefined);\n\nexport const normalizeStdio = options => {\n\tif (!options) {\n\t\treturn;\n\t}\n\n\tconst {stdio} = options;\n\n\tif (stdio === undefined) {\n\t\treturn aliases.map(alias => options[alias]);\n\t}\n\n\tif (hasAlias(options)) {\n\t\tthrow new Error(`It's not possible to provide \\`stdio\\` in combination with one of ${aliases.map(alias => `\\`${alias}\\``).join(', ')}`);\n\t}\n\n\tif (typeof stdio === 'string') {\n\t\treturn stdio;\n\t}\n\n\tif (!Array.isArray(stdio)) {\n\t\tthrow new TypeError(`Expected \\`stdio\\` to be of type \\`string\\` or \\`Array\\`, got \\`${typeof stdio}\\``);\n\t}\n\n\tconst length = Math.max(stdio.length, aliases.length);\n\treturn Array.from({length}, (value, index) => stdio[index]);\n};\n\n// `ipc` is pushed unless it is already present\nexport const normalizeStdioNode = options => {\n\tconst stdio = normalizeStdio(options);\n\n\tif (stdio === 'ipc') {\n\t\treturn 'ipc';\n\t}\n\n\tif (stdio === undefined || typeof stdio === 'string') {\n\t\treturn [stdio, stdio, stdio, 'ipc'];\n\t}\n\n\tif (stdio.includes('ipc')) {\n\t\treturn stdio;\n\t}\n\n\treturn [...stdio, 'ipc'];\n};\n","// Note: since nyc uses this module to output coverage, any lines\n// that are in the direct sync flow of nyc's outputCoverage are\n// ignored, since we can never get coverage for them.\n// grab a reference to node's real process object right away\nvar process = global.process\n\nconst processOk = function (process) {\n return process &&\n typeof process === 'object' &&\n typeof process.removeListener === 'function' &&\n typeof process.emit === 'function' &&\n typeof process.reallyExit === 'function' &&\n typeof process.listeners === 'function' &&\n typeof process.kill === 'function' &&\n typeof process.pid === 'number' &&\n typeof process.on === 'function'\n}\n\n// some kind of non-node environment, just no-op\n/* istanbul ignore if */\nif (!processOk(process)) {\n module.exports = function () {\n return function () {}\n }\n} else {\n var assert = require('assert')\n var signals = require('./signals.js')\n var isWin = /^win/i.test(process.platform)\n\n var EE = require('events')\n /* istanbul ignore if */\n if (typeof EE !== 'function') {\n EE = EE.EventEmitter\n }\n\n var emitter\n if (process.__signal_exit_emitter__) {\n emitter = process.__signal_exit_emitter__\n } else {\n emitter = process.__signal_exit_emitter__ = new EE()\n emitter.count = 0\n emitter.emitted = {}\n }\n\n // Because this emitter is a global, we have to check to see if a\n // previous version of this library failed to enable infinite listeners.\n // I know what you're about to say. But literally everything about\n // signal-exit is a compromise with evil. Get used to it.\n if (!emitter.infinite) {\n emitter.setMaxListeners(Infinity)\n emitter.infinite = true\n }\n\n module.exports = function (cb, opts) {\n /* istanbul ignore if */\n if (!processOk(global.process)) {\n return function () {}\n }\n assert.equal(typeof cb, 'function', 'a callback must be provided for exit handler')\n\n if (loaded === false) {\n load()\n }\n\n var ev = 'exit'\n if (opts && opts.alwaysLast) {\n ev = 'afterexit'\n }\n\n var remove = function () {\n emitter.removeListener(ev, cb)\n if (emitter.listeners('exit').length === 0 &&\n emitter.listeners('afterexit').length === 0) {\n unload()\n }\n }\n emitter.on(ev, cb)\n\n return remove\n }\n\n var unload = function unload () {\n if (!loaded || !processOk(global.process)) {\n return\n }\n loaded = false\n\n signals.forEach(function (sig) {\n try {\n process.removeListener(sig, sigListeners[sig])\n } catch (er) {}\n })\n process.emit = originalProcessEmit\n process.reallyExit = originalProcessReallyExit\n emitter.count -= 1\n }\n module.exports.unload = unload\n\n var emit = function emit (event, code, signal) {\n /* istanbul ignore if */\n if (emitter.emitted[event]) {\n return\n }\n emitter.emitted[event] = true\n emitter.emit(event, code, signal)\n }\n\n // { <signal>: <listener fn>, ... }\n var sigListeners = {}\n signals.forEach(function (sig) {\n sigListeners[sig] = function listener () {\n /* istanbul ignore if */\n if (!processOk(global.process)) {\n return\n }\n // If there are no other listeners, an exit is coming!\n // Simplest way: remove us and then re-send the signal.\n // We know that this will kill the process, so we can\n // safely emit now.\n var listeners = process.listeners(sig)\n if (listeners.length === emitter.count) {\n unload()\n emit('exit', null, sig)\n /* istanbul ignore next */\n emit('afterexit', null, sig)\n /* istanbul ignore next */\n if (isWin && sig === 'SIGHUP') {\n // \"SIGHUP\" throws an `ENOSYS` error on Windows,\n // so use a supported signal instead\n sig = 'SIGINT'\n }\n /* istanbul ignore next */\n process.kill(process.pid, sig)\n }\n }\n })\n\n module.exports.signals = function () {\n return signals\n }\n\n var loaded = false\n\n var load = function load () {\n if (loaded || !processOk(global.process)) {\n return\n }\n loaded = true\n\n // This is the number of onSignalExit's that are in play.\n // It's important so that we can count the correct number of\n // listeners on signals, and don't wait for the other one to\n // handle it instead of us.\n emitter.count += 1\n\n signals = signals.filter(function (sig) {\n try {\n process.on(sig, sigListeners[sig])\n return true\n } catch (er) {\n return false\n }\n })\n\n process.emit = processEmit\n process.reallyExit = processReallyExit\n }\n module.exports.load = load\n\n var originalProcessReallyExit = process.reallyExit\n var processReallyExit = function processReallyExit (code) {\n /* istanbul ignore if */\n if (!processOk(global.process)) {\n return\n }\n process.exitCode = code || /* istanbul ignore next */ 0\n emit('exit', process.exitCode, null)\n /* istanbul ignore next */\n emit('afterexit', process.exitCode, null)\n /* istanbul ignore next */\n originalProcessReallyExit.call(process, process.exitCode)\n }\n\n var originalProcessEmit = process.emit\n var processEmit = function processEmit (ev, arg) {\n if (ev === 'exit' && processOk(global.process)) {\n /* istanbul ignore else */\n if (arg !== undefined) {\n process.exitCode = arg\n }\n var ret = originalProcessEmit.apply(this, arguments)\n /* istanbul ignore next */\n emit('exit', process.exitCode, null)\n /* istanbul ignore next */\n emit('afterexit', process.exitCode, null)\n /* istanbul ignore next */\n return ret\n } else {\n return originalProcessEmit.apply(this, arguments)\n }\n }\n}\n","// This is not the set of all possible signals.\n//\n// It IS, however, the set of all signals that trigger\n// an exit on either Linux or BSD systems. Linux is a\n// superset of the signal names supported on BSD, and\n// the unknown signals just fail to register, so we can\n// catch that easily enough.\n//\n// Don't bother with SIGKILL. It's uncatchable, which\n// means that we can't fire any callbacks anyway.\n//\n// If a user does happen to register a handler on a non-\n// fatal signal like SIGWINCH or something, and then\n// exit, it'll end up firing `process.emit('exit')`, so\n// the handler will be fired anyway.\n//\n// SIGBUS, SIGFPE, SIGSEGV and SIGILL, when not raised\n// artificially, inherently leave the process in a\n// state from which it is not safe to try and enter JS\n// listeners.\nmodule.exports = [\n 'SIGABRT',\n 'SIGALRM',\n 'SIGHUP',\n 'SIGINT',\n 'SIGTERM'\n]\n\nif (process.platform !== 'win32') {\n module.exports.push(\n 'SIGVTALRM',\n 'SIGXCPU',\n 'SIGXFSZ',\n 'SIGUSR2',\n 'SIGTRAP',\n 'SIGSYS',\n 'SIGQUIT',\n 'SIGIOT'\n // should detect profiler and enable/disable accordingly.\n // see #21\n // 'SIGPROF'\n )\n}\n\nif (process.platform === 'linux') {\n module.exports.push(\n 'SIGIO',\n 'SIGPOLL',\n 'SIGPWR',\n 'SIGSTKFLT',\n 'SIGUNUSED'\n )\n}\n","'use strict';\nconst {PassThrough: PassThroughStream} = require('stream');\n\nmodule.exports = options => {\n\toptions = {...options};\n\n\tconst {array} = options;\n\tlet {encoding} = options;\n\tconst isBuffer = encoding === 'buffer';\n\tlet objectMode = false;\n\n\tif (array) {\n\t\tobjectMode = !(encoding || isBuffer);\n\t} else {\n\t\tencoding = encoding || 'utf8';\n\t}\n\n\tif (isBuffer) {\n\t\tencoding = null;\n\t}\n\n\tconst stream = new PassThroughStream({objectMode});\n\n\tif (encoding) {\n\t\tstream.setEncoding(encoding);\n\t}\n\n\tlet length = 0;\n\tconst chunks = [];\n\n\tstream.on('data', chunk => {\n\t\tchunks.push(chunk);\n\n\t\tif (objectMode) {\n\t\t\tlength = chunks.length;\n\t\t} else {\n\t\t\tlength += chunk.length;\n\t\t}\n\t});\n\n\tstream.getBufferedValue = () => {\n\t\tif (array) {\n\t\t\treturn chunks;\n\t\t}\n\n\t\treturn isBuffer ? Buffer.concat(chunks, length) : chunks.join('');\n\t};\n\n\tstream.getBufferedLength = () => length;\n\n\treturn stream;\n};\n","'use strict';\n\nconst { PassThrough } = require('stream');\n\nmodule.exports = function (/*streams...*/) {\n var sources = []\n var output = new PassThrough({objectMode: true})\n\n output.setMaxListeners(0)\n\n output.add = add\n output.isEmpty = isEmpty\n\n output.on('unpipe', remove)\n\n Array.prototype.slice.call(arguments).forEach(add)\n\n return output\n\n function add (source) {\n if (Array.isArray(source)) {\n source.forEach(add)\n return this\n }\n\n sources.push(source);\n source.once('end', remove.bind(null, source))\n source.once('error', output.emit.bind(output, 'error'))\n source.pipe(output, {end: false})\n return this\n }\n\n function isEmpty () {\n return sources.length == 0;\n }\n\n function remove (source) {\n sources = sources.filter(function (it) { return it !== source })\n if (!sources.length && output.readable) { output.end() }\n }\n}\n","import {Buffer} from 'node:buffer';\nimport {ChildProcess} from 'node:child_process';\n\nconst normalizeArgs = (file, args = []) => {\n\tif (!Array.isArray(args)) {\n\t\treturn [file];\n\t}\n\n\treturn [file, ...args];\n};\n\nconst NO_ESCAPE_REGEXP = /^[\\w.-]+$/;\nconst DOUBLE_QUOTES_REGEXP = /\"/g;\n\nconst escapeArg = arg => {\n\tif (typeof arg !== 'string' || NO_ESCAPE_REGEXP.test(arg)) {\n\t\treturn arg;\n\t}\n\n\treturn `\"${arg.replace(DOUBLE_QUOTES_REGEXP, '\\\\\"')}\"`;\n};\n\nexport const joinCommand = (file, args) => normalizeArgs(file, args).join(' ');\n\nexport const getEscapedCommand = (file, args) => normalizeArgs(file, args).map(arg => escapeArg(arg)).join(' ');\n\nconst SPACES_REGEXP = / +/g;\n\n// Handle `execaCommand()`\nexport const parseCommand = command => {\n\tconst tokens = [];\n\tfor (const token of command.trim().split(SPACES_REGEXP)) {\n\t\t// Allow spaces to be escaped by a backslash if not meant as a delimiter\n\t\tconst previousToken = tokens[tokens.length - 1];\n\t\tif (previousToken && previousToken.endsWith('\\\\')) {\n\t\t\t// Merge previous token with current one\n\t\t\ttokens[tokens.length - 1] = `${previousToken.slice(0, -1)} ${token}`;\n\t\t} else {\n\t\t\ttokens.push(token);\n\t\t}\n\t}\n\n\treturn tokens;\n};\n\nconst parseExpression = expression => {\n\tconst typeOfExpression = typeof expression;\n\n\tif (typeOfExpression === 'string') {\n\t\treturn expression;\n\t}\n\n\tif (typeOfExpression === 'number') {\n\t\treturn String(expression);\n\t}\n\n\tif (\n\t\ttypeOfExpression === 'object'\n\t\t&& expression !== null\n\t\t&& !(expression instanceof ChildProcess)\n\t\t&& 'stdout' in expression\n\t) {\n\t\tconst typeOfStdout = typeof expression.stdout;\n\n\t\tif (typeOfStdout === 'string') {\n\t\t\treturn expression.stdout;\n\t\t}\n\n\t\tif (Buffer.isBuffer(expression.stdout)) {\n\t\t\treturn expression.stdout.toString();\n\t\t}\n\n\t\tthrow new TypeError(`Unexpected \"${typeOfStdout}\" stdout in template expression`);\n\t}\n\n\tthrow new TypeError(`Unexpected \"${typeOfExpression}\" in template expression`);\n};\n\nconst concatTokens = (tokens, nextTokens, isNew) => isNew || tokens.length === 0 || nextTokens.length === 0\n\t? [...tokens, ...nextTokens]\n\t: [\n\t\t...tokens.slice(0, -1),\n\t\t`${tokens[tokens.length - 1]}${nextTokens[0]}`,\n\t\t...nextTokens.slice(1),\n\t];\n\nconst parseTemplate = ({templates, expressions, tokens, index, template}) => {\n\tconst templateString = template ?? templates.raw[index];\n\tconst templateTokens = templateString.split(SPACES_REGEXP).filter(Boolean);\n\tconst newTokens = concatTokens(\n\t\ttokens,\n\t\ttemplateTokens,\n\t\ttemplateString.startsWith(' '),\n\t);\n\n\tif (index === expressions.length) {\n\t\treturn newTokens;\n\t}\n\n\tconst expression = expressions[index];\n\tconst expressionTokens = Array.isArray(expression)\n\t\t? expression.map(expression => parseExpression(expression))\n\t\t: [parseExpression(expression)];\n\treturn concatTokens(\n\t\tnewTokens,\n\t\texpressionTokens,\n\t\ttemplateString.endsWith(' '),\n\t);\n};\n\nexport const parseTemplates = (templates, expressions) => {\n\tlet tokens = [];\n\n\tfor (const [index, template] of templates.entries()) {\n\t\ttokens = parseTemplate({templates, expressions, tokens, index, template});\n\t}\n\n\treturn tokens;\n};\n\n","import {debuglog} from 'node:util';\nimport process from 'node:process';\n\nexport const verboseDefault = debuglog('execa').enabled;\n\nconst padField = (field, padding) => String(field).padStart(padding, '0');\n\nconst getTimestamp = () => {\n\tconst date = new Date();\n\treturn `${padField(date.getHours(), 2)}:${padField(date.getMinutes(), 2)}:${padField(date.getSeconds(), 2)}.${padField(date.getMilliseconds(), 3)}`;\n};\n\nexport const logCommand = (escapedCommand, {verbose}) => {\n\tif (!verbose) {\n\t\treturn;\n\t}\n\n\tprocess.stderr.write(`[${getTimestamp()}] ${escapedCommand}\\n`);\n};\n","export default function stripFinalNewline(input) {\n\tconst LF = typeof input === 'string' ? '\\n' : '\\n'.charCodeAt();\n\tconst CR = typeof input === 'string' ? '\\r' : '\\r'.charCodeAt();\n\n\tif (input[input.length - 1] === LF) {\n\t\tinput = input.slice(0, -1);\n\t}\n\n\tif (input[input.length - 1] === CR) {\n\t\tinput = input.slice(0, -1);\n\t}\n\n\treturn input;\n}\n","\"use strict\";\n\nmodule.exports = function () {\n\tvar sign = Math.sign;\n\tif (typeof sign !== \"function\") return false;\n\treturn sign(10) === 1 && sign(-20) === -1;\n};\n","// Internal method, used by iteration functions.\n// Calls a function for each key-value pair found in object\n// Optionally takes compareFn to iterate object in specific order\n\n\"use strict\";\n\nvar callable = require(\"./valid-callable\")\n , value = require(\"./valid-value\")\n , bind = Function.prototype.bind\n , call = Function.prototype.call\n , keys = Object.keys\n , objPropertyIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nmodule.exports = function (method, defVal) {\n\treturn function (obj, cb /*, thisArg, compareFn*/) {\n\t\tvar list, thisArg = arguments[2], compareFn = arguments[3];\n\t\tobj = Object(value(obj));\n\t\tcallable(cb);\n\n\t\tlist = keys(obj);\n\t\tif (compareFn) {\n\t\t\tlist.sort(typeof compareFn === \"function\" ? bind.call(compareFn, obj) : undefined);\n\t\t}\n\t\tif (typeof method !== \"function\") method = list[method];\n\t\treturn call.call(method, list, function (key, index) {\n\t\t\tif (!objPropertyIsEnumerable.call(obj, key)) return defVal;\n\t\t\treturn call.call(cb, thisArg, obj[key], key, obj, index);\n\t\t});\n\t};\n};\n","\"use strict\";\n\nmodule.exports = function () {\n\tvar assign = Object.assign, obj;\n\tif (typeof assign !== \"function\") return false;\n\tobj = { foo: \"raz\" };\n\tassign(obj, { bar: \"dwa\" }, { trzy: \"trzy\" });\n\treturn obj.foo + obj.bar + obj.trzy === \"razdwatrzy\";\n};\n","\"use strict\";\n\nvar _undefined = require(\"../function/noop\")(); // Support ES3 engines\n\nmodule.exports = function (val) { return val !== _undefined && val !== null; };\n","\"use strict\";\n\nvar isValue = require(\"./is-value\");\n\nvar forEach = Array.prototype.forEach, create = Object.create;\n\nvar process = function (src, obj) {\n\tvar key;\n\tfor (key in src) obj[key] = src[key];\n};\n\n// eslint-disable-next-line no-unused-vars\nmodule.exports = function (opts1 /*, …options*/) {\n\tvar result = create(null);\n\tforEach.call(arguments, function (options) {\n\t\tif (!isValue(options)) return;\n\t\tprocess(Object(options), result);\n\t});\n\treturn result;\n};\n","\"use strict\";\n\nvar sign = require(\"../math/sign\")\n , abs = Math.abs\n , floor = Math.floor;\n\nmodule.exports = function (value) {\n\tif (isNaN(value)) return 0;\n\tvalue = Number(value);\n\tif (value === 0 || !isFinite(value)) return value;\n\treturn sign(value) * floor(abs(value));\n};\n","\"use strict\";\n\nmodule.exports = require(\"./is-implemented\")() ? Math.sign : require(\"./shim\");\n","\"use strict\";\n\nmodule.exports = function (value) {\n\tvalue = Number(value);\n\tif (isNaN(value) || value === 0) return value;\n\treturn value > 0 ? 1 : -1;\n};\n","\"use strict\";\n\nvar toInteger = require(\"./to-integer\")\n , max = Math.max;\n\nmodule.exports = function (value) { return max(0, toInteger(value)); };\n","\"use strict\";\n\nvar toPosInt = require(\"es5-ext/number/to-pos-integer\");\n\nmodule.exports = function (optsLength, fnLength, isAsync) {\n\tvar length;\n\tif (isNaN(optsLength)) {\n\t\tlength = fnLength;\n\t\tif (!(length >= 0)) return 1;\n\t\tif (isAsync && length) return length - 1;\n\t\treturn length;\n\t}\n\tif (optsLength === false) return false;\n\treturn toPosInt(optsLength);\n};\n","\"use strict\";\n\nmodule.exports = function (fn) {\n\tif (typeof fn !== \"function\") throw new TypeError(fn + \" is not a function\");\n\treturn fn;\n};\n","\"use strict\";\n\nvar isValue = require(\"./is-value\");\n\nmodule.exports = function (value) {\n\tif (!isValue(value)) throw new TypeError(\"Cannot use null or undefined\");\n\treturn value;\n};\n","\"use strict\";\n\nmodule.exports = require(\"./_iterate\")(\"forEach\");\n","\"use strict\";\n\nmodule.exports = require(\"./is-implemented\")() ? Object.assign : require(\"./shim\");\n","\"use strict\";\n\nvar keys = require(\"../keys\")\n , value = require(\"../valid-value\")\n , max = Math.max;\n\nmodule.exports = function (dest, src /*, …srcn*/) {\n\tvar error, i, length = max(arguments.length, 2), assign;\n\tdest = Object(value(dest));\n\tassign = function (key) {\n\t\ttry {\n\t\t\tdest[key] = src[key];\n\t\t} catch (e) {\n\t\t\tif (!error) error = e;\n\t\t}\n\t};\n\tfor (i = 1; i < length; ++i) {\n\t\tsrc = arguments[i];\n\t\tkeys(src).forEach(assign);\n\t}\n\tif (error !== undefined) throw error;\n\treturn dest;\n};\n","\"use strict\";\n\nmodule.exports = require(\"./is-implemented\")() ? Object.keys : require(\"./shim\");\n","\"use strict\";\n\nmodule.exports = function () {\n\ttry {\n\t\tObject.keys(\"primitive\");\n\t\treturn true;\n\t} catch (e) {\n\t\treturn false;\n\t}\n};\n","\"use strict\";\n\nvar isValue = require(\"../is-value\");\n\nvar keys = Object.keys;\n\nmodule.exports = function (object) { return keys(isValue(object) ? Object(object) : object); };\n","\"use strict\";\n\nvar isValue = require(\"./is-value\");\n\nvar map = { function: true, object: true };\n\nmodule.exports = function (value) { return (isValue(value) && map[typeof value]) || false; };\n","\"use strict\";\n\nvar assign = require(\"../object/assign\")\n , isObject = require(\"../object/is-object\")\n , isValue = require(\"../object/is-value\")\n , captureStackTrace = Error.captureStackTrace;\n\nmodule.exports = function (message /*, code, ext*/) {\n\tvar err = new Error(message), code = arguments[1], ext = arguments[2];\n\tif (!isValue(ext)) {\n\t\tif (isObject(code)) {\n\t\t\text = code;\n\t\t\tcode = null;\n\t\t}\n\t}\n\tif (isValue(ext)) assign(err, ext);\n\tif (isValue(code)) err.code = code;\n\tif (captureStackTrace) captureStackTrace(err, module.exports);\n\treturn err;\n};\n","\"use strict\";\n\nvar toPosInt = require(\"../number/to-pos-integer\");\n\nvar test = function (arg1, arg2) { return arg2; };\n\nvar desc, defineProperty, generate, mixin;\n\ntry {\n\tObject.defineProperty(test, \"length\", {\n\t\tconfigurable: true,\n\t\twritable: false,\n\t\tenumerable: false,\n\t\tvalue: 1\n\t});\n}\ncatch (ignore) {}\n\nif (test.length === 1) {\n\t// ES6\n\tdesc = { configurable: true, writable: false, enumerable: false };\n\tdefineProperty = Object.defineProperty;\n\tmodule.exports = function (fn, length) {\n\t\tlength = toPosInt(length);\n\t\tif (fn.length === length) return fn;\n\t\tdesc.value = length;\n\t\treturn defineProperty(fn, \"length\", desc);\n\t};\n} else {\n\tmixin = require(\"../object/mixin\");\n\tgenerate = (function () {\n\t\tvar cache = [];\n\t\treturn function (length) {\n\t\t\tvar args, i = 0;\n\t\t\tif (cache[length]) return cache[length];\n\t\t\targs = [];\n\t\t\twhile (length--) args.push(\"a\" + (++i).toString(36));\n\t\t\t// eslint-disable-next-line no-new-func\n\t\t\treturn new Function(\n\t\t\t\t\"fn\",\n\t\t\t\t\"return function (\" + args.join(\", \") + \") { return fn.apply(this, arguments); };\"\n\t\t\t);\n\t\t};\n\t})();\n\tmodule.exports = function (src, length) {\n\t\tvar target;\n\t\tlength = toPosInt(length);\n\t\tif (src.length === length) return src;\n\t\ttarget = generate(length)(src);\n\t\ttry { mixin(target, src); }\n\t\tcatch (ignore) {}\n\t\treturn target;\n\t};\n}\n","\"use strict\";\n\n// ES3 safe\nvar _undefined = void 0;\n\nmodule.exports = function (value) { return value !== _undefined && value !== null; };\n","\"use strict\";\n\nvar isValue = require(\"../value/is\");\n\n// prettier-ignore\nvar possibleTypes = { \"object\": true, \"function\": true, \"undefined\": true /* document.all */ };\n\nmodule.exports = function (value) {\n\tif (!isValue(value)) return false;\n\treturn hasOwnProperty.call(possibleTypes, typeof value);\n};\n","\"use strict\";\n\nvar isPrototype = require(\"../prototype/is\");\n\nmodule.exports = function (value) {\n\tif (typeof value !== \"function\") return false;\n\n\tif (!hasOwnProperty.call(value, \"length\")) return false;\n\n\ttry {\n\t\tif (typeof value.length !== \"number\") return false;\n\t\tif (typeof value.call !== \"function\") return false;\n\t\tif (typeof value.apply !== \"function\") return false;\n\t} catch (error) {\n\t\treturn false;\n\t}\n\n\treturn !isPrototype(value);\n};\n","\"use strict\";\n\nvar isObject = require(\"../object/is\");\n\nmodule.exports = function (value) {\n\tif (!isObject(value)) return false;\n\ttry {\n\t\tif (!value.constructor) return false;\n\t\treturn value.constructor.prototype === value;\n\t} catch (error) {\n\t\treturn false;\n\t}\n};\n","\"use strict\";\n\nvar isFunction = require(\"../function/is\");\n\nvar classRe = /^\\s*class[\\s{/}]/, functionToString = Function.prototype.toString;\n\nmodule.exports = function (value) {\n\tif (!isFunction(value)) return false;\n\tif (classRe.test(functionToString.call(value))) return false;\n\treturn true;\n};\n","\"use strict\";\n\nvar str = \"razdwatrzy\";\n\nmodule.exports = function () {\n\tif (typeof str.contains !== \"function\") return false;\n\treturn str.contains(\"dwa\") === true && str.contains(\"foo\") === false;\n};\n","\"use strict\";\n\nmodule.exports = require(\"./is-implemented\")() ? String.prototype.contains : require(\"./shim\");\n","\"use strict\";\n\nvar indexOf = String.prototype.indexOf;\n\nmodule.exports = function (searchString /*, position*/) {\n\treturn indexOf.call(this, searchString, arguments[1]) > -1;\n};\n","\"use strict\";\n\nvar isValue = require(\"type/value/is\")\n , isPlainFunction = require(\"type/plain-function/is\")\n , assign = require(\"es5-ext/object/assign\")\n , normalizeOpts = require(\"es5-ext/object/normalize-options\")\n , contains = require(\"es5-ext/string/#/contains\");\n\nvar d = (module.exports = function (dscr, value/*, options*/) {\n\tvar c, e, w, options, desc;\n\tif (arguments.length < 2 || typeof dscr !== \"string\") {\n\t\toptions = value;\n\t\tvalue = dscr;\n\t\tdscr = null;\n\t} else {\n\t\toptions = arguments[2];\n\t}\n\tif (isValue(dscr)) {\n\t\tc = contains.call(dscr, \"c\");\n\t\te = contains.call(dscr, \"e\");\n\t\tw = contains.call(dscr, \"w\");\n\t} else {\n\t\tc = w = true;\n\t\te = false;\n\t}\n\n\tdesc = { value: value, configurable: c, enumerable: e, writable: w };\n\treturn !options ? desc : assign(normalizeOpts(options), desc);\n});\n\nd.gs = function (dscr, get, set/*, options*/) {\n\tvar c, e, options, desc;\n\tif (typeof dscr !== \"string\") {\n\t\toptions = set;\n\t\tset = get;\n\t\tget = dscr;\n\t\tdscr = null;\n\t} else {\n\t\toptions = arguments[3];\n\t}\n\tif (!isValue(get)) {\n\t\tget = undefined;\n\t} else if (!isPlainFunction(get)) {\n\t\toptions = get;\n\t\tget = set = undefined;\n\t} else if (!isValue(set)) {\n\t\tset = undefined;\n\t} else if (!isPlainFunction(set)) {\n\t\toptions = set;\n\t\tset = undefined;\n\t}\n\tif (isValue(dscr)) {\n\t\tc = contains.call(dscr, \"c\");\n\t\te = contains.call(dscr, \"e\");\n\t} else {\n\t\tc = true;\n\t\te = false;\n\t}\n\n\tdesc = { get: get, set: set, configurable: c, enumerable: e };\n\treturn !options ? desc : assign(normalizeOpts(options), desc);\n};\n","'use strict';\n\nvar d = require('d')\n , callable = require('es5-ext/object/valid-callable')\n\n , apply = Function.prototype.apply, call = Function.prototype.call\n , create = Object.create, defineProperty = Object.defineProperty\n , defineProperties = Object.defineProperties\n , hasOwnProperty = Object.prototype.hasOwnProperty\n , descriptor = { configurable: true, enumerable: false, writable: true }\n\n , on, once, off, emit, methods, descriptors, base;\n\non = function (type, listener) {\n\tvar data;\n\n\tcallable(listener);\n\n\tif (!hasOwnProperty.call(this, '__ee__')) {\n\t\tdata = descriptor.value = create(null);\n\t\tdefineProperty(this, '__ee__', descriptor);\n\t\tdescriptor.value = null;\n\t} else {\n\t\tdata = this.__ee__;\n\t}\n\tif (!data[type]) data[type] = listener;\n\telse if (typeof data[type] === 'object') data[type].push(listener);\n\telse data[type] = [data[type], listener];\n\n\treturn this;\n};\n\nonce = function (type, listener) {\n\tvar once, self;\n\n\tcallable(listener);\n\tself = this;\n\ton.call(this, type, once = function () {\n\t\toff.call(self, type, once);\n\t\tapply.call(listener, this, arguments);\n\t});\n\n\tonce.__eeOnceListener__ = listener;\n\treturn this;\n};\n\noff = function (type, listener) {\n\tvar data, listeners, candidate, i;\n\n\tcallable(listener);\n\n\tif (!hasOwnProperty.call(this, '__ee__')) return this;\n\tdata = this.__ee__;\n\tif (!data[type]) return this;\n\tlisteners = data[type];\n\n\tif (typeof listeners === 'object') {\n\t\tfor (i = 0; (candidate = listeners[i]); ++i) {\n\t\t\tif ((candidate === listener) ||\n\t\t\t\t\t(candidate.__eeOnceListener__ === listener)) {\n\t\t\t\tif (listeners.length === 2) data[type] = listeners[i ? 0 : 1];\n\t\t\t\telse listeners.splice(i, 1);\n\t\t\t}\n\t\t}\n\t} else {\n\t\tif ((listeners === listener) ||\n\t\t\t\t(listeners.__eeOnceListener__ === listener)) {\n\t\t\tdelete data[type];\n\t\t}\n\t}\n\n\treturn this;\n};\n\nemit = function (type) {\n\tvar i, l, listener, listeners, args;\n\n\tif (!hasOwnProperty.call(this, '__ee__')) return;\n\tlisteners = this.__ee__[type];\n\tif (!listeners) return;\n\n\tif (typeof listeners === 'object') {\n\t\tl = arguments.length;\n\t\targs = new Array(l - 1);\n\t\tfor (i = 1; i < l; ++i) args[i - 1] = arguments[i];\n\n\t\tlisteners = listeners.slice();\n\t\tfor (i = 0; (listener = listeners[i]); ++i) {\n\t\t\tapply.call(listener, this, args);\n\t\t}\n\t} else {\n\t\tswitch (arguments.length) {\n\t\tcase 1:\n\t\t\tcall.call(listeners, this);\n\t\t\tbreak;\n\t\tcase 2:\n\t\t\tcall.call(listeners, this, arguments[1]);\n\t\t\tbreak;\n\t\tcase 3:\n\t\t\tcall.call(listeners, this, arguments[1], arguments[2]);\n\t\t\tbreak;\n\t\tdefault:\n\t\t\tl = arguments.length;\n\t\t\targs = new Array(l - 1);\n\t\t\tfor (i = 1; i < l; ++i) {\n\t\t\t\targs[i - 1] = arguments[i];\n\t\t\t}\n\t\t\tapply.call(listeners, this, args);\n\t\t}\n\t}\n};\n\nmethods = {\n\ton: on,\n\tonce: once,\n\toff: off,\n\temit: emit\n};\n\ndescriptors = {\n\ton: d(on),\n\tonce: d(once),\n\toff: d(off),\n\temit: d(emit)\n};\n\nbase = defineProperties({}, descriptors);\n\nmodule.exports = exports = function (o) {\n\treturn (o == null) ? create(base) : defineProperties(Object(o), descriptors);\n};\nexports.methods = methods;\n","\"use strict\";\n\nvar toArray = require(\"es5-ext/array/to-array\")\n , isValue = require(\"es5-ext/object/is-value\")\n , callable = require(\"es5-ext/object/valid-callable\");\n\nvar slice = Array.prototype.slice, resolveArgs;\n\nresolveArgs = function (args) {\n\treturn this.map(function (resolve, i) { return resolve ? resolve(args[i]) : args[i]; }).concat(\n\t\tslice.call(args, this.length)\n\t);\n};\n\nmodule.exports = function (resolvers) {\n\tresolvers = toArray(resolvers);\n\tresolvers.forEach(function (resolve) { if (isValue(resolve)) callable(resolve); });\n\treturn resolveArgs.bind(resolvers);\n};\n","\"use strict\";\n\nvar from = require(\"./from\")\n , isArray = Array.isArray;\n\nmodule.exports = function (arrayLike) { return isArray(arrayLike) ? arrayLike : from(arrayLike); };\n","\"use strict\";\n\nvar callable = require(\"es5-ext/object/valid-callable\");\n\nmodule.exports = function (userNormalizer) {\n\tvar normalizer;\n\tif (typeof userNormalizer === \"function\") return { set: userNormalizer, get: userNormalizer };\n\tnormalizer = { get: callable(userNormalizer.get) };\n\tif (userNormalizer.set !== undefined) {\n\t\tnormalizer.set = callable(userNormalizer.set);\n\t\tif (userNormalizer.delete) normalizer.delete = callable(userNormalizer.delete);\n\t\tif (userNormalizer.clear) normalizer.clear = callable(userNormalizer.clear);\n\t\treturn normalizer;\n\t}\n\tnormalizer.set = normalizer.get;\n\treturn normalizer;\n};\n","/* eslint no-eq-null: 0, eqeqeq: 0, no-unused-vars: 0 */\n\n\"use strict\";\n\nvar customError = require(\"es5-ext/error/custom\")\n , defineLength = require(\"es5-ext/function/_define-length\")\n , d = require(\"d\")\n , ee = require(\"event-emitter\").methods\n , resolveResolve = require(\"./resolve-resolve\")\n , resolveNormalize = require(\"./resolve-normalize\");\n\nvar apply = Function.prototype.apply\n , call = Function.prototype.call\n , create = Object.create\n , defineProperties = Object.defineProperties\n , on = ee.on\n , emit = ee.emit;\n\nmodule.exports = function (original, length, options) {\n\tvar cache = create(null)\n\t , conf\n\t , memLength\n\t , get\n\t , set\n\t , del\n\t , clear\n\t , extDel\n\t , extGet\n\t , extHas\n\t , normalizer\n\t , getListeners\n\t , setListeners\n\t , deleteListeners\n\t , memoized\n\t , resolve;\n\tif (length !== false) memLength = length;\n\telse if (isNaN(original.length)) memLength = 1;\n\telse memLength = original.length;\n\n\tif (options.normalizer) {\n\t\tnormalizer = resolveNormalize(options.normalizer);\n\t\tget = normalizer.get;\n\t\tset = normalizer.set;\n\t\tdel = normalizer.delete;\n\t\tclear = normalizer.clear;\n\t}\n\tif (options.resolvers != null) resolve = resolveResolve(options.resolvers);\n\n\tif (get) {\n\t\tmemoized = defineLength(function (arg) {\n\t\t\tvar id, result, args = arguments;\n\t\t\tif (resolve) args = resolve(args);\n\t\t\tid = get(args);\n\t\t\tif (id !== null) {\n\t\t\t\tif (hasOwnProperty.call(cache, id)) {\n\t\t\t\t\tif (getListeners) conf.emit(\"get\", id, args, this);\n\t\t\t\t\treturn cache[id];\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (args.length === 1) result = call.call(original, this, args[0]);\n\t\t\telse result = apply.call(original, this, args);\n\t\t\tif (id === null) {\n\t\t\t\tid = get(args);\n\t\t\t\tif (id !== null) throw customError(\"Circular invocation\", \"CIRCULAR_INVOCATION\");\n\t\t\t\tid = set(args);\n\t\t\t} else if (hasOwnProperty.call(cache, id)) {\n\t\t\t\tthrow customError(\"Circular invocation\", \"CIRCULAR_INVOCATION\");\n\t\t\t}\n\t\t\tcache[id] = result;\n\t\t\tif (setListeners) conf.emit(\"set\", id, null, result);\n\t\t\treturn result;\n\t\t}, memLength);\n\t} else if (length === 0) {\n\t\tmemoized = function () {\n\t\t\tvar result;\n\t\t\tif (hasOwnProperty.call(cache, \"data\")) {\n\t\t\t\tif (getListeners) conf.emit(\"get\", \"data\", arguments, this);\n\t\t\t\treturn cache.data;\n\t\t\t}\n\t\t\tif (arguments.length) result = apply.call(original, this, arguments);\n\t\t\telse result = call.call(original, this);\n\t\t\tif (hasOwnProperty.call(cache, \"data\")) {\n\t\t\t\tthrow customError(\"Circular invocation\", \"CIRCULAR_INVOCATION\");\n\t\t\t}\n\t\t\tcache.data = result;\n\t\t\tif (setListeners) conf.emit(\"set\", \"data\", null, result);\n\t\t\treturn result;\n\t\t};\n\t} else {\n\t\tmemoized = function (arg) {\n\t\t\tvar result, args = arguments, id;\n\t\t\tif (resolve) args = resolve(arguments);\n\t\t\tid = String(args[0]);\n\t\t\tif (hasOwnProperty.call(cache, id)) {\n\t\t\t\tif (getListeners) conf.emit(\"get\", id, args, this);\n\t\t\t\treturn cache[id];\n\t\t\t}\n\t\t\tif (args.length === 1) result = call.call(original, this, args[0]);\n\t\t\telse result = apply.call(original, this, args);\n\t\t\tif (hasOwnProperty.call(cache, id)) {\n\t\t\t\tthrow customError(\"Circular invocation\", \"CIRCULAR_INVOCATION\");\n\t\t\t}\n\t\t\tcache[id] = result;\n\t\t\tif (setListeners) conf.emit(\"set\", id, null, result);\n\t\t\treturn result;\n\t\t};\n\t}\n\tconf = {\n\t\toriginal: original,\n\t\tmemoized: memoized,\n\t\tprofileName: options.profileName,\n\t\tget: function (args) {\n\t\t\tif (resolve) args = resolve(args);\n\t\t\tif (get) return get(args);\n\t\t\treturn String(args[0]);\n\t\t},\n\t\thas: function (id) { return hasOwnProperty.call(cache, id); },\n\t\tdelete: function (id) {\n\t\t\tvar result;\n\t\t\tif (!hasOwnProperty.call(cache, id)) return;\n\t\t\tif (del) del(id);\n\t\t\tresult = cache[id];\n\t\t\tdelete cache[id];\n\t\t\tif (deleteListeners) conf.emit(\"delete\", id, result);\n\t\t},\n\t\tclear: function () {\n\t\t\tvar oldCache = cache;\n\t\t\tif (clear) clear();\n\t\t\tcache = create(null);\n\t\t\tconf.emit(\"clear\", oldCache);\n\t\t},\n\t\ton: function (type, listener) {\n\t\t\tif (type === \"get\") getListeners = true;\n\t\t\telse if (type === \"set\") setListeners = true;\n\t\t\telse if (type === \"delete\") deleteListeners = true;\n\t\t\treturn on.call(this, type, listener);\n\t\t},\n\t\temit: emit,\n\t\tupdateEnv: function () { original = conf.original; },\n\t};\n\tif (get) {\n\t\textDel = defineLength(function (arg) {\n\t\t\tvar id, args = arguments;\n\t\t\tif (resolve) args = resolve(args);\n\t\t\tid = get(args);\n\t\t\tif (id === null) return;\n\t\t\tconf.delete(id);\n\t\t}, memLength);\n\t} else if (length === 0) {\n\t\textDel = function () { return conf.delete(\"data\"); };\n\t} else {\n\t\textDel = function (arg) {\n\t\t\tif (resolve) arg = resolve(arguments)[0];\n\t\t\treturn conf.delete(arg);\n\t\t};\n\t}\n\textGet = defineLength(function () {\n\t\tvar id, args = arguments;\n\t\tif (length === 0) return cache.data;\n\t\tif (resolve) args = resolve(args);\n\t\tif (get) id = get(args);\n\t\telse id = String(args[0]);\n\t\treturn cache[id];\n\t});\n\textHas = defineLength(function () {\n\t\tvar id, args = arguments;\n\t\tif (length === 0) return conf.has(\"data\");\n\t\tif (resolve) args = resolve(args);\n\t\tif (get) id = get(args);\n\t\telse id = String(args[0]);\n\t\tif (id === null) return false;\n\t\treturn conf.has(id);\n\t});\n\tdefineProperties(memoized, {\n\t\t__memoized__: d(true),\n\t\tdelete: d(extDel),\n\t\tclear: d(conf.clear),\n\t\t_get: d(extGet),\n\t\t_has: d(extHas),\n\t});\n\treturn conf;\n};\n","\"use strict\";\n\nvar callable = require(\"es5-ext/object/valid-callable\")\n , forEach = require(\"es5-ext/object/for-each\")\n , extensions = require(\"./lib/registered-extensions\")\n , configure = require(\"./lib/configure-map\")\n , resolveLength = require(\"./lib/resolve-length\");\n\nmodule.exports = function self(fn/*, options */) {\n\tvar options, length, conf;\n\n\tcallable(fn);\n\toptions = Object(arguments[1]);\n\n\tif (options.async && options.promise) {\n\t\tthrow new Error(\"Options 'async' and 'promise' cannot be used together\");\n\t}\n\n\t// Do not memoize already memoized function\n\tif (hasOwnProperty.call(fn, \"__memoized__\") && !options.force) return fn;\n\n\t// Resolve length;\n\tlength = resolveLength(options.length, fn.length, options.async && extensions.async);\n\n\t// Configure cache map\n\tconf = configure(fn, length, options);\n\n\t// Bind eventual extensions\n\tforEach(extensions, function (extFn, name) {\n\t\tif (options[name]) extFn(options[name], conf, options);\n\t});\n\n\tif (self.__profiler__) self.__profiler__(conf);\n\n\tconf.updateEnv();\n\treturn conf.memoized;\n};\n","\"use strict\";\n\nvar normalizeOpts = require(\"es5-ext/object/normalize-options\")\n , resolveLength = require(\"./lib/resolve-length\")\n , plain = require(\"./plain\");\n\nmodule.exports = function (fn/*, options*/) {\n\tvar options = normalizeOpts(arguments[1]), length;\n\n\tif (!options.normalizer) {\n\t\tlength = options.length = resolveLength(options.length, fn.length, options.async);\n\t\tif (length !== 0) {\n\t\t\tif (options.primitive) {\n\t\t\t\tif (length === false) {\n\t\t\t\t\toptions.normalizer = require(\"./normalizers/primitive\");\n\t\t\t\t} else if (length > 1) {\n\t\t\t\t\toptions.normalizer = require(\"./normalizers/get-primitive-fixed\")(length);\n\t\t\t\t}\n\t\t\t} else if (length === false) options.normalizer = require(\"./normalizers/get\")();\n\t\t\telse if (length === 1) options.normalizer = require(\"./normalizers/get-1\")();\n\t\t\telse options.normalizer = require(\"./normalizers/get-fixed\")(length);\n\t\t}\n\t}\n\n\t// Assure extensions\n\tif (options.async) require(\"./ext/async\");\n\tif (options.promise) require(\"./ext/promise\");\n\tif (options.dispose) require(\"./ext/dispose\");\n\tif (options.maxAge) require(\"./ext/max-age\");\n\tif (options.max) require(\"./ext/max\");\n\tif (options.refCounter) require(\"./ext/ref-counter\");\n\n\treturn plain(fn, options);\n};\n","\"use strict\";\n\nmodule.exports = function (args) {\n\tvar id, i, length = args.length;\n\tif (!length) return \"\\u0002\";\n\tid = String(args[(i = 0)]);\n\twhile (--length) id += \"\\u0001\" + args[++i];\n\treturn id;\n};\n","\"use strict\";\n\nmodule.exports = function (length) {\n\tif (!length) {\n\t\treturn function () { return \"\"; };\n\t}\n\treturn function (args) {\n\t\tvar id = String(args[0]), i = 0, currentLength = length;\n\t\twhile (--currentLength) {\n\t\t\tid += \"\\u0001\" + args[++i];\n\t\t}\n\t\treturn id;\n\t};\n};\n","/* eslint max-statements: 0 */\n\n\"use strict\";\n\nvar indexOf = require(\"es5-ext/array/#/e-index-of\");\n\nvar create = Object.create;\n\nmodule.exports = function () {\n\tvar lastId = 0, map = [], cache = create(null);\n\treturn {\n\t\tget: function (args) {\n\t\t\tvar index = 0, set = map, i, length = args.length;\n\t\t\tif (length === 0) return set[length] || null;\n\t\t\tif ((set = set[length])) {\n\t\t\t\twhile (index < length - 1) {\n\t\t\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\t\t\tif (i === -1) return null;\n\t\t\t\t\tset = set[1][i];\n\t\t\t\t\t++index;\n\t\t\t\t}\n\t\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\t\tif (i === -1) return null;\n\t\t\t\treturn set[1][i] || null;\n\t\t\t}\n\t\t\treturn null;\n\t\t},\n\t\tset: function (args) {\n\t\t\tvar index = 0, set = map, i, length = args.length;\n\t\t\tif (length === 0) {\n\t\t\t\tset[length] = ++lastId;\n\t\t\t} else {\n\t\t\t\tif (!set[length]) {\n\t\t\t\t\tset[length] = [[], []];\n\t\t\t\t}\n\t\t\t\tset = set[length];\n\t\t\t\twhile (index < length - 1) {\n\t\t\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\t\t\tif (i === -1) {\n\t\t\t\t\t\ti = set[0].push(args[index]) - 1;\n\t\t\t\t\t\tset[1].push([[], []]);\n\t\t\t\t\t}\n\t\t\t\t\tset = set[1][i];\n\t\t\t\t\t++index;\n\t\t\t\t}\n\t\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\t\tif (i === -1) {\n\t\t\t\t\ti = set[0].push(args[index]) - 1;\n\t\t\t\t}\n\t\t\t\tset[1][i] = ++lastId;\n\t\t\t}\n\t\t\tcache[lastId] = args;\n\t\t\treturn lastId;\n\t\t},\n\t\tdelete: function (id) {\n\t\t\tvar index = 0, set = map, i, args = cache[id], length = args.length, path = [];\n\t\t\tif (length === 0) {\n\t\t\t\tdelete set[length];\n\t\t\t} else if ((set = set[length])) {\n\t\t\t\twhile (index < length - 1) {\n\t\t\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\t\t\tif (i === -1) {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\tpath.push(set, i);\n\t\t\t\t\tset = set[1][i];\n\t\t\t\t\t++index;\n\t\t\t\t}\n\t\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\t\tif (i === -1) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tid = set[1][i];\n\t\t\t\tset[0].splice(i, 1);\n\t\t\t\tset[1].splice(i, 1);\n\t\t\t\twhile (!set[0].length && path.length) {\n\t\t\t\t\ti = path.pop();\n\t\t\t\t\tset = path.pop();\n\t\t\t\t\tset[0].splice(i, 1);\n\t\t\t\t\tset[1].splice(i, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\tdelete cache[id];\n\t\t},\n\t\tclear: function () {\n\t\t\tmap = [];\n\t\t\tcache = create(null);\n\t\t},\n\t};\n};\n","\"use strict\";\n\nvar indexOf = require(\"es5-ext/array/#/e-index-of\");\n\nmodule.exports = function () {\n\tvar lastId = 0, argsMap = [], cache = [];\n\treturn {\n\t\tget: function (args) {\n\t\t\tvar index = indexOf.call(argsMap, args[0]);\n\t\t\treturn index === -1 ? null : cache[index];\n\t\t},\n\t\tset: function (args) {\n\t\t\targsMap.push(args[0]);\n\t\t\tcache.push(++lastId);\n\t\t\treturn lastId;\n\t\t},\n\t\tdelete: function (id) {\n\t\t\tvar index = indexOf.call(cache, id);\n\t\t\tif (index !== -1) {\n\t\t\t\targsMap.splice(index, 1);\n\t\t\t\tcache.splice(index, 1);\n\t\t\t}\n\t\t},\n\t\tclear: function () {\n\t\t\targsMap = [];\n\t\t\tcache = [];\n\t\t},\n\t};\n};\n","\"use strict\";\n\nvar indexOf = require(\"es5-ext/array/#/e-index-of\")\n , create = Object.create;\n\nmodule.exports = function (length) {\n\tvar lastId = 0, map = [[], []], cache = create(null);\n\treturn {\n\t\tget: function (args) {\n\t\t\tvar index = 0, set = map, i;\n\t\t\twhile (index < length - 1) {\n\t\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\t\tif (i === -1) return null;\n\t\t\t\tset = set[1][i];\n\t\t\t\t++index;\n\t\t\t}\n\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\tif (i === -1) return null;\n\t\t\treturn set[1][i] || null;\n\t\t},\n\t\tset: function (args) {\n\t\t\tvar index = 0, set = map, i;\n\t\t\twhile (index < length - 1) {\n\t\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\t\tif (i === -1) {\n\t\t\t\t\ti = set[0].push(args[index]) - 1;\n\t\t\t\t\tset[1].push([[], []]);\n\t\t\t\t}\n\t\t\t\tset = set[1][i];\n\t\t\t\t++index;\n\t\t\t}\n\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\tif (i === -1) {\n\t\t\t\ti = set[0].push(args[index]) - 1;\n\t\t\t}\n\t\t\tset[1][i] = ++lastId;\n\t\t\tcache[lastId] = args;\n\t\t\treturn lastId;\n\t\t},\n\t\tdelete: function (id) {\n\t\t\tvar index = 0, set = map, i, path = [], args = cache[id];\n\t\t\twhile (index < length - 1) {\n\t\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\t\tif (i === -1) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tpath.push(set, i);\n\t\t\t\tset = set[1][i];\n\t\t\t\t++index;\n\t\t\t}\n\t\t\ti = indexOf.call(set[0], args[index]);\n\t\t\tif (i === -1) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tid = set[1][i];\n\t\t\tset[0].splice(i, 1);\n\t\t\tset[1].splice(i, 1);\n\t\t\twhile (!set[0].length && path.length) {\n\t\t\t\ti = path.pop();\n\t\t\t\tset = path.pop();\n\t\t\t\tset[0].splice(i, 1);\n\t\t\t\tset[1].splice(i, 1);\n\t\t\t}\n\t\t\tdelete cache[id];\n\t\t},\n\t\tclear: function () {\n\t\t\tmap = [[], []];\n\t\t\tcache = create(null);\n\t\t},\n\t};\n};\n","/* eslint consistent-this: 0, no-shadow:0, no-eq-null: 0, eqeqeq: 0, no-unused-vars: 0 */\n\n// Support for asynchronous functions\n\n\"use strict\";\n\nvar aFrom = require(\"es5-ext/array/from\")\n , objectMap = require(\"es5-ext/object/map\")\n , mixin = require(\"es5-ext/object/mixin\")\n , defineLength = require(\"es5-ext/function/_define-length\")\n , nextTick = require(\"next-tick\");\n\nvar slice = Array.prototype.slice, apply = Function.prototype.apply, create = Object.create;\n\nrequire(\"../lib/registered-extensions\").async = function (tbi, conf) {\n\tvar waiting = create(null)\n\t , cache = create(null)\n\t , base = conf.memoized\n\t , original = conf.original\n\t , currentCallback\n\t , currentContext\n\t , currentArgs;\n\n\t// Initial\n\tconf.memoized = defineLength(function (arg) {\n\t\tvar args = arguments, last = args[args.length - 1];\n\t\tif (typeof last === \"function\") {\n\t\t\tcurrentCallback = last;\n\t\t\targs = slice.call(args, 0, -1);\n\t\t}\n\t\treturn base.apply((currentContext = this), (currentArgs = args));\n\t}, base);\n\ttry { mixin(conf.memoized, base); }\n\tcatch (ignore) {}\n\n\t// From cache (sync)\n\tconf.on(\"get\", function (id) {\n\t\tvar cb, context, args;\n\t\tif (!currentCallback) return;\n\n\t\t// Unresolved\n\t\tif (waiting[id]) {\n\t\t\tif (typeof waiting[id] === \"function\") waiting[id] = [waiting[id], currentCallback];\n\t\t\telse waiting[id].push(currentCallback);\n\t\t\tcurrentCallback = null;\n\t\t\treturn;\n\t\t}\n\n\t\t// Resolved, assure next tick invocation\n\t\tcb = currentCallback;\n\t\tcontext = currentContext;\n\t\targs = currentArgs;\n\t\tcurrentCallback = currentContext = currentArgs = null;\n\t\tnextTick(function () {\n\t\t\tvar data;\n\t\t\tif (hasOwnProperty.call(cache, id)) {\n\t\t\t\tdata = cache[id];\n\t\t\t\tconf.emit(\"getasync\", id, args, context);\n\t\t\t\tapply.call(cb, data.context, data.args);\n\t\t\t} else {\n\t\t\t\t// Purged in a meantime, we shouldn't rely on cached value, recall\n\t\t\t\tcurrentCallback = cb;\n\t\t\t\tcurrentContext = context;\n\t\t\t\tcurrentArgs = args;\n\t\t\t\tbase.apply(context, args);\n\t\t\t}\n\t\t});\n\t});\n\n\t// Not from cache\n\tconf.original = function () {\n\t\tvar args, cb, origCb, result;\n\t\tif (!currentCallback) return apply.call(original, this, arguments);\n\t\targs = aFrom(arguments);\n\t\tcb = function self(err) {\n\t\t\tvar cb, args, id = self.id;\n\t\t\tif (id == null) {\n\t\t\t\t// Shouldn't happen, means async callback was called sync way\n\t\t\t\tnextTick(apply.bind(self, this, arguments));\n\t\t\t\treturn undefined;\n\t\t\t}\n\t\t\tdelete self.id;\n\t\t\tcb = waiting[id];\n\t\t\tdelete waiting[id];\n\t\t\tif (!cb) {\n\t\t\t\t// Already processed,\n\t\t\t\t// outcome of race condition: asyncFn(1, cb), asyncFn.clear(), asyncFn(1, cb)\n\t\t\t\treturn undefined;\n\t\t\t}\n\t\t\targs = aFrom(arguments);\n\t\t\tif (conf.has(id)) {\n\t\t\t\tif (err) {\n\t\t\t\t\tconf.delete(id);\n\t\t\t\t} else {\n\t\t\t\t\tcache[id] = { context: this, args: args };\n\t\t\t\t\tconf.emit(\"setasync\", id, typeof cb === \"function\" ? 1 : cb.length);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (typeof cb === \"function\") {\n\t\t\t\tresult = apply.call(cb, this, args);\n\t\t\t} else {\n\t\t\t\tcb.forEach(function (cb) { result = apply.call(cb, this, args); }, this);\n\t\t\t}\n\t\t\treturn result;\n\t\t};\n\t\torigCb = currentCallback;\n\t\tcurrentCallback = currentContext = currentArgs = null;\n\t\targs.push(cb);\n\t\tresult = apply.call(original, this, args);\n\t\tcb.cb = origCb;\n\t\tcurrentCallback = cb;\n\t\treturn result;\n\t};\n\n\t// After not from cache call\n\tconf.on(\"set\", function (id) {\n\t\tif (!currentCallback) {\n\t\t\tconf.delete(id);\n\t\t\treturn;\n\t\t}\n\t\tif (waiting[id]) {\n\t\t\t// Race condition: asyncFn(1, cb), asyncFn.clear(), asyncFn(1, cb)\n\t\t\tif (typeof waiting[id] === \"function\") waiting[id] = [waiting[id], currentCallback.cb];\n\t\t\telse waiting[id].push(currentCallback.cb);\n\t\t} else {\n\t\t\twaiting[id] = currentCallback.cb;\n\t\t}\n\t\tdelete currentCallback.cb;\n\t\tcurrentCallback.id = id;\n\t\tcurrentCallback = null;\n\t});\n\n\t// On delete\n\tconf.on(\"delete\", function (id) {\n\t\tvar result;\n\t\t// If false, we don't have value yet, so we assume that intention is not\n\t\t// to memoize this call. After value is obtained we don't cache it but\n\t\t// gracefully pass to callback\n\t\tif (hasOwnProperty.call(waiting, id)) return;\n\t\tif (!cache[id]) return;\n\t\tresult = cache[id];\n\t\tdelete cache[id];\n\t\tconf.emit(\"deleteasync\", id, slice.call(result.args, 1));\n\t});\n\n\t// On clear\n\tconf.on(\"clear\", function () {\n\t\tvar oldCache = cache;\n\t\tcache = create(null);\n\t\tconf.emit(\n\t\t\t\"clearasync\", objectMap(oldCache, function (data) { return slice.call(data.args, 1); })\n\t\t);\n\t});\n};\n","// Call dispose callback on each cache purge\n\n\"use strict\";\n\nvar callable = require(\"es5-ext/object/valid-callable\")\n , forEach = require(\"es5-ext/object/for-each\")\n , extensions = require(\"../lib/registered-extensions\")\n , apply = Function.prototype.apply;\n\nextensions.dispose = function (dispose, conf, options) {\n\tvar del;\n\tcallable(dispose);\n\tif ((options.async && extensions.async) || (options.promise && extensions.promise)) {\n\t\tconf.on(\n\t\t\t\"deleteasync\",\n\t\t\t(del = function (id, resultArray) { apply.call(dispose, null, resultArray); })\n\t\t);\n\t\tconf.on(\"clearasync\", function (cache) {\n\t\t\tforEach(cache, function (result, id) { del(id, result); });\n\t\t});\n\t\treturn;\n\t}\n\tconf.on(\"delete\", (del = function (id, result) { dispose(result); }));\n\tconf.on(\"clear\", function (cache) {\n\t\tforEach(cache, function (result, id) { del(id, result); });\n\t});\n};\n","/* eslint consistent-this: 0 */\n\n// Timeout cached values\n\n\"use strict\";\n\nvar aFrom = require(\"es5-ext/array/from\")\n , forEach = require(\"es5-ext/object/for-each\")\n , nextTick = require(\"next-tick\")\n , isPromise = require(\"is-promise\")\n , timeout = require(\"timers-ext/valid-timeout\")\n , extensions = require(\"../lib/registered-extensions\");\n\nvar noop = Function.prototype, max = Math.max, min = Math.min, create = Object.create;\n\nextensions.maxAge = function (maxAge, conf, options) {\n\tvar timeouts, postfix, preFetchAge, preFetchTimeouts;\n\n\tmaxAge = timeout(maxAge);\n\tif (!maxAge) return;\n\n\ttimeouts = create(null);\n\tpostfix =\n\t\t(options.async && extensions.async) || (options.promise && extensions.promise)\n\t\t\t? \"async\"\n\t\t\t: \"\";\n\tconf.on(\"set\" + postfix, function (id) {\n\t\ttimeouts[id] = setTimeout(function () { conf.delete(id); }, maxAge);\n\t\tif (typeof timeouts[id].unref === \"function\") timeouts[id].unref();\n\t\tif (!preFetchTimeouts) return;\n\t\tif (preFetchTimeouts[id]) {\n\t\t\tif (preFetchTimeouts[id] !== \"nextTick\") clearTimeout(preFetchTimeouts[id]);\n\t\t}\n\t\tpreFetchTimeouts[id] = setTimeout(function () {\n\t\t\tdelete preFetchTimeouts[id];\n\t\t}, preFetchAge);\n\t\tif (typeof preFetchTimeouts[id].unref === \"function\") preFetchTimeouts[id].unref();\n\t});\n\tconf.on(\"delete\" + postfix, function (id) {\n\t\tclearTimeout(timeouts[id]);\n\t\tdelete timeouts[id];\n\t\tif (!preFetchTimeouts) return;\n\t\tif (preFetchTimeouts[id] !== \"nextTick\") clearTimeout(preFetchTimeouts[id]);\n\t\tdelete preFetchTimeouts[id];\n\t});\n\n\tif (options.preFetch) {\n\t\tif (options.preFetch === true || isNaN(options.preFetch)) {\n\t\t\tpreFetchAge = 0.333;\n\t\t} else {\n\t\t\tpreFetchAge = max(min(Number(options.preFetch), 1), 0);\n\t\t}\n\t\tif (preFetchAge) {\n\t\t\tpreFetchTimeouts = {};\n\t\t\tpreFetchAge = (1 - preFetchAge) * maxAge;\n\t\t\tconf.on(\"get\" + postfix, function (id, args, context) {\n\t\t\t\tif (!preFetchTimeouts[id]) {\n\t\t\t\t\tpreFetchTimeouts[id] = \"nextTick\";\n\t\t\t\t\tnextTick(function () {\n\t\t\t\t\t\tvar result;\n\t\t\t\t\t\tif (preFetchTimeouts[id] !== \"nextTick\") return;\n\t\t\t\t\t\tdelete preFetchTimeouts[id];\n\t\t\t\t\t\tconf.delete(id);\n\t\t\t\t\t\tif (options.async) {\n\t\t\t\t\t\t\targs = aFrom(args);\n\t\t\t\t\t\t\targs.push(noop);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tresult = conf.memoized.apply(context, args);\n\t\t\t\t\t\tif (options.promise) {\n\t\t\t\t\t\t\t// Supress eventual error warnings\n\t\t\t\t\t\t\tif (isPromise(result)) {\n\t\t\t\t\t\t\t\tif (typeof result.done === \"function\") result.done(noop, noop);\n\t\t\t\t\t\t\t\telse result.then(noop, noop);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t}\n\n\tconf.on(\"clear\" + postfix, function () {\n\t\tforEach(timeouts, function (id) { clearTimeout(id); });\n\t\ttimeouts = {};\n\t\tif (preFetchTimeouts) {\n\t\t\tforEach(preFetchTimeouts, function (id) { if (id !== \"nextTick\") clearTimeout(id); });\n\t\t\tpreFetchTimeouts = {};\n\t\t}\n\t});\n};\n","\"use strict\";\n\nvar toPosInt = require(\"es5-ext/number/to-pos-integer\")\n , maxTimeout = require(\"./max-timeout\");\n\nmodule.exports = function (value) {\n\tvalue = toPosInt(value);\n\tif (value > maxTimeout) throw new TypeError(value + \" exceeds maximum possible timeout\");\n\treturn value;\n};\n","\"use strict\";\n\nmodule.exports = 2147483647;\n","// Limit cache size, LRU (least recently used) algorithm.\n\n\"use strict\";\n\nvar toPosInteger = require(\"es5-ext/number/to-pos-integer\")\n , lruQueue = require(\"lru-queue\")\n , extensions = require(\"../lib/registered-extensions\");\n\nextensions.max = function (max, conf, options) {\n\tvar postfix, queue, hit;\n\n\tmax = toPosInteger(max);\n\tif (!max) return;\n\n\tqueue = lruQueue(max);\n\tpostfix =\n\t\t(options.async && extensions.async) || (options.promise && extensions.promise)\n\t\t\t? \"async\"\n\t\t\t: \"\";\n\n\tconf.on(\n\t\t\"set\" + postfix,\n\t\t(hit = function (id) {\n\t\t\tid = queue.hit(id);\n\t\t\tif (id === undefined) return;\n\t\t\tconf.delete(id);\n\t\t})\n\t);\n\tconf.on(\"get\" + postfix, hit);\n\tconf.on(\"delete\" + postfix, queue.delete);\n\tconf.on(\"clear\" + postfix, queue.clear);\n};\n","'use strict';\n\nvar toPosInt = require('es5-ext/number/to-pos-integer')\n\n , create = Object.create, hasOwnProperty = Object.prototype.hasOwnProperty;\n\nmodule.exports = function (limit) {\n\tvar size = 0, base = 1, queue = create(null), map = create(null), index = 0, del;\n\tlimit = toPosInt(limit);\n\treturn {\n\t\thit: function (id) {\n\t\t\tvar oldIndex = map[id], nuIndex = ++index;\n\t\t\tqueue[nuIndex] = id;\n\t\t\tmap[id] = nuIndex;\n\t\t\tif (!oldIndex) {\n\t\t\t\t++size;\n\t\t\t\tif (size <= limit) return;\n\t\t\t\tid = queue[base];\n\t\t\t\tdel(id);\n\t\t\t\treturn id;\n\t\t\t}\n\t\t\tdelete queue[oldIndex];\n\t\t\tif (base !== oldIndex) return;\n\t\t\twhile (!hasOwnProperty.call(queue, ++base)) continue; //jslint: skip\n\t\t},\n\t\tdelete: del = function (id) {\n\t\t\tvar oldIndex = map[id];\n\t\t\tif (!oldIndex) return;\n\t\t\tdelete queue[oldIndex];\n\t\t\tdelete map[id];\n\t\t\t--size;\n\t\t\tif (base !== oldIndex) return;\n\t\t\tif (!size) {\n\t\t\t\tindex = 0;\n\t\t\t\tbase = 1;\n\t\t\t\treturn;\n\t\t\t}\n\t\t\twhile (!hasOwnProperty.call(queue, ++base)) continue; //jslint: skip\n\t\t},\n\t\tclear: function () {\n\t\t\tsize = 0;\n\t\t\tbase = 1;\n\t\t\tqueue = create(null);\n\t\t\tmap = create(null);\n\t\t\tindex = 0;\n\t\t}\n\t};\n};\n","// Reference counter, useful for garbage collector like functionality\n\n\"use strict\";\n\nvar d = require(\"d\")\n , extensions = require(\"../lib/registered-extensions\")\n , create = Object.create\n , defineProperties = Object.defineProperties;\n\nextensions.refCounter = function (ignore, conf, options) {\n\tvar cache, postfix;\n\n\tcache = create(null);\n\tpostfix =\n\t\t(options.async && extensions.async) || (options.promise && extensions.promise)\n\t\t\t? \"async\"\n\t\t\t: \"\";\n\n\tconf.on(\"set\" + postfix, function (id, length) { cache[id] = length || 1; });\n\tconf.on(\"get\" + postfix, function (id) { ++cache[id]; });\n\tconf.on(\"delete\" + postfix, function (id) { delete cache[id]; });\n\tconf.on(\"clear\" + postfix, function () { cache = {}; });\n\n\tdefineProperties(conf.memoized, {\n\t\tdeleteRef: d(function () {\n\t\t\tvar id = conf.get(arguments);\n\t\t\tif (id === null) return null;\n\t\t\tif (!cache[id]) return null;\n\t\t\tif (!--cache[id]) {\n\t\t\t\tconf.delete(id);\n\t\t\t\treturn true;\n\t\t\t}\n\t\t\treturn false;\n\t\t}),\n\t\tgetRefCount: d(function () {\n\t\t\tvar id = conf.get(arguments);\n\t\t\tif (id === null) return 0;\n\t\t\tif (!cache[id]) return 0;\n\t\t\treturn cache[id];\n\t\t}),\n\t});\n};\n","const os = require(\"os\");\r\n\r\n// to detect on with os user had used path.resolve(...)\r\nconst is_posix_os = (os.platform() !== \"win32\");\r\nconst version = os.release();\r\n\r\n// For some windows version (Windows 10 v1803), it is not useful to escape spaces in path\r\n// https://docs.microsoft.com/en-us/windows/release-information/\r\nconst windows_version_regex = /(\\d+\\.\\d+)\\.(\\d+)/;\r\nconst should_not_escape = (major_release = \"\", os_build = \"\") =>\r\n /1\\d+\\.\\d+/.test(major_release) && Number(os_build) >= 17134.1184;\r\n\r\nmodule.exports = function (given_path) {\r\n return (is_posix_os)\r\n // for posix path, escape is simple\r\n ? given_path.replace(/(\\s+)/g, '\\\\$1')\r\n // for windows, it depend of the build\r\n : (should_not_escape(...windows_version_regex.exec(version).splice(1)))\r\n // on major version, no need to escape anymore\r\n // https://support.microsoft.com/en-us/help/4467268/url-encoded-unc-paths-not-url-decoded-in-windows-10-version-1803-later\r\n ? given_path\r\n // on older version, replace space with symbol %20\r\n : given_path.replace(/(\\s+)/g, '%20');\r\n};","// Generated by CoffeeScript 1.10.0\n(function() {\n var regexEscape, reverse;\n\n regexEscape = require('escape-string-regexp');\n\n reverse = function(s) {\n return s.split('').reverse().join('');\n };\n\n module.exports = function(s, chars, escapeChar) {\n var regex;\n if (chars == null) {\n chars = '\\'';\n }\n if (escapeChar == null) {\n escapeChar = '\\\\';\n }\n if (typeof s !== 'string') {\n return s;\n }\n regex = new RegExp(\"([\" + (regexEscape(chars)) + \"])(?!\" + (regexEscape(escapeChar)) + \")\", 'g');\n return reverse(reverse(s).replace(regex, \"$1\" + escapeChar));\n };\n\n}).call(this);\n","'use strict';\n\nvar matchOperatorsRe = /[|\\\\{}()[\\]^$+*?.]/g;\n\nmodule.exports = function (str) {\n\tif (typeof str !== 'string') {\n\t\tthrow new TypeError('Expected a string');\n\t}\n\n\treturn str.replace(matchOperatorsRe, '\\\\$&');\n};\n","(function () {\n\n 'use strict';\n\n var root = this;\n\n\n //=========//\n // GLOBALS //\n //=========//\n\n var locales = {};\n\n\n //==========//\n // EXPOSING //\n //==========//\n\n var moduleDefinition = {\n create: factory,\n addLocale: addLocale,\n pluralize: pluralize\n };\n\n if ('undefined' !== typeof module && 'undefined' !== typeof module.exports) {\n module.exports = moduleDefinition;\n } else {\n root.numerous = moduleDefinition;\n }\n\n\n //==================//\n // PUBLIC FUNCTIONS //\n //==================//\n\n /**\n * Creates new instance of numerous.\n *\n * @param {string} locale\n * @returns {object}\n */\n function factory (locale) {\n\n checkLocale(locale);\n\n return {\n pluralize: function (value, variants) {\n return pluralize(locale, value, variants);\n }\n };\n }\n\n /**\n * Adds pluralization function for specified locale.\n * Usually externally called by locale itself.\n *\n * @param {string} locale\n * @param {function} callable\n */\n function addLocale (locale, callable) {\n locales[locale] = callable;\n }\n\n /**\n * Returns variant from the specified list of variants\n * according to the specified value and locale.\n *\n * @param {string} locale\n * @param {int} value\n * @param {object} variants\n */\n function pluralize (locale, value, variants) {\n\n checkLocale(locale);\n\n if ('object' !== typeof variants) {\n throw new Error('List of variants should be specified as an object');\n }\n\n var key = locales[locale](value);\n\n return ('undefined' !== typeof variants[key] ? variants[key] : null);\n }\n\n\n //===================//\n // PRIVATE FUNCTIONS //\n //===================//\n\n /**\n * Returns true if specified locale is loaded, false otherwise.\n *\n * @param {string} locale\n *\n * @returns {boolean}\n */\n function hasLocale (locale) {\n return ('undefined' !== typeof locales[locale]);\n }\n\n /**\n * Checks if locale is loaded. If not, tries to load it.\n *\n * @param {string} locale\n */\n function checkLocale (locale) {\n if (!hasLocale(locale)) {\n requireLocale(locale);\n }\n }\n\n /**\n * Tries to load the specified locale.\n *\n * @param {string} locale\n */\n function requireLocale (locale) {\n try {\n require(__dirname + '/../locales/' + locale + '.js');\n } catch (error) {\n throw Error('Failed to load the following locale: ' + locale);\n }\n }\n\n}).call(this);\n","module.exports = require('./lib/numerous.js');\n","(function () {\n var root = this;\n var numerous;\n if ('function' === typeof require) {\n numerous = require('../lib/numerous.js');\n } else {\n numerous = root.numerous;\n }\n numerous.addLocale('en', function pluralize_en(n /*``*/ ) {\n var i = Math.floor(Math.abs(n)),\n v = n.toString().replace(/^[^.]*\\.?/, \"\").length;\n if (typeof n === \"string\") n = parseInt(n, 10);\n if (i === 1 && v === 0) return \"one\";\n return \"other\"\n });\n}).call(this);","// Coding standard for this project defined @ https://github.com/MatthewSH/standards/blob/master/JavaScript.md\n'use strict';\n\nexports = module.exports = !!(typeof process !== 'undefined' && process.versions && process.versions.node);\n","module.exports = {\n \"id\": \"en\",\n \"data\": {\n \"long\": {\n \"years\": {\n \"one\": \"{0} year\",\n \"other\": \"{0} years\"\n },\n \"months\": {\n \"one\": \"{0} month\",\n \"other\": \"{0} months\"\n },\n \"weeks\": {\n \"one\": \"{0} week\",\n \"other\": \"{0} weeks\"\n },\n \"days\": {\n \"one\": \"{0} day\",\n \"other\": \"{0} days\"\n },\n \"hours\": {\n \"one\": \"{0} hour\",\n \"other\": \"{0} hours\"\n },\n \"minutes\": {\n \"one\": \"{0} minute\",\n \"other\": \"{0} minutes\"\n },\n \"seconds\": {\n \"one\": \"{0} second\",\n \"other\": \"{0} seconds\"\n }\n },\n \"narrow\": {\n \"years\": {\n \"one\": \"{0}y\",\n \"other\": \"{0}y\"\n },\n \"months\": {\n \"one\": \"{0}m\",\n \"other\": \"{0}m\"\n },\n \"weeks\": {\n \"one\": \"{0}w\",\n \"other\": \"{0}w\"\n },\n \"days\": {\n \"one\": \"{0}d\",\n \"other\": \"{0}d\"\n },\n \"hours\": {\n \"one\": \"{0}h\",\n \"other\": \"{0}h\"\n },\n \"minutes\": {\n \"one\": \"{0}m\",\n \"other\": \"{0}m\"\n },\n \"seconds\": {\n \"one\": \"{0}s\",\n \"other\": \"{0}s\"\n }\n },\n \"short\": {\n \"years\": {\n \"one\": \"{0} yr\",\n \"other\": \"{0} yrs\"\n },\n \"months\": {\n \"one\": \"{0} mth\",\n \"other\": \"{0} mths\"\n },\n \"weeks\": {\n \"one\": \"{0} wk\",\n \"other\": \"{0} wks\"\n },\n \"days\": {\n \"one\": \"{0} day\",\n \"other\": \"{0} days\"\n },\n \"hours\": {\n \"one\": \"{0} hr\",\n \"other\": \"{0} hr\"\n },\n \"minutes\": {\n \"one\": \"{0} min\",\n \"other\": \"{0} min\"\n },\n \"seconds\": {\n \"one\": \"{0} sec\",\n \"other\": \"{0} sec\"\n }\n }\n }\n};\n","// Note: this is the semver.org version of the spec that it implements\n// Not necessarily the package version of this code.\nconst SEMVER_SPEC_VERSION = '2.0.0'\n\nconst MAX_LENGTH = 256\nconst MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER ||\n/* istanbul ignore next */ 9007199254740991\n\n// Max safe segment length for coercion.\nconst MAX_SAFE_COMPONENT_LENGTH = 16\n\n// Max safe length for a build identifier. The max length minus 6 characters for\n// the shortest version with a build 0.0.0+BUILD.\nconst MAX_SAFE_BUILD_LENGTH = MAX_LENGTH - 6\n\nconst RELEASE_TYPES = [\n 'major',\n 'premajor',\n 'minor',\n 'preminor',\n 'patch',\n 'prepatch',\n 'prerelease',\n]\n\nmodule.exports = {\n MAX_LENGTH,\n MAX_SAFE_COMPONENT_LENGTH,\n MAX_SAFE_BUILD_LENGTH,\n MAX_SAFE_INTEGER,\n RELEASE_TYPES,\n SEMVER_SPEC_VERSION,\n FLAG_INCLUDE_PRERELEASE: 0b001,\n FLAG_LOOSE: 0b010,\n}\n","const debug = (\n typeof process === 'object' &&\n process.env &&\n process.env.NODE_DEBUG &&\n /\\bsemver\\b/i.test(process.env.NODE_DEBUG)\n) ? (...args) => console.error('SEMVER', ...args)\n : () => {}\n\nmodule.exports = debug\n","const {\n MAX_SAFE_COMPONENT_LENGTH,\n MAX_SAFE_BUILD_LENGTH,\n MAX_LENGTH,\n} = require('./constants')\nconst debug = require('./debug')\nexports = module.exports = {}\n\n// The actual regexps go on exports.re\nconst re = exports.re = []\nconst safeRe = exports.safeRe = []\nconst src = exports.src = []\nconst t = exports.t = {}\nlet R = 0\n\nconst LETTERDASHNUMBER = '[a-zA-Z0-9-]'\n\n// Replace some greedy regex tokens to prevent regex dos issues. These regex are\n// used internally via the safeRe object since all inputs in this library get\n// normalized first to trim and collapse all extra whitespace. The original\n// regexes are exported for userland consumption and lower level usage. A\n// future breaking change could export the safer regex only with a note that\n// all input should have extra whitespace removed.\nconst safeRegexReplacements = [\n ['\\\\s', 1],\n ['\\\\d', MAX_LENGTH],\n [LETTERDASHNUMBER, MAX_SAFE_BUILD_LENGTH],\n]\n\nconst makeSafeRegex = (value) => {\n for (const [token, max] of safeRegexReplacements) {\n value = value\n .split(`${token}*`).join(`${token}{0,${max}}`)\n .split(`${token}+`).join(`${token}{1,${max}}`)\n }\n return value\n}\n\nconst createToken = (name, value, isGlobal) => {\n const safe = makeSafeRegex(value)\n const index = R++\n debug(name, index, value)\n t[name] = index\n src[index] = value\n re[index] = new RegExp(value, isGlobal ? 'g' : undefined)\n safeRe[index] = new RegExp(safe, isGlobal ? 'g' : undefined)\n}\n\n// The following Regular Expressions can be used for tokenizing,\n// validating, and parsing SemVer version strings.\n\n// ## Numeric Identifier\n// A single `0`, or a non-zero digit followed by zero or more digits.\n\ncreateToken('NUMERICIDENTIFIER', '0|[1-9]\\\\d*')\ncreateToken('NUMERICIDENTIFIERLOOSE', '\\\\d+')\n\n// ## Non-numeric Identifier\n// Zero or more digits, followed by a letter or hyphen, and then zero or\n// more letters, digits, or hyphens.\n\ncreateToken('NONNUMERICIDENTIFIER', `\\\\d*[a-zA-Z-]${LETTERDASHNUMBER}*`)\n\n// ## Main Version\n// Three dot-separated numeric identifiers.\n\ncreateToken('MAINVERSION', `(${src[t.NUMERICIDENTIFIER]})\\\\.` +\n `(${src[t.NUMERICIDENTIFIER]})\\\\.` +\n `(${src[t.NUMERICIDENTIFIER]})`)\n\ncreateToken('MAINVERSIONLOOSE', `(${src[t.NUMERICIDENTIFIERLOOSE]})\\\\.` +\n `(${src[t.NUMERICIDENTIFIERLOOSE]})\\\\.` +\n `(${src[t.NUMERICIDENTIFIERLOOSE]})`)\n\n// ## Pre-release Version Identifier\n// A numeric identifier, or a non-numeric identifier.\n\ncreateToken('PRERELEASEIDENTIFIER', `(?:${src[t.NUMERICIDENTIFIER]\n}|${src[t.NONNUMERICIDENTIFIER]})`)\n\ncreateToken('PRERELEASEIDENTIFIERLOOSE', `(?:${src[t.NUMERICIDENTIFIERLOOSE]\n}|${src[t.NONNUMERICIDENTIFIER]})`)\n\n// ## Pre-release Version\n// Hyphen, followed by one or more dot-separated pre-release version\n// identifiers.\n\ncreateToken('PRERELEASE', `(?:-(${src[t.PRERELEASEIDENTIFIER]\n}(?:\\\\.${src[t.PRERELEASEIDENTIFIER]})*))`)\n\ncreateToken('PRERELEASELOOSE', `(?:-?(${src[t.PRERELEASEIDENTIFIERLOOSE]\n}(?:\\\\.${src[t.PRERELEASEIDENTIFIERLOOSE]})*))`)\n\n// ## Build Metadata Identifier\n// Any combination of digits, letters, or hyphens.\n\ncreateToken('BUILDIDENTIFIER', `${LETTERDASHNUMBER}+`)\n\n// ## Build Metadata\n// Plus sign, followed by one or more period-separated build metadata\n// identifiers.\n\ncreateToken('BUILD', `(?:\\\\+(${src[t.BUILDIDENTIFIER]\n}(?:\\\\.${src[t.BUILDIDENTIFIER]})*))`)\n\n// ## Full Version String\n// A main version, followed optionally by a pre-release version and\n// build metadata.\n\n// Note that the only major, minor, patch, and pre-release sections of\n// the version string are capturing groups. The build metadata is not a\n// capturing group, because it should not ever be used in version\n// comparison.\n\ncreateToken('FULLPLAIN', `v?${src[t.MAINVERSION]\n}${src[t.PRERELEASE]}?${\n src[t.BUILD]}?`)\n\ncreateToken('FULL', `^${src[t.FULLPLAIN]}$`)\n\n// like full, but allows v1.2.3 and =1.2.3, which people do sometimes.\n// also, 1.0.0alpha1 (prerelease without the hyphen) which is pretty\n// common in the npm registry.\ncreateToken('LOOSEPLAIN', `[v=\\\\s]*${src[t.MAINVERSIONLOOSE]\n}${src[t.PRERELEASELOOSE]}?${\n src[t.BUILD]}?`)\n\ncreateToken('LOOSE', `^${src[t.LOOSEPLAIN]}$`)\n\ncreateToken('GTLT', '((?:<|>)?=?)')\n\n// Something like \"2.*\" or \"1.2.x\".\n// Note that \"x.x\" is a valid xRange identifer, meaning \"any version\"\n// Only the first item is strictly required.\ncreateToken('XRANGEIDENTIFIERLOOSE', `${src[t.NUMERICIDENTIFIERLOOSE]}|x|X|\\\\*`)\ncreateToken('XRANGEIDENTIFIER', `${src[t.NUMERICIDENTIFIER]}|x|X|\\\\*`)\n\ncreateToken('XRANGEPLAIN', `[v=\\\\s]*(${src[t.XRANGEIDENTIFIER]})` +\n `(?:\\\\.(${src[t.XRANGEIDENTIFIER]})` +\n `(?:\\\\.(${src[t.XRANGEIDENTIFIER]})` +\n `(?:${src[t.PRERELEASE]})?${\n src[t.BUILD]}?` +\n `)?)?`)\n\ncreateToken('XRANGEPLAINLOOSE', `[v=\\\\s]*(${src[t.XRANGEIDENTIFIERLOOSE]})` +\n `(?:\\\\.(${src[t.XRANGEIDENTIFIERLOOSE]})` +\n `(?:\\\\.(${src[t.XRANGEIDENTIFIERLOOSE]})` +\n `(?:${src[t.PRERELEASELOOSE]})?${\n src[t.BUILD]}?` +\n `)?)?`)\n\ncreateToken('XRANGE', `^${src[t.GTLT]}\\\\s*${src[t.XRANGEPLAIN]}$`)\ncreateToken('XRANGELOOSE', `^${src[t.GTLT]}\\\\s*${src[t.XRANGEPLAINLOOSE]}$`)\n\n// Coercion.\n// Extract anything that could conceivably be a part of a valid semver\ncreateToken('COERCEPLAIN', `${'(^|[^\\\\d])' +\n '(\\\\d{1,'}${MAX_SAFE_COMPONENT_LENGTH}})` +\n `(?:\\\\.(\\\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?` +\n `(?:\\\\.(\\\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?`)\ncreateToken('COERCE', `${src[t.COERCEPLAIN]}(?:$|[^\\\\d])`)\ncreateToken('COERCEFULL', src[t.COERCEPLAIN] +\n `(?:${src[t.PRERELEASE]})?` +\n `(?:${src[t.BUILD]})?` +\n `(?:$|[^\\\\d])`)\ncreateToken('COERCERTL', src[t.COERCE], true)\ncreateToken('COERCERTLFULL', src[t.COERCEFULL], true)\n\n// Tilde ranges.\n// Meaning is \"reasonably at or greater than\"\ncreateToken('LONETILDE', '(?:~>?)')\n\ncreateToken('TILDETRIM', `(\\\\s*)${src[t.LONETILDE]}\\\\s+`, true)\nexports.tildeTrimReplace = '$1~'\n\ncreateToken('TILDE', `^${src[t.LONETILDE]}${src[t.XRANGEPLAIN]}$`)\ncreateToken('TILDELOOSE', `^${src[t.LONETILDE]}${src[t.XRANGEPLAINLOOSE]}$`)\n\n// Caret ranges.\n// Meaning is \"at least and backwards compatible with\"\ncreateToken('LONECARET', '(?:\\\\^)')\n\ncreateToken('CARETTRIM', `(\\\\s*)${src[t.LONECARET]}\\\\s+`, true)\nexports.caretTrimReplace = '$1^'\n\ncreateToken('CARET', `^${src[t.LONECARET]}${src[t.XRANGEPLAIN]}$`)\ncreateToken('CARETLOOSE', `^${src[t.LONECARET]}${src[t.XRANGEPLAINLOOSE]}$`)\n\n// A simple gt/lt/eq thing, or just \"\" to indicate \"any version\"\ncreateToken('COMPARATORLOOSE', `^${src[t.GTLT]}\\\\s*(${src[t.LOOSEPLAIN]})$|^$`)\ncreateToken('COMPARATOR', `^${src[t.GTLT]}\\\\s*(${src[t.FULLPLAIN]})$|^$`)\n\n// An expression to strip any whitespace between the gtlt and the thing\n// it modifies, so that `> 1.2.3` ==> `>1.2.3`\ncreateToken('COMPARATORTRIM', `(\\\\s*)${src[t.GTLT]\n}\\\\s*(${src[t.LOOSEPLAIN]}|${src[t.XRANGEPLAIN]})`, true)\nexports.comparatorTrimReplace = '$1$2$3'\n\n// Something like `1.2.3 - 1.2.4`\n// Note that these all use the loose form, because they'll be\n// checked against either the strict or loose comparator form\n// later.\ncreateToken('HYPHENRANGE', `^\\\\s*(${src[t.XRANGEPLAIN]})` +\n `\\\\s+-\\\\s+` +\n `(${src[t.XRANGEPLAIN]})` +\n `\\\\s*$`)\n\ncreateToken('HYPHENRANGELOOSE', `^\\\\s*(${src[t.XRANGEPLAINLOOSE]})` +\n `\\\\s+-\\\\s+` +\n `(${src[t.XRANGEPLAINLOOSE]})` +\n `\\\\s*$`)\n\n// Star ranges basically just allow anything at all.\ncreateToken('STAR', '(<|>)?=?\\\\s*\\\\*')\n// >=0.0.0 is like a star\ncreateToken('GTE0', '^\\\\s*>=\\\\s*0\\\\.0\\\\.0\\\\s*$')\ncreateToken('GTE0PRE', '^\\\\s*>=\\\\s*0\\\\.0\\\\.0-0\\\\s*$')\n","// parse out just the options we care about\nconst looseOption = Object.freeze({ loose: true })\nconst emptyOpts = Object.freeze({ })\nconst parseOptions = options => {\n if (!options) {\n return emptyOpts\n }\n\n if (typeof options !== 'object') {\n return looseOption\n }\n\n return options\n}\nmodule.exports = parseOptions\n","const numeric = /^[0-9]+$/\nconst compareIdentifiers = (a, b) => {\n const anum = numeric.test(a)\n const bnum = numeric.test(b)\n\n if (anum && bnum) {\n a = +a\n b = +b\n }\n\n return a === b ? 0\n : (anum && !bnum) ? -1\n : (bnum && !anum) ? 1\n : a < b ? -1\n : 1\n}\n\nconst rcompareIdentifiers = (a, b) => compareIdentifiers(b, a)\n\nmodule.exports = {\n compareIdentifiers,\n rcompareIdentifiers,\n}\n","const debug = require('../internal/debug')\nconst { MAX_LENGTH, MAX_SAFE_INTEGER } = require('../internal/constants')\nconst { safeRe: re, t } = require('../internal/re')\n\nconst parseOptions = require('../internal/parse-options')\nconst { compareIdentifiers } = require('../internal/identifiers')\nclass SemVer {\n constructor (version, options) {\n options = parseOptions(options)\n\n if (version instanceof SemVer) {\n if (version.loose === !!options.loose &&\n version.includePrerelease === !!options.includePrerelease) {\n return version\n } else {\n version = version.version\n }\n } else if (typeof version !== 'string') {\n throw new TypeError(`Invalid version. Must be a string. Got type \"${typeof version}\".`)\n }\n\n if (version.length > MAX_LENGTH) {\n throw new TypeError(\n `version is longer than ${MAX_LENGTH} characters`\n )\n }\n\n debug('SemVer', version, options)\n this.options = options\n this.loose = !!options.loose\n // this isn't actually relevant for versions, but keep it so that we\n // don't run into trouble passing this.options around.\n this.includePrerelease = !!options.includePrerelease\n\n const m = version.trim().match(options.loose ? re[t.LOOSE] : re[t.FULL])\n\n if (!m) {\n throw new TypeError(`Invalid Version: ${version}`)\n }\n\n this.raw = version\n\n // these are actually numbers\n this.major = +m[1]\n this.minor = +m[2]\n this.patch = +m[3]\n\n if (this.major > MAX_SAFE_INTEGER || this.major < 0) {\n throw new TypeError('Invalid major version')\n }\n\n if (this.minor > MAX_SAFE_INTEGER || this.minor < 0) {\n throw new TypeError('Invalid minor version')\n }\n\n if (this.patch > MAX_SAFE_INTEGER || this.patch < 0) {\n throw new TypeError('Invalid patch version')\n }\n\n // numberify any prerelease numeric ids\n if (!m[4]) {\n this.prerelease = []\n } else {\n this.prerelease = m[4].split('.').map((id) => {\n if (/^[0-9]+$/.test(id)) {\n const num = +id\n if (num >= 0 && num < MAX_SAFE_INTEGER) {\n return num\n }\n }\n return id\n })\n }\n\n this.build = m[5] ? m[5].split('.') : []\n this.format()\n }\n\n format () {\n this.version = `${this.major}.${this.minor}.${this.patch}`\n if (this.prerelease.length) {\n this.version += `-${this.prerelease.join('.')}`\n }\n return this.version\n }\n\n toString () {\n return this.version\n }\n\n compare (other) {\n debug('SemVer.compare', this.version, this.options, other)\n if (!(other instanceof SemVer)) {\n if (typeof other === 'string' && other === this.version) {\n return 0\n }\n other = new SemVer(other, this.options)\n }\n\n if (other.version === this.version) {\n return 0\n }\n\n return this.compareMain(other) || this.comparePre(other)\n }\n\n compareMain (other) {\n if (!(other instanceof SemVer)) {\n other = new SemVer(other, this.options)\n }\n\n return (\n compareIdentifiers(this.major, other.major) ||\n compareIdentifiers(this.minor, other.minor) ||\n compareIdentifiers(this.patch, other.patch)\n )\n }\n\n comparePre (other) {\n if (!(other instanceof SemVer)) {\n other = new SemVer(other, this.options)\n }\n\n // NOT having a prerelease is > having one\n if (this.prerelease.length && !other.prerelease.length) {\n return -1\n } else if (!this.prerelease.length && other.prerelease.length) {\n return 1\n } else if (!this.prerelease.length && !other.prerelease.length) {\n return 0\n }\n\n let i = 0\n do {\n const a = this.prerelease[i]\n const b = other.prerelease[i]\n debug('prerelease compare', i, a, b)\n if (a === undefined && b === undefined) {\n return 0\n } else if (b === undefined) {\n return 1\n } else if (a === undefined) {\n return -1\n } else if (a === b) {\n continue\n } else {\n return compareIdentifiers(a, b)\n }\n } while (++i)\n }\n\n compareBuild (other) {\n if (!(other instanceof SemVer)) {\n other = new SemVer(other, this.options)\n }\n\n let i = 0\n do {\n const a = this.build[i]\n const b = other.build[i]\n debug('build compare', i, a, b)\n if (a === undefined && b === undefined) {\n return 0\n } else if (b === undefined) {\n return 1\n } else if (a === undefined) {\n return -1\n } else if (a === b) {\n continue\n } else {\n return compareIdentifiers(a, b)\n }\n } while (++i)\n }\n\n // preminor will bump the version up to the next minor release, and immediately\n // down to pre-release. premajor and prepatch work the same way.\n inc (release, identifier, identifierBase) {\n switch (release) {\n case 'premajor':\n this.prerelease.length = 0\n this.patch = 0\n this.minor = 0\n this.major++\n this.inc('pre', identifier, identifierBase)\n break\n case 'preminor':\n this.prerelease.length = 0\n this.patch = 0\n this.minor++\n this.inc('pre', identifier, identifierBase)\n break\n case 'prepatch':\n // If this is already a prerelease, it will bump to the next version\n // drop any prereleases that might already exist, since they are not\n // relevant at this point.\n this.prerelease.length = 0\n this.inc('patch', identifier, identifierBase)\n this.inc('pre', identifier, identifierBase)\n break\n // If the input is a non-prerelease version, this acts the same as\n // prepatch.\n case 'prerelease':\n if (this.prerelease.length === 0) {\n this.inc('patch', identifier, identifierBase)\n }\n this.inc('pre', identifier, identifierBase)\n break\n\n case 'major':\n // If this is a pre-major version, bump up to the same major version.\n // Otherwise increment major.\n // 1.0.0-5 bumps to 1.0.0\n // 1.1.0 bumps to 2.0.0\n if (\n this.minor !== 0 ||\n this.patch !== 0 ||\n this.prerelease.length === 0\n ) {\n this.major++\n }\n this.minor = 0\n this.patch = 0\n this.prerelease = []\n break\n case 'minor':\n // If this is a pre-minor version, bump up to the same minor version.\n // Otherwise increment minor.\n // 1.2.0-5 bumps to 1.2.0\n // 1.2.1 bumps to 1.3.0\n if (this.patch !== 0 || this.prerelease.length === 0) {\n this.minor++\n }\n this.patch = 0\n this.prerelease = []\n break\n case 'patch':\n // If this is not a pre-release version, it will increment the patch.\n // If it is a pre-release it will bump up to the same patch version.\n // 1.2.0-5 patches to 1.2.0\n // 1.2.0 patches to 1.2.1\n if (this.prerelease.length === 0) {\n this.patch++\n }\n this.prerelease = []\n break\n // This probably shouldn't be used publicly.\n // 1.0.0 'pre' would become 1.0.0-0 which is the wrong direction.\n case 'pre': {\n const base = Number(identifierBase) ? 1 : 0\n\n if (!identifier && identifierBase === false) {\n throw new Error('invalid increment argument: identifier is empty')\n }\n\n if (this.prerelease.length === 0) {\n this.prerelease = [base]\n } else {\n let i = this.prerelease.length\n while (--i >= 0) {\n if (typeof this.prerelease[i] === 'number') {\n this.prerelease[i]++\n i = -2\n }\n }\n if (i === -1) {\n // didn't increment anything\n if (identifier === this.prerelease.join('.') && identifierBase === false) {\n throw new Error('invalid increment argument: identifier already exists')\n }\n this.prerelease.push(base)\n }\n }\n if (identifier) {\n // 1.2.0-beta.1 bumps to 1.2.0-beta.2,\n // 1.2.0-beta.fooblz or 1.2.0-beta bumps to 1.2.0-beta.0\n let prerelease = [identifier, base]\n if (identifierBase === false) {\n prerelease = [identifier]\n }\n if (compareIdentifiers(this.prerelease[0], identifier) === 0) {\n if (isNaN(this.prerelease[1])) {\n this.prerelease = prerelease\n }\n } else {\n this.prerelease = prerelease\n }\n }\n break\n }\n default:\n throw new Error(`invalid increment argument: ${release}`)\n }\n this.raw = this.format()\n if (this.build.length) {\n this.raw += `+${this.build.join('.')}`\n }\n return this\n }\n}\n\nmodule.exports = SemVer\n","const SemVer = require('../classes/semver')\nconst parse = (version, options, throwErrors = false) => {\n if (version instanceof SemVer) {\n return version\n }\n try {\n return new SemVer(version, options)\n } catch (er) {\n if (!throwErrors) {\n return null\n }\n throw er\n }\n}\n\nmodule.exports = parse\n","const parse = require('./parse')\nconst valid = (version, options) => {\n const v = parse(version, options)\n return v ? v.version : null\n}\nmodule.exports = valid\n","const parse = require('./parse')\nconst clean = (version, options) => {\n const s = parse(version.trim().replace(/^[=v]+/, ''), options)\n return s ? s.version : null\n}\nmodule.exports = clean\n","const SemVer = require('../classes/semver')\n\nconst inc = (version, release, options, identifier, identifierBase) => {\n if (typeof (options) === 'string') {\n identifierBase = identifier\n identifier = options\n options = undefined\n }\n\n try {\n return new SemVer(\n version instanceof SemVer ? version.version : version,\n options\n ).inc(release, identifier, identifierBase).version\n } catch (er) {\n return null\n }\n}\nmodule.exports = inc\n","const parse = require('./parse.js')\n\nconst diff = (version1, version2) => {\n const v1 = parse(version1, null, true)\n const v2 = parse(version2, null, true)\n const comparison = v1.compare(v2)\n\n if (comparison === 0) {\n return null\n }\n\n const v1Higher = comparison > 0\n const highVersion = v1Higher ? v1 : v2\n const lowVersion = v1Higher ? v2 : v1\n const highHasPre = !!highVersion.prerelease.length\n const lowHasPre = !!lowVersion.prerelease.length\n\n if (lowHasPre && !highHasPre) {\n // Going from prerelease -> no prerelease requires some special casing\n\n // If the low version has only a major, then it will always be a major\n // Some examples:\n // 1.0.0-1 -> 1.0.0\n // 1.0.0-1 -> 1.1.1\n // 1.0.0-1 -> 2.0.0\n if (!lowVersion.patch && !lowVersion.minor) {\n return 'major'\n }\n\n // Otherwise it can be determined by checking the high version\n\n if (highVersion.patch) {\n // anything higher than a patch bump would result in the wrong version\n return 'patch'\n }\n\n if (highVersion.minor) {\n // anything higher than a minor bump would result in the wrong version\n return 'minor'\n }\n\n // bumping major/minor/patch all have same result\n return 'major'\n }\n\n // add the `pre` prefix if we are going to a prerelease version\n const prefix = highHasPre ? 'pre' : ''\n\n if (v1.major !== v2.major) {\n return prefix + 'major'\n }\n\n if (v1.minor !== v2.minor) {\n return prefix + 'minor'\n }\n\n if (v1.patch !== v2.patch) {\n return prefix + 'patch'\n }\n\n // high and low are preleases\n return 'prerelease'\n}\n\nmodule.exports = diff\n","const SemVer = require('../classes/semver')\nconst major = (a, loose) => new SemVer(a, loose).major\nmodule.exports = major\n","const SemVer = require('../classes/semver')\nconst minor = (a, loose) => new SemVer(a, loose).minor\nmodule.exports = minor\n","const SemVer = require('../classes/semver')\nconst patch = (a, loose) => new SemVer(a, loose).patch\nmodule.exports = patch\n","const parse = require('./parse')\nconst prerelease = (version, options) => {\n const parsed = parse(version, options)\n return (parsed && parsed.prerelease.length) ? parsed.prerelease : null\n}\nmodule.exports = prerelease\n","const SemVer = require('../classes/semver')\nconst compare = (a, b, loose) =>\n new SemVer(a, loose).compare(new SemVer(b, loose))\n\nmodule.exports = compare\n","const compare = require('./compare')\nconst rcompare = (a, b, loose) => compare(b, a, loose)\nmodule.exports = rcompare\n","const compare = require('./compare')\nconst compareLoose = (a, b) => compare(a, b, true)\nmodule.exports = compareLoose\n","const SemVer = require('../classes/semver')\nconst compareBuild = (a, b, loose) => {\n const versionA = new SemVer(a, loose)\n const versionB = new SemVer(b, loose)\n return versionA.compare(versionB) || versionA.compareBuild(versionB)\n}\nmodule.exports = compareBuild\n","const compareBuild = require('./compare-build')\nconst sort = (list, loose) => list.sort((a, b) => compareBuild(a, b, loose))\nmodule.exports = sort\n","const compareBuild = require('./compare-build')\nconst rsort = (list, loose) => list.sort((a, b) => compareBuild(b, a, loose))\nmodule.exports = rsort\n","const compare = require('./compare')\nconst gt = (a, b, loose) => compare(a, b, loose) > 0\nmodule.exports = gt\n","const compare = require('./compare')\nconst lt = (a, b, loose) => compare(a, b, loose) < 0\nmodule.exports = lt\n","const compare = require('./compare')\nconst eq = (a, b, loose) => compare(a, b, loose) === 0\nmodule.exports = eq\n","const compare = require('./compare')\nconst neq = (a, b, loose) => compare(a, b, loose) !== 0\nmodule.exports = neq\n","const compare = require('./compare')\nconst gte = (a, b, loose) => compare(a, b, loose) >= 0\nmodule.exports = gte\n","const compare = require('./compare')\nconst lte = (a, b, loose) => compare(a, b, loose) <= 0\nmodule.exports = lte\n","const eq = require('./eq')\nconst neq = require('./neq')\nconst gt = require('./gt')\nconst gte = require('./gte')\nconst lt = require('./lt')\nconst lte = require('./lte')\n\nconst cmp = (a, op, b, loose) => {\n switch (op) {\n case '===':\n if (typeof a === 'object') {\n a = a.version\n }\n if (typeof b === 'object') {\n b = b.version\n }\n return a === b\n\n case '!==':\n if (typeof a === 'object') {\n a = a.version\n }\n if (typeof b === 'object') {\n b = b.version\n }\n return a !== b\n\n case '':\n case '=':\n case '==':\n return eq(a, b, loose)\n\n case '!=':\n return neq(a, b, loose)\n\n case '>':\n return gt(a, b, loose)\n\n case '>=':\n return gte(a, b, loose)\n\n case '<':\n return lt(a, b, loose)\n\n case '<=':\n return lte(a, b, loose)\n\n default:\n throw new TypeError(`Invalid operator: ${op}`)\n }\n}\nmodule.exports = cmp\n","const SemVer = require('../classes/semver')\nconst parse = require('./parse')\nconst { safeRe: re, t } = require('../internal/re')\n\nconst coerce = (version, options) => {\n if (version instanceof SemVer) {\n return version\n }\n\n if (typeof version === 'number') {\n version = String(version)\n }\n\n if (typeof version !== 'string') {\n return null\n }\n\n options = options || {}\n\n let match = null\n if (!options.rtl) {\n match = version.match(options.includePrerelease ? re[t.COERCEFULL] : re[t.COERCE])\n } else {\n // Find the right-most coercible string that does not share\n // a terminus with a more left-ward coercible string.\n // Eg, '1.2.3.4' wants to coerce '2.3.4', not '3.4' or '4'\n // With includePrerelease option set, '1.2.3.4-rc' wants to coerce '2.3.4-rc', not '2.3.4'\n //\n // Walk through the string checking with a /g regexp\n // Manually set the index so as to pick up overlapping matches.\n // Stop when we get a match that ends at the string end, since no\n // coercible string can be more right-ward without the same terminus.\n const coerceRtlRegex = options.includePrerelease ? re[t.COERCERTLFULL] : re[t.COERCERTL]\n let next\n while ((next = coerceRtlRegex.exec(version)) &&\n (!match || match.index + match[0].length !== version.length)\n ) {\n if (!match ||\n next.index + next[0].length !== match.index + match[0].length) {\n match = next\n }\n coerceRtlRegex.lastIndex = next.index + next[1].length + next[2].length\n }\n // leave it in a clean state\n coerceRtlRegex.lastIndex = -1\n }\n\n if (match === null) {\n return null\n }\n\n const major = match[2]\n const minor = match[3] || '0'\n const patch = match[4] || '0'\n const prerelease = options.includePrerelease && match[5] ? `-${match[5]}` : ''\n const build = options.includePrerelease && match[6] ? `+${match[6]}` : ''\n\n return parse(`${major}.${minor}.${patch}${prerelease}${build}`, options)\n}\nmodule.exports = coerce\n","class LRUCache {\n constructor () {\n this.max = 1000\n this.map = new Map()\n }\n\n get (key) {\n const value = this.map.get(key)\n if (value === undefined) {\n return undefined\n } else {\n // Remove the key from the map and add it to the end\n this.map.delete(key)\n this.map.set(key, value)\n return value\n }\n }\n\n delete (key) {\n return this.map.delete(key)\n }\n\n set (key, value) {\n const deleted = this.delete(key)\n\n if (!deleted && value !== undefined) {\n // If cache is full, delete the least recently used item\n if (this.map.size >= this.max) {\n const firstKey = this.map.keys().next().value\n this.delete(firstKey)\n }\n\n this.map.set(key, value)\n }\n\n return this\n }\n}\n\nmodule.exports = LRUCache\n","const Range = require('../classes/range')\nconst satisfies = (version, range, options) => {\n try {\n range = new Range(range, options)\n } catch (er) {\n return false\n }\n return range.test(version)\n}\nmodule.exports = satisfies\n","const Range = require('../classes/range')\n\n// Mostly just for testing and legacy API reasons\nconst toComparators = (range, options) =>\n new Range(range, options).set\n .map(comp => comp.map(c => c.value).join(' ').trim().split(' '))\n\nmodule.exports = toComparators\n","const SemVer = require('../classes/semver')\nconst Range = require('../classes/range')\n\nconst maxSatisfying = (versions, range, options) => {\n let max = null\n let maxSV = null\n let rangeObj = null\n try {\n rangeObj = new Range(range, options)\n } catch (er) {\n return null\n }\n versions.forEach((v) => {\n if (rangeObj.test(v)) {\n // satisfies(v, range, options)\n if (!max || maxSV.compare(v) === -1) {\n // compare(max, v, true)\n max = v\n maxSV = new SemVer(max, options)\n }\n }\n })\n return max\n}\nmodule.exports = maxSatisfying\n","const SemVer = require('../classes/semver')\nconst Range = require('../classes/range')\nconst minSatisfying = (versions, range, options) => {\n let min = null\n let minSV = null\n let rangeObj = null\n try {\n rangeObj = new Range(range, options)\n } catch (er) {\n return null\n }\n versions.forEach((v) => {\n if (rangeObj.test(v)) {\n // satisfies(v, range, options)\n if (!min || minSV.compare(v) === 1) {\n // compare(min, v, true)\n min = v\n minSV = new SemVer(min, options)\n }\n }\n })\n return min\n}\nmodule.exports = minSatisfying\n","const SemVer = require('../classes/semver')\nconst Range = require('../classes/range')\nconst gt = require('../functions/gt')\n\nconst minVersion = (range, loose) => {\n range = new Range(range, loose)\n\n let minver = new SemVer('0.0.0')\n if (range.test(minver)) {\n return minver\n }\n\n minver = new SemVer('0.0.0-0')\n if (range.test(minver)) {\n return minver\n }\n\n minver = null\n for (let i = 0; i < range.set.length; ++i) {\n const comparators = range.set[i]\n\n let setMin = null\n comparators.forEach((comparator) => {\n // Clone to avoid manipulating the comparator's semver object.\n const compver = new SemVer(comparator.semver.version)\n switch (comparator.operator) {\n case '>':\n if (compver.prerelease.length === 0) {\n compver.patch++\n } else {\n compver.prerelease.push(0)\n }\n compver.raw = compver.format()\n /* fallthrough */\n case '':\n case '>=':\n if (!setMin || gt(compver, setMin)) {\n setMin = compver\n }\n break\n case '<':\n case '<=':\n /* Ignore maximum versions */\n break\n /* istanbul ignore next */\n default:\n throw new Error(`Unexpected operation: ${comparator.operator}`)\n }\n })\n if (setMin && (!minver || gt(minver, setMin))) {\n minver = setMin\n }\n }\n\n if (minver && range.test(minver)) {\n return minver\n }\n\n return null\n}\nmodule.exports = minVersion\n","const Range = require('../classes/range')\nconst validRange = (range, options) => {\n try {\n // Return '*' instead of '' so that truthiness works.\n // This will throw if it's invalid anyway\n return new Range(range, options).range || '*'\n } catch (er) {\n return null\n }\n}\nmodule.exports = validRange\n","const SemVer = require('../classes/semver')\nconst Comparator = require('../classes/comparator')\nconst { ANY } = Comparator\nconst Range = require('../classes/range')\nconst satisfies = require('../functions/satisfies')\nconst gt = require('../functions/gt')\nconst lt = require('../functions/lt')\nconst lte = require('../functions/lte')\nconst gte = require('../functions/gte')\n\nconst outside = (version, range, hilo, options) => {\n version = new SemVer(version, options)\n range = new Range(range, options)\n\n let gtfn, ltefn, ltfn, comp, ecomp\n switch (hilo) {\n case '>':\n gtfn = gt\n ltefn = lte\n ltfn = lt\n comp = '>'\n ecomp = '>='\n break\n case '<':\n gtfn = lt\n ltefn = gte\n ltfn = gt\n comp = '<'\n ecomp = '<='\n break\n default:\n throw new TypeError('Must provide a hilo val of \"<\" or \">\"')\n }\n\n // If it satisfies the range it is not outside\n if (satisfies(version, range, options)) {\n return false\n }\n\n // From now on, variable terms are as if we're in \"gtr\" mode.\n // but note that everything is flipped for the \"ltr\" function.\n\n for (let i = 0; i < range.set.length; ++i) {\n const comparators = range.set[i]\n\n let high = null\n let low = null\n\n comparators.forEach((comparator) => {\n if (comparator.semver === ANY) {\n comparator = new Comparator('>=0.0.0')\n }\n high = high || comparator\n low = low || comparator\n if (gtfn(comparator.semver, high.semver, options)) {\n high = comparator\n } else if (ltfn(comparator.semver, low.semver, options)) {\n low = comparator\n }\n })\n\n // If the edge version comparator has a operator then our version\n // isn't outside it\n if (high.operator === comp || high.operator === ecomp) {\n return false\n }\n\n // If the lowest version comparator has an operator and our version\n // is less than it then it isn't higher than the range\n if ((!low.operator || low.operator === comp) &&\n ltefn(version, low.semver)) {\n return false\n } else if (low.operator === ecomp && ltfn(version, low.semver)) {\n return false\n }\n }\n return true\n}\n\nmodule.exports = outside\n","// Determine if version is greater than all the versions possible in the range.\nconst outside = require('./outside')\nconst gtr = (version, range, options) => outside(version, range, '>', options)\nmodule.exports = gtr\n","const outside = require('./outside')\n// Determine if version is less than all the versions possible in the range\nconst ltr = (version, range, options) => outside(version, range, '<', options)\nmodule.exports = ltr\n","const Range = require('../classes/range')\nconst intersects = (r1, r2, options) => {\n r1 = new Range(r1, options)\n r2 = new Range(r2, options)\n return r1.intersects(r2, options)\n}\nmodule.exports = intersects\n","// given a set of versions and a range, create a \"simplified\" range\n// that includes the same versions that the original range does\n// If the original range is shorter than the simplified one, return that.\nconst satisfies = require('../functions/satisfies.js')\nconst compare = require('../functions/compare.js')\nmodule.exports = (versions, range, options) => {\n const set = []\n let first = null\n let prev = null\n const v = versions.sort((a, b) => compare(a, b, options))\n for (const version of v) {\n const included = satisfies(version, range, options)\n if (included) {\n prev = version\n if (!first) {\n first = version\n }\n } else {\n if (prev) {\n set.push([first, prev])\n }\n prev = null\n first = null\n }\n }\n if (first) {\n set.push([first, null])\n }\n\n const ranges = []\n for (const [min, max] of set) {\n if (min === max) {\n ranges.push(min)\n } else if (!max && min === v[0]) {\n ranges.push('*')\n } else if (!max) {\n ranges.push(`>=${min}`)\n } else if (min === v[0]) {\n ranges.push(`<=${max}`)\n } else {\n ranges.push(`${min} - ${max}`)\n }\n }\n const simplified = ranges.join(' || ')\n const original = typeof range.raw === 'string' ? range.raw : String(range)\n return simplified.length < original.length ? simplified : range\n}\n","const Range = require('../classes/range.js')\nconst Comparator = require('../classes/comparator.js')\nconst { ANY } = Comparator\nconst satisfies = require('../functions/satisfies.js')\nconst compare = require('../functions/compare.js')\n\n// Complex range `r1 || r2 || ...` is a subset of `R1 || R2 || ...` iff:\n// - Every simple range `r1, r2, ...` is a null set, OR\n// - Every simple range `r1, r2, ...` which is not a null set is a subset of\n// some `R1, R2, ...`\n//\n// Simple range `c1 c2 ...` is a subset of simple range `C1 C2 ...` iff:\n// - If c is only the ANY comparator\n// - If C is only the ANY comparator, return true\n// - Else if in prerelease mode, return false\n// - else replace c with `[>=0.0.0]`\n// - If C is only the ANY comparator\n// - if in prerelease mode, return true\n// - else replace C with `[>=0.0.0]`\n// - Let EQ be the set of = comparators in c\n// - If EQ is more than one, return true (null set)\n// - Let GT be the highest > or >= comparator in c\n// - Let LT be the lowest < or <= comparator in c\n// - If GT and LT, and GT.semver > LT.semver, return true (null set)\n// - If any C is a = range, and GT or LT are set, return false\n// - If EQ\n// - If GT, and EQ does not satisfy GT, return true (null set)\n// - If LT, and EQ does not satisfy LT, return true (null set)\n// - If EQ satisfies every C, return true\n// - Else return false\n// - If GT\n// - If GT.semver is lower than any > or >= comp in C, return false\n// - If GT is >=, and GT.semver does not satisfy every C, return false\n// - If GT.semver has a prerelease, and not in prerelease mode\n// - If no C has a prerelease and the GT.semver tuple, return false\n// - If LT\n// - If LT.semver is greater than any < or <= comp in C, return false\n// - If LT is <=, and LT.semver does not satisfy every C, return false\n// - If GT.semver has a prerelease, and not in prerelease mode\n// - If no C has a prerelease and the LT.semver tuple, return false\n// - Else return true\n\nconst subset = (sub, dom, options = {}) => {\n if (sub === dom) {\n return true\n }\n\n sub = new Range(sub, options)\n dom = new Range(dom, options)\n let sawNonNull = false\n\n OUTER: for (const simpleSub of sub.set) {\n for (const simpleDom of dom.set) {\n const isSub = simpleSubset(simpleSub, simpleDom, options)\n sawNonNull = sawNonNull || isSub !== null\n if (isSub) {\n continue OUTER\n }\n }\n // the null set is a subset of everything, but null simple ranges in\n // a complex range should be ignored. so if we saw a non-null range,\n // then we know this isn't a subset, but if EVERY simple range was null,\n // then it is a subset.\n if (sawNonNull) {\n return false\n }\n }\n return true\n}\n\nconst minimumVersionWithPreRelease = [new Comparator('>=0.0.0-0')]\nconst minimumVersion = [new Comparator('>=0.0.0')]\n\nconst simpleSubset = (sub, dom, options) => {\n if (sub === dom) {\n return true\n }\n\n if (sub.length === 1 && sub[0].semver === ANY) {\n if (dom.length === 1 && dom[0].semver === ANY) {\n return true\n } else if (options.includePrerelease) {\n sub = minimumVersionWithPreRelease\n } else {\n sub = minimumVersion\n }\n }\n\n if (dom.length === 1 && dom[0].semver === ANY) {\n if (options.includePrerelease) {\n return true\n } else {\n dom = minimumVersion\n }\n }\n\n const eqSet = new Set()\n let gt, lt\n for (const c of sub) {\n if (c.operator === '>' || c.operator === '>=') {\n gt = higherGT(gt, c, options)\n } else if (c.operator === '<' || c.operator === '<=') {\n lt = lowerLT(lt, c, options)\n } else {\n eqSet.add(c.semver)\n }\n }\n\n if (eqSet.size > 1) {\n return null\n }\n\n let gtltComp\n if (gt && lt) {\n gtltComp = compare(gt.semver, lt.semver, options)\n if (gtltComp > 0) {\n return null\n } else if (gtltComp === 0 && (gt.operator !== '>=' || lt.operator !== '<=')) {\n return null\n }\n }\n\n // will iterate one or zero times\n for (const eq of eqSet) {\n if (gt && !satisfies(eq, String(gt), options)) {\n return null\n }\n\n if (lt && !satisfies(eq, String(lt), options)) {\n return null\n }\n\n for (const c of dom) {\n if (!satisfies(eq, String(c), options)) {\n return false\n }\n }\n\n return true\n }\n\n let higher, lower\n let hasDomLT, hasDomGT\n // if the subset has a prerelease, we need a comparator in the superset\n // with the same tuple and a prerelease, or it's not a subset\n let needDomLTPre = lt &&\n !options.includePrerelease &&\n lt.semver.prerelease.length ? lt.semver : false\n let needDomGTPre = gt &&\n !options.includePrerelease &&\n gt.semver.prerelease.length ? gt.semver : false\n // exception: <1.2.3-0 is the same as <1.2.3\n if (needDomLTPre && needDomLTPre.prerelease.length === 1 &&\n lt.operator === '<' && needDomLTPre.prerelease[0] === 0) {\n needDomLTPre = false\n }\n\n for (const c of dom) {\n hasDomGT = hasDomGT || c.operator === '>' || c.operator === '>='\n hasDomLT = hasDomLT || c.operator === '<' || c.operator === '<='\n if (gt) {\n if (needDomGTPre) {\n if (c.semver.prerelease && c.semver.prerelease.length &&\n c.semver.major === needDomGTPre.major &&\n c.semver.minor === needDomGTPre.minor &&\n c.semver.patch === needDomGTPre.patch) {\n needDomGTPre = false\n }\n }\n if (c.operator === '>' || c.operator === '>=') {\n higher = higherGT(gt, c, options)\n if (higher === c && higher !== gt) {\n return false\n }\n } else if (gt.operator === '>=' && !satisfies(gt.semver, String(c), options)) {\n return false\n }\n }\n if (lt) {\n if (needDomLTPre) {\n if (c.semver.prerelease && c.semver.prerelease.length &&\n c.semver.major === needDomLTPre.major &&\n c.semver.minor === needDomLTPre.minor &&\n c.semver.patch === needDomLTPre.patch) {\n needDomLTPre = false\n }\n }\n if (c.operator === '<' || c.operator === '<=') {\n lower = lowerLT(lt, c, options)\n if (lower === c && lower !== lt) {\n return false\n }\n } else if (lt.operator === '<=' && !satisfies(lt.semver, String(c), options)) {\n return false\n }\n }\n if (!c.operator && (lt || gt) && gtltComp !== 0) {\n return false\n }\n }\n\n // if there was a < or >, and nothing in the dom, then must be false\n // UNLESS it was limited by another range in the other direction.\n // Eg, >1.0.0 <1.0.1 is still a subset of <2.0.0\n if (gt && hasDomLT && !lt && gtltComp !== 0) {\n return false\n }\n\n if (lt && hasDomGT && !gt && gtltComp !== 0) {\n return false\n }\n\n // we needed a prerelease range in a specific tuple, but didn't get one\n // then this isn't a subset. eg >=1.2.3-pre is not a subset of >=1.0.0,\n // because it includes prereleases in the 1.2.3 tuple\n if (needDomGTPre || needDomLTPre) {\n return false\n }\n\n return true\n}\n\n// >=1.2.3 is lower than >1.2.3\nconst higherGT = (a, b, options) => {\n if (!a) {\n return b\n }\n const comp = compare(a.semver, b.semver, options)\n return comp > 0 ? a\n : comp < 0 ? b\n : b.operator === '>' && a.operator === '>=' ? b\n : a\n}\n\n// <=1.2.3 is higher than <1.2.3\nconst lowerLT = (a, b, options) => {\n if (!a) {\n return b\n }\n const comp = compare(a.semver, b.semver, options)\n return comp < 0 ? a\n : comp > 0 ? b\n : b.operator === '<' && a.operator === '<=' ? b\n : a\n}\n\nmodule.exports = subset\n","// just pre-load all the stuff that index.js lazily exports\nconst internalRe = require('./internal/re')\nconst constants = require('./internal/constants')\nconst SemVer = require('./classes/semver')\nconst identifiers = require('./internal/identifiers')\nconst parse = require('./functions/parse')\nconst valid = require('./functions/valid')\nconst clean = require('./functions/clean')\nconst inc = require('./functions/inc')\nconst diff = require('./functions/diff')\nconst major = require('./functions/major')\nconst minor = require('./functions/minor')\nconst patch = require('./functions/patch')\nconst prerelease = require('./functions/prerelease')\nconst compare = require('./functions/compare')\nconst rcompare = require('./functions/rcompare')\nconst compareLoose = require('./functions/compare-loose')\nconst compareBuild = require('./functions/compare-build')\nconst sort = require('./functions/sort')\nconst rsort = require('./functions/rsort')\nconst gt = require('./functions/gt')\nconst lt = require('./functions/lt')\nconst eq = require('./functions/eq')\nconst neq = require('./functions/neq')\nconst gte = require('./functions/gte')\nconst lte = require('./functions/lte')\nconst cmp = require('./functions/cmp')\nconst coerce = require('./functions/coerce')\nconst Comparator = require('./classes/comparator')\nconst Range = require('./classes/range')\nconst satisfies = require('./functions/satisfies')\nconst toComparators = require('./ranges/to-comparators')\nconst maxSatisfying = require('./ranges/max-satisfying')\nconst minSatisfying = require('./ranges/min-satisfying')\nconst minVersion = require('./ranges/min-version')\nconst validRange = require('./ranges/valid')\nconst outside = require('./ranges/outside')\nconst gtr = require('./ranges/gtr')\nconst ltr = require('./ranges/ltr')\nconst intersects = require('./ranges/intersects')\nconst simplifyRange = require('./ranges/simplify')\nconst subset = require('./ranges/subset')\nmodule.exports = {\n parse,\n valid,\n clean,\n inc,\n diff,\n major,\n minor,\n patch,\n prerelease,\n compare,\n rcompare,\n compareLoose,\n compareBuild,\n sort,\n rsort,\n gt,\n lt,\n eq,\n neq,\n gte,\n lte,\n cmp,\n coerce,\n Comparator,\n Range,\n satisfies,\n toComparators,\n maxSatisfying,\n minSatisfying,\n minVersion,\n validRange,\n outside,\n gtr,\n ltr,\n intersects,\n simplifyRange,\n subset,\n SemVer,\n re: internalRe.re,\n src: internalRe.src,\n tokens: internalRe.t,\n SEMVER_SPEC_VERSION: constants.SEMVER_SPEC_VERSION,\n RELEASE_TYPES: constants.RELEASE_TYPES,\n compareIdentifiers: identifiers.compareIdentifiers,\n rcompareIdentifiers: identifiers.rcompareIdentifiers,\n}\n","'use strict';Object.defineProperty(exports,'__esModule',{value:!0}),exports.DownloaderHelper=exports.DH_STATES=void 0;var _typeof='function'==typeof Symbol&&'symbol'==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&'function'==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?'symbol':typeof a},_createClass=function(){function a(a,b){for(var c,d=0;d<b.length;d++)c=b[d],c.enumerable=c.enumerable||!1,c.configurable=!0,'value'in c&&(c.writable=!0),Object.defineProperty(a,c.key,c)}return function(b,c,d){return c&&a(b.prototype,c),d&&a(b,d),b}}(),_fs=require('fs'),fs=_interopRequireWildcard(_fs),_url=require('url'),_path=require('path'),path=_interopRequireWildcard(_path),_http=require('http'),http=_interopRequireWildcard(_http),_https=require('https'),https=_interopRequireWildcard(_https),_events=require('events');function _interopRequireWildcard(a){if(a&&a.__esModule)return a;var b={};if(null!=a)for(var c in a)Object.prototype.hasOwnProperty.call(a,c)&&(b[c]=a[c]);return b.default=a,b}function _classCallCheck(a,b){if(!(a instanceof b))throw new TypeError('Cannot call a class as a function')}function _possibleConstructorReturn(a,b){if(!a)throw new ReferenceError('this hasn\\'t been initialised - super() hasn\\'t been called');return b&&('object'==typeof b||'function'==typeof b)?b:a}function _inherits(a,b){if('function'!=typeof b&&null!==b)throw new TypeError('Super expression must either be null or a function, not '+typeof b);a.prototype=Object.create(b&&b.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(a,b):a.__proto__=b)}var DH_STATES=exports.DH_STATES={IDLE:'IDLE',SKIPPED:'SKIPPED',STARTED:'STARTED',DOWNLOADING:'DOWNLOADING',RETRY:'RETRY',PAUSED:'PAUSED',RESUMED:'RESUMED',STOPPED:'STOPPED',FINISHED:'FINISHED',FAILED:'FAILED'},DownloaderHelper=exports.DownloaderHelper=function(a){function b(a,c){var d=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};_classCallCheck(this,b);var e=_possibleConstructorReturn(this,(b.__proto__||Object.getPrototypeOf(b)).call(this,{captureRejections:!0}));return e.__validate(a,c)?(e.url=e.requestURL=a.trim(),e.state=DH_STATES.IDLE,e.__defaultOpts={body:null,retry:!1,method:'GET',headers:{},fileName:'',timeout:-1,metadata:null,override:!1,forceResume:!1,removeOnStop:!0,removeOnFail:!0,progressThrottle:1e3,httpRequestOptions:{},httpsRequestOptions:{},resumeOnIncomplete:!0,resumeIfFileExists:!1,resumeOnIncompleteMaxRetry:5},e.__opts=Object.assign({},e.__defaultOpts),e.__pipes=[],e.__total=0,e.__downloaded=0,e.__progress=0,e.__retryCount=0,e.__retryTimeout=null,e.__resumeRetryCount=0,e.__states=DH_STATES,e.__promise=null,e.__request=null,e.__response=null,e.__isAborted=!1,e.__isResumed=!1,e.__isResumable=!1,e.__isRedirected=!1,e.__destFolder=c,e.__statsEstimate={time:0,bytes:0,prevBytes:0,throttleTime:0},e.__fileName='',e.__filePath='',e.updateOptions(d),e):_possibleConstructorReturn(e)}return _inherits(b,a),_createClass(b,[{key:'start',value:function c(){var a=this,b=function(){return new Promise(function(b,c){a.__promise={resolve:b,reject:c},a.__start()})};return this.__opts.resumeIfFileExists&&this.state!==this.__states.RESUMED?this.getTotalSize().then(function(c){var d=c.name,e=c.total,f=a.__opts.override;if(a.__opts.override=!0,a.__filePath=a.__getFilePath(d),a.__opts.override=f,a.__filePath&&fs.existsSync(a.__filePath)){var g=a.__getFilesizeInBytes(a.__filePath);return g===e?b():a.resumeFromFile(a.__filePath,{total:e,fileName:d})}return b()}):b()}},{key:'pause',value:function b(){var a=this;return this.state===this.__states.STOPPED?Promise.resolve(!0):(this.__response&&(this.__response.unpipe(),this.__pipes.forEach(function(a){return a.stream.unpipe()})),this.__fileStream&&this.__fileStream.removeAllListeners(),this.__requestAbort(),this.__closeFileStream().then(function(){return a.__setState(a.__states.PAUSED),a.emit('pause'),!0}))}},{key:'resume',value:function a(){return this.__promise?this.state===this.__states.STOPPED?Promise.resolve(!1):(this.__setState(this.__states.RESUMED),this.__isResumable&&(this.__isResumed=!0,this.__reqOptions.headers.range='bytes='+this.__downloaded+'-'),this.emit('resume',this.__isResumed),this.__start()):this.start()}},{key:'stop',value:function c(){var a=this;if(this.state===this.__states.STOPPED)return Promise.resolve(!0);var b=function(){return new Promise(function(b,c){fs.access(a.__filePath,function(d){return d?(a.__emitStop(),b(!0)):void fs.unlink(a.__filePath,function(d){return d?(a.__setState(a.__states.FAILED),a.emit('error',d),c(d)):void(a.__emitStop(),b(!0))})})})};return this.__requestAbort(),this.__closeFileStream().then(function(){return a.__opts.removeOnStop?b():(a.__emitStop(),Promise.resolve(!0))})}},{key:'pipe',value:function c(a){var b=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null;return this.__pipes.push({stream:a,options:b}),a}},{key:'unpipe',value:function d(){var a=this,b=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,c=function(b){return a.__response?a.__response.unpipe(b):b.unpipe()};if(b){var e=this.__pipes.find(function(a){return a.stream===b});return void(e&&(c(b),this.__pipes=this.__pipes.filter(function(a){return a.stream!==b})))}this.__pipes.forEach(function(a){return c(a.stream)}),this.__pipes=[]}},{key:'getDownloadPath',value:function a(){return this.__filePath}},{key:'isResumable',value:function a(){return this.__isResumable}},{key:'updateOptions',value:function c(a){var b=1<arguments.length&&void 0!==arguments[1]?arguments[1]:'';this.__opts=Object.assign({},this.__opts,a),this.__headers=this.__opts.headers,-1<this.__opts.timeout&&(this.__opts.httpRequestOptions.timeout=this.__opts.timeout,this.__opts.httpsRequestOptions.timeout=this.__opts.timeout),('number'!=typeof this.__opts.progressThrottle||0>this.__opts.progressThrottle)&&(this.__opts.progressThrottle=this.__defaultOpts.progressThrottle),this.url=b||this.url,this.__reqOptions=this.__getReqOptions(this.__opts.method,this.url,this.__opts.headers),this.__initProtocol(this.url)}},{key:'getOptions',value:function a(){return this.__opts}},{key:'getMetadata',value:function a(){return this.__opts.metadata}},{key:'getStats',value:function a(){return{total:this.__total,name:this.__fileName,downloaded:this.__downloaded,progress:this.__progress,speed:this.__statsEstimate.bytes}}},{key:'getTotalSize',value:function b(){var a=this;return new Promise(function(b,c){var d=function(b){a.__initProtocol(b);var c=Object.assign({},a.__headers);c.hasOwnProperty('range')&&delete c.range;var d=a.__getReqOptions('HEAD',b,c);return Object.assign({},a.__reqOptions,d)},e=function(f,g){var h=a.__protocol.request(g,function(g){if(a.__isRequireRedirect(g)){var h=/^https?:\\/\\//.test(g.headers.location)?g.headers.location:new _url.URL(g.headers.location,f).href;return a.emit('redirected',h,f),e(h,d(h))}return 200===g.statusCode?void b({name:a.__getFileNameFromHeaders(g.headers,g),total:parseInt(g.headers['content-length'])||null}):c(new Error('Response status was '+g.statusCode))});h.on('error',function(a){return c(a)}),h.on('timeout',function(){return c(new Error('timeout'))}),h.on('uncaughtException',function(a){return c(a)}),h.end()};e(a.url,d(a.url))})}},{key:'getResumeState',value:function a(){return{downloaded:this.__downloaded,filePath:this.__filePath,fileName:this.__fileName,total:this.__total}}},{key:'resumeFromFile',value:function d(a){var b=this,c=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};return this.__opts.override=!0,this.__filePath=a,(c.total&&c.fileName?Promise.resolve({name:c.fileName,total:c.total}):this.getTotalSize()).then(function(a){var d=a.name,e=a.total;return b.__total=c.total||e,b.__fileName=c.fileName||d,b.__downloaded=c.downloaded||b.__getFilesizeInBytes(b.__filePath),b.__reqOptions.headers.range='bytes='+b.__downloaded+'-',b.__isResumed=!0,b.__isResumable=!0,b.__setState(b.__states.RESUMED),b.emit('resume',b.__isResumed),new Promise(function(a,c){b.__promise={resolve:a,reject:c},b.__start()})})}},{key:'__start',value:function a(){this.__isRedirected||this.state===this.__states.RESUMED||(this.emit('start'),this.__setState(this.__states.STARTED),this.__initProtocol(this.url)),this.__response=null,this.__isAborted=!1,this.__request&&!this.__request.destroyed&&this.__request.destroy(),this.__retryTimeout&&(clearTimeout(this.__retryTimeout),this.__retryTimeout=null),this.__request=this.__downloadRequest(this.__promise.resolve,this.__promise.reject),this.__request.on('error',this.__onError(this.__promise.resolve,this.__promise.reject)),this.__request.on('timeout',this.__onTimeout(this.__promise.resolve,this.__promise.reject)),this.__request.on('uncaughtException',this.__onError(this.__promise.resolve,this.__promise.reject,!0)),this.__opts.body&&this.__request.write(this.__opts.body),this.__request.end()}},{key:'__resolvePending',value:function b(){if(this.__promise){var a=this.__promise.resolve;return this.__promise=null,a(!0)}}},{key:'__downloadRequest',value:function d(a,b){var c=this;return this.__protocol.request(this.__reqOptions,function(d){if(c.__response=d,c.__isResumed||(c.__total=parseInt(d.headers['content-length'])||null,c.__resetStats()),c.__isRequireRedirect(d)){var e=/^https?:\\/\\//.test(d.headers.location)?d.headers.location:new _url.URL(d.headers.location,c.url).href;return c.__isRedirected=!0,c.__initProtocol(e),c.emit('redirected',e,c.url),c.__start()}if(200!==d.statusCode&&206!==d.statusCode){var f=new Error('Response status was '+d.statusCode);return f.status=d.statusCode||0,f.body=d.body||'',c.__setState(c.__states.FAILED),c.emit('error',f),b(f)}c.__opts.forceResume?c.__isResumable=!0:d.headers.hasOwnProperty('accept-ranges')&&'none'!==d.headers['accept-ranges']&&(c.__isResumable=!0),c.__startDownload(d,a,b)})}},{key:'__startDownload',value:function h(a,b,c){var d=this,e=a;if(!this.__isResumed){var i=this.__getFileNameFromHeaders(a.headers);if(this.__filePath=this.__getFilePath(i),this.__fileName=this.__filePath.split(path.sep).pop(),fs.existsSync(this.__filePath)){var f=this.__getFilesizeInBytes(this.__filePath),g=this.__total?this.__total:0;if('object'===_typeof(this.__opts.override)&&this.__opts.override.skip&&(this.__opts.override.skipSmaller||f>=g))return this.emit('skip',{totalSize:this.__total,fileName:this.__fileName,filePath:this.__filePath,downloadedSize:f}),this.__setState(this.__states.SKIPPED),b(!0)}this.__fileStream=fs.createWriteStream(this.__filePath,{})}else this.__fileStream=fs.createWriteStream(this.__filePath,{flags:'a'});this.emit('download',{fileName:this.__fileName,filePath:this.__filePath,totalSize:this.__total,isResumed:this.__isResumed,downloadedSize:this.__downloaded}),this.__retryCount=0,this.__isResumed=!1,this.__isRedirected=!1,this.__setState(this.__states.DOWNLOADING),this.__statsEstimate.time=new Date,this.__statsEstimate.throttleTime=new Date,e.on('data',function(a){return d.__calculateStats(a.length)}),this.__pipes.forEach(function(a){e.pipe(a.stream,a.options),e=a.stream}),e.pipe(this.__fileStream),e.on('error',this.__onError(b,c)),this.__fileStream.on('finish',this.__onFinished(b,c)),this.__fileStream.on('error',this.__onError(b,c))}},{key:'__hasFinished',value:function a(){return!this.__isAborted&&-1===[this.__states.PAUSED,this.__states.STOPPED,this.__states.RETRY,this.__states.FAILED,this.__states.RESUMED].indexOf(this.state)}},{key:'__isRequireRedirect',value:function b(a){return 300<a.statusCode&&400>a.statusCode&&a.headers.hasOwnProperty('location')&&a.headers.location}},{key:'__onFinished',value:function d(a,b){var c=this;return function(){c.__fileStream.close(function(d){if(d)return b(d);if(c.__hasFinished()){var e=!!c.__total&&c.__downloaded!==c.__total;if(e&&c.__isResumable&&c.__opts.resumeOnIncomplete&&c.__resumeRetryCount<=c.__opts.resumeOnIncompleteMaxRetry)return c.__resumeRetryCount++,c.emit('warning',new Error('uncomplete download, retrying')),c.resume();c.__setState(c.__states.FINISHED),c.__pipes=[],c.emit('end',{fileName:c.__fileName,filePath:c.__filePath,totalSize:c.__total,incomplete:e,onDiskSize:c.__getFilesizeInBytes(c.__filePath),downloadedSize:c.__downloaded})}return a(c.__downloaded===c.__total)})}}},{key:'__closeFileStream',value:function b(){var a=this;return this.__fileStream?new Promise(function(b,c){a.__fileStream.close(function(a){return a?c(a):b(!0)})}):Promise.resolve(!0)}},{key:'__onError',value:function e(a,b){var c=this,d=!!(2<arguments.length&&void 0!==arguments[2])&&arguments[2];return function(a){return c.__pipes=[],d&&c.__requestAbort(),c.state===c.__states.STOPPED||c.state===c.__states.FAILED?void 0:c.__opts.retry?c.__retry(a).catch(function(d){c.__removeFile().finally(function(){c.__setState(c.__states.FAILED),c.emit('error',d?d:a),b(d?d:a)})}):c.__removeFile().finally(function(){c.__setState(c.__states.FAILED),c.emit('error',a),b(a)})}}},{key:'__retry',value:function h(){var a=this,b=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;if(!this.__opts.retry||'object'!==_typeof(this.__opts.retry))return Promise.reject(b||new Error('wrong retry options'));var c=this.__opts.retry,d=c.delay,e=void 0===d?0:d,f=c.maxRetries,g=void 0===f?999:f;return this.__retryCount>=g?Promise.reject(b||new Error('reached the maximum retries')):(this.__retryCount++,this.__setState(this.__states.RETRY),this.emit('retry',this.__retryCount,this.__opts.retry,b),this.__response&&(this.__response.unpipe(),this.__pipes.forEach(function(a){return a.stream.unpipe()})),this.__fileStream&&this.__fileStream.removeAllListeners(),this.__requestAbort(),this.__closeFileStream().then(function(){return new Promise(function(b){return a.__retryTimeout=setTimeout(function(){return b(0<a.__downloaded?a.resume():a.__start())},e)})}))}},{key:'__onTimeout',value:function d(a,b){var c=this;return function(){return c.__requestAbort(),c.__opts.retry?c.__retry(new Error('timeout')).catch(function(a){c.__removeFile().finally(function(){c.__setState(c.__states.FAILED),a?b(a):(c.emit('timeout'),b(new Error('timeout')))})}):c.__removeFile().finally(function(){c.__setState(c.__states.FAILED),c.emit('timeout'),b(new Error('timeout'))})}}},{key:'__resetStats',value:function a(){this.__retryCount=0,this.__downloaded=0,this.__progress=0,this.__resumeRetryCount=0,this.__statsEstimate={time:0,bytes:0,prevBytes:0,throttleTime:0}}},{key:'__getFileNameFromHeaders',value:function k(a,b){var c='',d=/.*filename\\*=.*?'.*?'([^\"].+?[^\"])(?:(?:;)|$)/i,e=/.*filename=\"(.*?)\";?/i,f=/.*filename=([^\"].+?[^\"])(?:(?:;)|$)/i,g=a.hasOwnProperty('content-disposition'),h=g?a['content-disposition'].match(d):null,i=!g||h?null:a['content-disposition'].match(e),j=!g||h||i?null:a['content-disposition'].match(f);return g&&(h||i||j)?(c=a['content-disposition'],c=c.trim(),h?c=h[1]:i?c=i[1]:j&&(c=j[1]),c=c.replace(/[/\\\\]/g,'')):0<path.basename(new _url.URL(this.requestURL).pathname).length?c=path.basename(new _url.URL(this.requestURL).pathname):c=new _url.URL(this.requestURL).hostname+'.html',this.__opts.fileName?this.__getFileNameFromOpts(c,b):c.replace(/\\.*$/,'')}},{key:'__getFilePath',value:function d(a){var b=path.join(this.__destFolder,a),c=b;return this.__opts.override||this.state===this.__states.RESUMED||(c=this.__uniqFileNameSync(c),b!==c&&this.emit('renamed',{path:c,fileName:c.split(path.sep).pop(),prevPath:b,prevFileName:b.split(path.sep).pop()})),c}},{key:'__getFileNameFromOpts',value:function g(a,b){if(!this.__opts.fileName)return a;if('string'==typeof this.__opts.fileName)return this.__opts.fileName;if('function'==typeof this.__opts.fileName){var h=path.join(this.__destFolder,a);return b&&b.headers||this.__response&&this.__response.headers?this.__opts.fileName(a,h,(b?b:this.__response).headers['content-type']):this.__opts.fileName(a,h)}if('object'===_typeof(this.__opts.fileName)){var c=this.__opts.fileName,d=c.name,e=!!c.hasOwnProperty('ext')&&c.ext;if('string'==typeof e)return d+'.'+e;if('boolean'==typeof e){if(e)return d;var f=a.includes('.')?a.split('.').pop():'';return''===f?d:d+'.'+f}}return a}},{key:'__calculateStats',value:function f(a){var b=new Date,c=b-this.__statsEstimate.time,d=b-this.__statsEstimate.throttleTime,e=this.__total||0;a&&(this.__downloaded+=a,this.__progress=0===e?0:100*(this.__downloaded/e),(this.__downloaded===e||1e3<c)&&(this.__statsEstimate.time=b,this.__statsEstimate.bytes=this.__downloaded-this.__statsEstimate.prevBytes,this.__statsEstimate.prevBytes=this.__downloaded),(this.__downloaded===e||d>this.__opts.progressThrottle)&&(this.__statsEstimate.throttleTime=b,this.emit('progress.throttled',this.getStats())),this.emit('progress',this.getStats()))}},{key:'__setState',value:function b(a){this.state=a,this.emit('stateChanged',this.state)}},{key:'__getReqOptions',value:function f(a,b){var c=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{},d=new _url.URL(b),e={protocol:d.protocol,host:d.hostname,port:d.port,path:d.pathname+d.search,method:a};return c&&(e.headers=c),e}},{key:'__getFilesizeInBytes',value:function d(a){try{var b=fs.statSync(a,{throwIfNoEntry:!1}),c=b.size||0;return c}catch(a){this.emit('warning',a)}return 0}},{key:'__validate',value:function d(a,b){if('string'!=typeof a)throw new Error('URL should be an string');if(''===a.trim())throw new Error('URL couldn\\'t be empty');if('string'!=typeof b)throw new Error('Destination Folder should be an string');if(''===b.trim())throw new Error('Destination Folder couldn\\'t be empty');if(!fs.existsSync(b))throw new Error('Destination Folder must exist');var c=fs.statSync(b);if(!c.isDirectory())throw new Error('Destination Folder must be a directory');try{fs.accessSync(b,fs.constants.W_OK)}catch(a){throw new Error('Destination Folder must be writable')}return!0}},{key:'__initProtocol',value:function c(a){var b=this.__getReqOptions(this.__opts.method,a,this.__headers);this.requestURL=a,-1<a.indexOf('https://')?(this.__protocol=https,b.agent=new https.Agent({keepAlive:!1}),this.__reqOptions=Object.assign({},b,this.__opts.httpsRequestOptions)):(this.__protocol=http,b.agent=new http.Agent({keepAlive:!1}),this.__reqOptions=Object.assign({},b,this.__opts.httpRequestOptions))}},{key:'__uniqFileNameSync',value:function f(a){if('string'!=typeof a||''===a)return a;try{fs.accessSync(a,fs.F_OK);var b=a.match(/(.*)(\\([0-9]+\\))(\\..*)$/),c=b?b[1].trim():a,d=b?parseInt(b[2].replace(/\\(|\\)/,'')):0,e=a.split('.').pop();return e!==a&&0<e.length?(e='.'+e,c=c.replace(e,'')):e='',this.__uniqFileNameSync(c+' ('+ ++d+')'+e)}catch(b){return a}}},{key:'__removeFile',value:function b(){var a=this;return new Promise(function(b){return a.__fileStream?void a.__fileStream.close(function(c){return c&&a.emit('warning',c),a.__opts.removeOnFail?fs.access(a.__filePath,function(d){return d?b():void fs.unlink(a.__filePath,function(d){d&&a.emit('warning',c),b()})}):void b()}):b()})}},{key:'__requestAbort',value:function a(){this.__isAborted=!0,this.__retryTimeout&&(clearTimeout(this.__retryTimeout),this.__retryTimeout=null),this.__response&&this.__response.destroy(),this.__request&&(this.__request.destroy?this.__request.destroy():this.__request.abort())}},{key:'__emitStop',value:function a(){this.__resolvePending(),this.__setState(this.__states.STOPPED),this.emit('stop')}}]),b}(_events.EventEmitter);","/**\n * The timeout to use for apt commands\n * Wait up to 300 seconds if the apt-get lock is held\n * @private Used internally\n */\nexport const aptTimeout = \"Dpkg::Lock::Timeout=300\";\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXB0LXRpbWVvdXQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvYXB0LXRpbWVvdXQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7Ozs7R0FJRztBQUVILE1BQU0sQ0FBQyxNQUFNLFVBQVUsR0FBRyx5QkFBeUIsQ0FBQSIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogVGhlIHRpbWVvdXQgdG8gdXNlIGZvciBhcHQgY29tbWFuZHNcbiAqIFdhaXQgdXAgdG8gMzAwIHNlY29uZHMgaWYgdGhlIGFwdC1nZXQgbG9jayBpcyBoZWxkXG4gKiBAcHJpdmF0ZSBVc2VkIGludGVybmFsbHlcbiAqL1xuXG5leHBvcnQgY29uc3QgYXB0VGltZW91dCA9IFwiRHBrZzo6TG9jazo6VGltZW91dD0zMDBcIlxuIl19","import { defaultExecOptions, execRootSync } from \"admina\";\nimport memoize from \"memoizee\";\nimport { getAptEnv } from \"./apt-env.js\";\nimport { aptTimeout } from \"./apt-timeout.js\";\nimport { getApt } from \"./get-apt.js\";\nexport let updatedRepos = false; // eslint-disable-line import/no-mutable-exports\n/**\n * Update the apt repositories\n * @param apt The apt command to use (optional)\n */\nexport function updateAptRepos(apt = getApt()) {\n execRootSync(apt, apt !== \"nala\" ? [\"update\", \"-y\", \"-o\", aptTimeout] : [\"update\", \"-o\", aptTimeout], { ...defaultExecOptions, env: getAptEnv(apt) });\n updatedRepos = true;\n}\n/**\n * Update the apt repositories (memoized)\n * @param apt The apt command to use (optional)\n */\nexport const updateAptReposMemoized = memoize(updateAptRepos);\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidXBkYXRlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vc3JjL3VwZGF0ZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsa0JBQWtCLEVBQUUsWUFBWSxFQUFFLE1BQU0sUUFBUSxDQUFBO0FBQ3pELE9B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bWVvdXQuanNcIlxuaW1wb3J0IHsgZ2V0QXB0IH0gZnJvbSBcIi4vZ2V0LWFwdC5qc1wiXG5cbmV4cG9ydCBsZXQgdXBkYXRlZFJlcG9zID0gZmFsc2UgLy8gZXNsaW50LWRpc2FibGUtbGluZSBpbXBvcnQvbm8tbXV0YWJsZS1leHBvcnRzXG5cbi8qKlxuICogVXBkYXRlIHRoZSBhcHQgcmVwb3NpdG9yaWVzXG4gKiBAcGFyYW0gYXB0IFRoZSBhcHQgY29tbWFuZCB0byB1c2UgKG9wdGlvbmFsKVxuICovXG5leHBvcnQgZnVuY3Rpb24gdXBkYXRlQXB0UmVwb3MoYXB0OiBzdHJpbmcgPSBnZXRBcHQoKSkge1xuICBleGVjUm9vdFN5bmMoXG4gICAgYXB0LFxuICAgIGFwdCAhPT0gXCJuYWxhXCIgPyBbXCJ1cGRhdGVcIiwgXCIteVwiLCBcIi1vXCIsIGFwdFRpbWVvdXRdIDogW1widXBkYXRlXCIsIFwiLW9cIiwgYXB0VGltZW91dF0sXG4gICAgeyAuLi5kZWZhdWx0RXhlY09wdGlvbnMsIGVudjogZ2V0QXB0RW52KGFwdCkgfSxcbiAgKVxuXG4gIHVwZGF0ZWRSZXBvcyA9IHRydWVcbn1cblxuLyoqXG4gKiBVcGRhdGUgdGhlIGFwdCByZXBvc2l0b3JpZXMgKG1lbW9pemVkKVxuICogQHBhcmFtIGFwdCBUaGUgYXB0IGNvbW1hbmQgdG8gdXNlIChvcHRpb25hbClcbiAqL1xuZXhwb3J0IGNvbnN0IHVwZGF0ZUFwdFJlcG9zTWVtb2l6ZWQgPSBtZW1vaXplKHVwZGF0ZUFwdFJlcG9zKVxuIl19","import { defaultExecOptions, execRootSync } from \"admina\";\nimport memoize from \"memoizee\";\nimport { getAptEnv } from \"./apt-env.js\";\nimport { aptTimeout } from \"./apt-timeout.js\";\nimport { filterAndQualifyAptPackages } from \"./qualify-install.js\";\nimport { updateAptReposMemoized } from \"./update.js\";\n/** Install gnupg and certificates (usually missing from docker containers) */\nexport async function initApt(apt) {\n // Update the repos\n updateAptReposMemoized(apt);\n const toInstall = await filterAndQualifyAptPackages([\n { name: \"ca-certificates\" },\n { name: \"gnupg\" },\n { name: \"apt-utils\" },\n ], apt);\n if (toInstall.length !== 0) {\n execRootSync(apt, [\"install\", \"-y\", \"--fix-broken\", \"-o\", aptTimeout, ...toInstall], {\n ...defaultExecOptions,\n env: getAptEnv(apt),\n });\n }\n}\n/** Install gnupg and certificates (usually missing from docker containers) (memoized) */\nexport const initAptMemoized = memoize(initApt, { promise: true });\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5pdC1hcHQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvaW5pdC1hcHQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLGtCQUFrQixFQUFFLFlBQVksRUFBRSxNQUFNLFFBQVEsQ0FBQTtBQUN6RCxPQUFPLE9BQU8sTUFBTSxVQUFVLENBQUE7QUFDOUIsT0FBTyxFQUFFLFNBQVMsRUFBRSxNQUFNLGNBQWMsQ0FBQTtBQUN4QyxPQUFPLEVBQUUsVUFBVSxFQUFFLE1BQU0sa0JBQWtCLENBQUE7QUFDN0MsT0FBTyxFQUFFLDJCQUEyQixFQUFFLE1BQU0sc0JBQXNCLENBQUE7QUFDbEUsT0FBTyxFQUFFLHNCQUFzQixFQUFFLE1BQU0sYUFBYSxDQUFBO0FBRXBELDhFQUE4RTtBQUM5RSxNQUFNLENBQUMsS0FBSyxVQUFVLE9BQU8sQ0FBQyxHQUFXO0lBQ3ZDLG1CQUFtQjtJQUNuQixzQkFBc0IsQ0FBQyxHQUFHLENBQUMsQ0FBQTtJQUUzQixNQUFNLFNBQVMsR0FBRyxNQUFNLDJCQUEyQixDQUFDO1FBQ2xELEVBQUUsSUFBSSxFQUFFLGlCQUFpQixFQUFFO1FBQzNCLEVBQUUsSU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yb20gZG9ja2VyIGNvbnRhaW5lcnMpICovXG5leHBvcnQgYXN5bmMgZnVuY3Rpb24gaW5pdEFwdChhcHQ6IHN0cmluZykge1xuICAvLyBVcGRhdGUgdGhlIHJlcG9zXG4gIHVwZGF0ZUFwdFJlcG9zTWVtb2l6ZWQoYXB0KVxuXG4gIGNvbnN0IHRvSW5zdGFsbCA9IGF3YWl0IGZpbHRlckFuZFF1YWxpZnlBcHRQYWNrYWdlcyhbXG4gICAgeyBuYW1lOiBcImNhLWNlcnRpZmljYXRlc1wiIH0sXG4gICAgeyBuYW1lOiBcImdudXBnXCIgfSxcbiAgICB7IG5hbWU6IFwiYXB0LXV0aWxzXCIgfSxcbiAgXSwgYXB0KVxuXG4gIGlmICh0b0luc3RhbGwubGVuZ3RoICE9PSAwKSB7XG4gICAgZXhlY1Jvb3RTeW5jKGFwdCwgW1wiaW5zdGFsbFwiLCBcIi15XCIsIFwiLS1maXgtYnJva2VuXCIsIFwiLW9cIiwgYXB0VGltZW91dCwgLi4udG9JbnN0YWxsXSwge1xuICAgICAgLi4uZGVmYXVsdEV4ZWNPcHRpb25zLFxuICAgICAgZW52OiBnZXRBcHRFbnYoYXB0KSxcbiAgICB9KVxuICB9XG59XG5cbi8qKiBJbnN0YWxsIGdudXBnIGFuZCBjZXJ0aWZpY2F0ZXMgKHVzdWFsbHkgbWlzc2luZyBmcm9tIGRvY2tlciBjb250YWluZXJzKSAobWVtb2l6ZWQpICovXG5leHBvcnQgY29uc3QgaW5pdEFwdE1lbW9pemVkID0gbWVtb2l6ZShpbml0QXB0LCB7IHByb21pc2U6IHRydWUgfSlcbiJdfQ==","'use strict';\n\nvar path = require('path');\n\nfunction replaceExt(npath, ext) {\n if (typeof npath !== 'string') {\n return npath;\n }\n\n if (npath.length === 0) {\n return npath;\n }\n\n var nFileName = path.basename(npath, path.extname(npath)) + ext;\n var nFilepath = path.join(path.dirname(npath), nFileName);\n\n // Because `path.join` removes the head './' from the given path.\n // This removal can cause a problem when passing the result to `require` or\n // `import`.\n if (startsWithSingleDot(npath)) {\n return '.' + path.sep + nFilepath;\n }\n\n return nFilepath;\n}\n\nfunction startsWithSingleDot(fpath) {\n var first2chars = fpath.slice(0, 2);\n return first2chars === '.' + path.sep || first2chars === './';\n}\n\nmodule.exports = replaceExt;\n","export const x86_64 = [\"x64\", \"amd64\", \"x86_64\", \"win64\", \"64\", \"amd64_x86\"]\nexport const x86 = [\"x86\", \"i386\", \"ia32\", \"win32\", \"32\", \"x32\"]\nexport const arm64 = [\"aarch64\", \"arm64\", \"woa64\", \"arm\"]\nexport const armv7 = [\"armv7\", \"armv7a\"]\nexport const powerpc64le = [\"powerpc64le\", \"ppc64le\"]\nexport const sparc64 = [\"sparc64\"]\n","exports = module.exports = SemVer\n\nvar debug\n/* istanbul ignore next */\nif (typeof process === 'object' &&\n process.env &&\n process.env.NODE_DEBUG &&\n /\\bsemver\\b/i.test(process.env.NODE_DEBUG)) {\n debug = function () {\n var args = Array.prototype.slice.call(arguments, 0)\n args.unshift('SEMVER')\n console.log.apply(console, args)\n }\n} else {\n debug = function () {}\n}\n\n// Note: this is the semver.org version of the spec that it implements\n// Not necessarily the package version of this code.\nexports.SEMVER_SPEC_VERSION = '2.0.0'\n\nvar MAX_LENGTH = 256\nvar MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER ||\n /* istanbul ignore next */ 9007199254740991\n\n// Max safe segment length for coercion.\nvar MAX_SAFE_COMPONENT_LENGTH = 16\n\nvar MAX_SAFE_BUILD_LENGTH = MAX_LENGTH - 6\n\n// The actual regexps go on exports.re\nvar re = exports.re = []\nvar safeRe = exports.safeRe = []\nvar src = exports.src = []\nvar t = exports.tokens = {}\nvar R = 0\n\nfunction tok (n) {\n t[n] = R++\n}\n\nvar LETTERDASHNUMBER = '[a-zA-Z0-9-]'\n\n// Replace some greedy regex tokens to prevent regex dos issues. These regex are\n// used internally via the safeRe object since all inputs in this library get\n// normalized first to trim and collapse all extra whitespace. The original\n// regexes are exported for userland consumption and lower level usage. A\n// future breaking change could export the safer regex only with a note that\n// all input should have extra whitespace removed.\nvar safeRegexReplacements = [\n ['\\\\s', 1],\n ['\\\\d', MAX_LENGTH],\n [LETTERDASHNUMBER, MAX_SAFE_BUILD_LENGTH],\n]\n\nfunction makeSafeRe (value) {\n for (var i = 0; i < safeRegexReplacements.length; i++) {\n var token = safeRegexReplacements[i][0]\n var max = safeRegexReplacements[i][1]\n value = value\n .split(token + '*').join(token + '{0,' + max + '}')\n .split(token + '+').join(token + '{1,' + max + '}')\n }\n return value\n}\n\n// The following Regular Expressions can be used for tokenizing,\n// validating, and parsing SemVer version strings.\n\n// ## Numeric Identifier\n// A single `0`, or a non-zero digit followed by zero or more digits.\n\ntok('NUMERICIDENTIFIER')\nsrc[t.NUMERICIDENTIFIER] = '0|[1-9]\\\\d*'\ntok('NUMERICIDENTIFIERLOOSE')\nsrc[t.NUMERICIDENTIFIERLOOSE] = '\\\\d+'\n\n// ## Non-numeric Identifier\n// Zero or more digits, followed by a letter or hyphen, and then zero or\n// more letters, digits, or hyphens.\n\ntok('NONNUMERICIDENTIFIER')\nsrc[t.NONNUMERICIDENTIFIER] = '\\\\d*[a-zA-Z-]' + LETTERDASHNUMBER + '*'\n\n// ## Main Version\n// Three dot-separated numeric identifiers.\n\ntok('MAINVERSION')\nsrc[t.MAINVERSION] = '(' + src[t.NUMERICIDENTIFIER] + ')\\\\.' +\n '(' + src[t.NUMERICIDENTIFIER] + ')\\\\.' +\n '(' + src[t.NUMERICIDENTIFIER] + ')'\n\ntok('MAINVERSIONLOOSE')\nsrc[t.MAINVERSIONLOOSE] = '(' + src[t.NUMERICIDENTIFIERLOOSE] + ')\\\\.' +\n '(' + src[t.NUMERICIDENTIFIERLOOSE] + ')\\\\.' +\n '(' + src[t.NUMERICIDENTIFIERLOOSE] + ')'\n\n// ## Pre-release Version Identifier\n// A numeric identifier, or a non-numeric identifier.\n\ntok('PRERELEASEIDENTIFIER')\nsrc[t.PRERELEASEIDENTIFIER] = '(?:' + src[t.NUMERICIDENTIFIER] +\n '|' + src[t.NONNUMERICIDENTIFIER] + ')'\n\ntok('PRERELEASEIDENTIFIERLOOSE')\nsrc[t.PRERELEASEIDENTIFIERLOOSE] = '(?:' + src[t.NUMERICIDENTIFIERLOOSE] +\n '|' + src[t.NONNUMERICIDENTIFIER] + ')'\n\n// ## Pre-release Version\n// Hyphen, followed by one or more dot-separated pre-release version\n// identifiers.\n\ntok('PRERELEASE')\nsrc[t.PRERELEASE] = '(?:-(' + src[t.PRERELEASEIDENTIFIER] +\n '(?:\\\\.' + src[t.PRERELEASEIDENTIFIER] + ')*))'\n\ntok('PRERELEASELOOSE')\nsrc[t.PRERELEASELOOSE] = '(?:-?(' + src[t.PRERELEASEIDENTIFIERLOOSE] +\n '(?:\\\\.' + src[t.PRERELEASEIDENTIFIERLOOSE] + ')*))'\n\n// ## Build Metadata Identifier\n// Any combination of digits, letters, or hyphens.\n\ntok('BUILDIDENTIFIER')\nsrc[t.BUILDIDENTIFIER] = LETTERDASHNUMBER + '+'\n\n// ## Build Metadata\n// Plus sign, followed by one or more period-separated build metadata\n// identifiers.\n\ntok('BUILD')\nsrc[t.BUILD] = '(?:\\\\+(' + src[t.BUILDIDENTIFIER] +\n '(?:\\\\.' + src[t.BUILDIDENTIFIER] + ')*))'\n\n// ## Full Version String\n// A main version, followed optionally by a pre-release version and\n// build metadata.\n\n// Note that the only major, minor, patch, and pre-release sections of\n// the version string are capturing groups. The build metadata is not a\n// capturing group, because it should not ever be used in version\n// comparison.\n\ntok('FULL')\ntok('FULLPLAIN')\nsrc[t.FULLPLAIN] = 'v?' + src[t.MAINVERSION] +\n src[t.PRERELEASE] + '?' +\n src[t.BUILD] + '?'\n\nsrc[t.FULL] = '^' + src[t.FULLPLAIN] + '$'\n\n// like full, but allows v1.2.3 and =1.2.3, which people do sometimes.\n// also, 1.0.0alpha1 (prerelease without the hyphen) which is pretty\n// common in the npm registry.\ntok('LOOSEPLAIN')\nsrc[t.LOOSEPLAIN] = '[v=\\\\s]*' + src[t.MAINVERSIONLOOSE] +\n src[t.PRERELEASELOOSE] + '?' +\n src[t.BUILD] + '?'\n\ntok('LOOSE')\nsrc[t.LOOSE] = '^' + src[t.LOOSEPLAIN] + '$'\n\ntok('GTLT')\nsrc[t.GTLT] = '((?:<|>)?=?)'\n\n// Something like \"2.*\" or \"1.2.x\".\n// Note that \"x.x\" is a valid xRange identifer, meaning \"any version\"\n// Only the first item is strictly required.\ntok('XRANGEIDENTIFIERLOOSE')\nsrc[t.XRANGEIDENTIFIERLOOSE] = src[t.NUMERICIDENTIFIERLOOSE] + '|x|X|\\\\*'\ntok('XRANGEIDENTIFIER')\nsrc[t.XRANGEIDENTIFIER] = src[t.NUMERICIDENTIFIER] + '|x|X|\\\\*'\n\ntok('XRANGEPLAIN')\nsrc[t.XRANGEPLAIN] = '[v=\\\\s]*(' + src[t.XRANGEIDENTIFIER] + ')' +\n '(?:\\\\.(' + src[t.XRANGEIDENTIFIER] + ')' +\n '(?:\\\\.(' + src[t.XRANGEIDENTIFIER] + ')' +\n '(?:' + src[t.PRERELEASE] + ')?' +\n src[t.BUILD] + '?' +\n ')?)?'\n\ntok('XRANGEPLAINLOOSE')\nsrc[t.XRANGEPLAINLOOSE] = '[v=\\\\s]*(' + src[t.XRANGEIDENTIFIERLOOSE] + ')' +\n '(?:\\\\.(' + src[t.XRANGEIDENTIFIERLOOSE] + ')' +\n '(?:\\\\.(' + src[t.XRANGEIDENTIFIERLOOSE] + ')' +\n '(?:' + src[t.PRERELEASELOOSE] + ')?' +\n src[t.BUILD] + '?' +\n ')?)?'\n\ntok('XRANGE')\nsrc[t.XRANGE] = '^' + src[t.GTLT] + '\\\\s*' + src[t.XRANGEPLAIN] + '$'\ntok('XRANGELOOSE')\nsrc[t.XRANGELOOSE] = '^' + src[t.GTLT] + '\\\\s*' + src[t.XRANGEPLAINLOOSE] + '$'\n\n// Coercion.\n// Extract anything that could conceivably be a part of a valid semver\ntok('COERCE')\nsrc[t.COERCE] = '(^|[^\\\\d])' +\n '(\\\\d{1,' + MAX_SAFE_COMPONENT_LENGTH + '})' +\n '(?:\\\\.(\\\\d{1,' + MAX_SAFE_COMPONENT_LENGTH + '}))?' +\n '(?:\\\\.(\\\\d{1,' + MAX_SAFE_COMPONENT_LENGTH + '}))?' +\n '(?:$|[^\\\\d])'\ntok('COERCERTL')\nre[t.COERCERTL] = new RegExp(src[t.COERCE], 'g')\nsafeRe[t.COERCERTL] = new RegExp(makeSafeRe(src[t.COERCE]), 'g')\n\n// Tilde ranges.\n// Meaning is \"reasonably at or greater than\"\ntok('LONETILDE')\nsrc[t.LONETILDE] = '(?:~>?)'\n\ntok('TILDETRIM')\nsrc[t.TILDETRIM] = '(\\\\s*)' + src[t.LONETILDE] + '\\\\s+'\nre[t.TILDETRIM] = new RegExp(src[t.TILDETRIM], 'g')\nsafeRe[t.TILDETRIM] = new RegExp(makeSafeRe(src[t.TILDETRIM]), 'g')\nvar tildeTrimReplace = '$1~'\n\ntok('TILDE')\nsrc[t.TILDE] = '^' + src[t.LONETILDE] + src[t.XRANGEPLAIN] + '$'\ntok('TILDELOOSE')\nsrc[t.TILDELOOSE] = '^' + src[t.LONETILDE] + src[t.XRANGEPLAINLOOSE] + '$'\n\n// Caret ranges.\n// Meaning is \"at least and backwards compatible with\"\ntok('LONECARET')\nsrc[t.LONECARET] = '(?:\\\\^)'\n\ntok('CARETTRIM')\nsrc[t.CARETTRIM] = '(\\\\s*)' + src[t.LONECARET] + '\\\\s+'\nre[t.CARETTRIM] = new RegExp(src[t.CARETTRIM], 'g')\nsafeRe[t.CARETTRIM] = new RegExp(makeSafeRe(src[t.CARETTRIM]), 'g')\nvar caretTrimReplace = '$1^'\n\ntok('CARET')\nsrc[t.CARET] = '^' + src[t.LONECARET] + src[t.XRANGEPLAIN] + '$'\ntok('CARETLOOSE')\nsrc[t.CARETLOOSE] = '^' + src[t.LONECARET] + src[t.XRANGEPLAINLOOSE] + '$'\n\n// A simple gt/lt/eq thing, or just \"\" to indicate \"any version\"\ntok('COMPARATORLOOSE')\nsrc[t.COMPARATORLOOSE] = '^' + src[t.GTLT] + '\\\\s*(' + src[t.LOOSEPLAIN] + ')$|^$'\ntok('COMPARATOR')\nsrc[t.COMPARATOR] = '^' + src[t.GTLT] + '\\\\s*(' + src[t.FULLPLAIN] + ')$|^$'\n\n// An expression to strip any whitespace between the gtlt and the thing\n// it modifies, so that `> 1.2.3` ==> `>1.2.3`\ntok('COMPARATORTRIM')\nsrc[t.COMPARATORTRIM] = '(\\\\s*)' + src[t.GTLT] +\n '\\\\s*(' + src[t.LOOSEPLAIN] + '|' + src[t.XRANGEPLAIN] + ')'\n\n// this one has to use the /g flag\nre[t.COMPARATORTRIM] = new RegExp(src[t.COMPARATORTRIM], 'g')\nsafeRe[t.COMPARATORTRIM] = new RegExp(makeSafeRe(src[t.COMPARATORTRIM]), 'g')\nvar comparatorTrimReplace = '$1$2$3'\n\n// Something like `1.2.3 - 1.2.4`\n// Note that these all use the loose form, because they'll be\n// checked against either the strict or loose comparator form\n// later.\ntok('HYPHENRANGE')\nsrc[t.HYPHENRANGE] = '^\\\\s*(' + src[t.XRANGEPLAIN] + ')' +\n '\\\\s+-\\\\s+' +\n '(' + src[t.XRANGEPLAIN] + ')' +\n '\\\\s*$'\n\ntok('HYPHENRANGELOOSE')\nsrc[t.HYPHENRANGELOOSE] = '^\\\\s*(' + src[t.XRANGEPLAINLOOSE] + ')' +\n '\\\\s+-\\\\s+' +\n '(' + src[t.XRANGEPLAINLOOSE] + ')' +\n '\\\\s*$'\n\n// Star ranges basically just allow anything at all.\ntok('STAR')\nsrc[t.STAR] = '(<|>)?=?\\\\s*\\\\*'\n\n// Compile to actual regexp objects.\n// All are flag-free, unless they were created above with a flag.\nfor (var i = 0; i < R; i++) {\n debug(i, src[i])\n if (!re[i]) {\n re[i] = new RegExp(src[i])\n\n // Replace all greedy whitespace to prevent regex dos issues. These regex are\n // used internally via the safeRe object since all inputs in this library get\n // normalized first to trim and collapse all extra whitespace. The original\n // regexes are exported for userland consumption and lower level usage. A\n // future breaking change could export the safer regex only with a note that\n // all input should have extra whitespace removed.\n safeRe[i] = new RegExp(makeSafeRe(src[i]))\n }\n}\n\nexports.parse = parse\nfunction parse (version, options) {\n if (!options || typeof options !== 'object') {\n options = {\n loose: !!options,\n includePrerelease: false\n }\n }\n\n if (version instanceof SemVer) {\n return version\n }\n\n if (typeof version !== 'string') {\n return null\n }\n\n if (version.length > MAX_LENGTH) {\n return null\n }\n\n var r = options.loose ? safeRe[t.LOOSE] : safeRe[t.FULL]\n if (!r.test(version)) {\n return null\n }\n\n try {\n return new SemVer(version, options)\n } catch (er) {\n return null\n }\n}\n\nexports.valid = valid\nfunction valid (version, options) {\n var v = parse(version, options)\n return v ? v.version : null\n}\n\nexports.clean = clean\nfunction clean (version, options) {\n var s = parse(version.trim().replace(/^[=v]+/, ''), options)\n return s ? s.version : null\n}\n\nexports.SemVer = SemVer\n\nfunction SemVer (version, options) {\n if (!options || typeof options !== 'object') {\n options = {\n loose: !!options,\n includePrerelease: false\n }\n }\n if (version instanceof SemVer) {\n if (version.loose === options.loose) {\n return version\n } else {\n version = version.version\n }\n } else if (typeof version !== 'string') {\n throw new TypeError('Invalid Version: ' + version)\n }\n\n if (version.length > MAX_LENGTH) {\n throw new TypeError('version is longer than ' + MAX_LENGTH + ' characters')\n }\n\n if (!(this instanceof SemVer)) {\n return new SemVer(version, options)\n }\n\n debug('SemVer', version, options)\n this.options = options\n this.loose = !!options.loose\n\n var m = version.trim().match(options.loose ? safeRe[t.LOOSE] : safeRe[t.FULL])\n\n if (!m) {\n throw new TypeError('Invalid Version: ' + version)\n }\n\n this.raw = version\n\n // these are actually numbers\n this.major = +m[1]\n this.minor = +m[2]\n this.patch = +m[3]\n\n if (this.major > MAX_SAFE_INTEGER || this.major < 0) {\n throw new TypeError('Invalid major version')\n }\n\n if (this.minor > MAX_SAFE_INTEGER || this.minor < 0) {\n throw new TypeError('Invalid minor version')\n }\n\n if (this.patch > MAX_SAFE_INTEGER || this.patch < 0) {\n throw new TypeError('Invalid patch version')\n }\n\n // numberify any prerelease numeric ids\n if (!m[4]) {\n this.prerelease = []\n } else {\n this.prerelease = m[4].split('.').map(function (id) {\n if (/^[0-9]+$/.test(id)) {\n var num = +id\n if (num >= 0 && num < MAX_SAFE_INTEGER) {\n return num\n }\n }\n return id\n })\n }\n\n this.build = m[5] ? m[5].split('.') : []\n this.format()\n}\n\nSemVer.prototype.format = function () {\n this.version = this.major + '.' + this.minor + '.' + this.patch\n if (this.prerelease.length) {\n this.version += '-' + this.prerelease.join('.')\n }\n return this.version\n}\n\nSemVer.prototype.toString = function () {\n return this.version\n}\n\nSemVer.prototype.compare = function (other) {\n debug('SemVer.compare', this.version, this.options, other)\n if (!(other instanceof SemVer)) {\n other = new SemVer(other, this.options)\n }\n\n return this.compareMain(other) || this.comparePre(other)\n}\n\nSemVer.prototype.compareMain = function (other) {\n if (!(other instanceof SemVer)) {\n other = new SemVer(other, this.options)\n }\n\n return compareIdentifiers(this.major, other.major) ||\n compareIdentifiers(this.minor, other.minor) ||\n compareIdentifiers(this.patch, other.patch)\n}\n\nSemVer.prototype.comparePre = function (other) {\n if (!(other instanceof SemVer)) {\n other = new SemVer(other, this.options)\n }\n\n // NOT having a prerelease is > having one\n if (this.prerelease.length && !other.prerelease.length) {\n return -1\n } else if (!this.prerelease.length && other.prerelease.length) {\n return 1\n } else if (!this.prerelease.length && !other.prerelease.length) {\n return 0\n }\n\n var i = 0\n do {\n var a = this.prerelease[i]\n var b = other.prerelease[i]\n debug('prerelease compare', i, a, b)\n if (a === undefined && b === undefined) {\n return 0\n } else if (b === undefined) {\n return 1\n } else if (a === undefined) {\n return -1\n } else if (a === b) {\n continue\n } else {\n return compareIdentifiers(a, b)\n }\n } while (++i)\n}\n\nSemVer.prototype.compareBuild = function (other) {\n if (!(other instanceof SemVer)) {\n other = new SemVer(other, this.options)\n }\n\n var i = 0\n do {\n var a = this.build[i]\n var b = other.build[i]\n debug('prerelease compare', i, a, b)\n if (a === undefined && b === undefined) {\n return 0\n } else if (b === undefined) {\n return 1\n } else if (a === undefined) {\n return -1\n } else if (a === b) {\n continue\n } else {\n return compareIdentifiers(a, b)\n }\n } while (++i)\n}\n\n// preminor will bump the version up to the next minor release, and immediately\n// down to pre-release. premajor and prepatch work the same way.\nSemVer.prototype.inc = function (release, identifier) {\n switch (release) {\n case 'premajor':\n this.prerelease.length = 0\n this.patch = 0\n this.minor = 0\n this.major++\n this.inc('pre', identifier)\n break\n case 'preminor':\n this.prerelease.length = 0\n this.patch = 0\n this.minor++\n this.inc('pre', identifier)\n break\n case 'prepatch':\n // If this is already a prerelease, it will bump to the next version\n // drop any prereleases that might already exist, since they are not\n // relevant at this point.\n this.prerelease.length = 0\n this.inc('patch', identifier)\n this.inc('pre', identifier)\n break\n // If the input is a non-prerelease version, this acts the same as\n // prepatch.\n case 'prerelease':\n if (this.prerelease.length === 0) {\n this.inc('patch', identifier)\n }\n this.inc('pre', identifier)\n break\n\n case 'major':\n // If this is a pre-major version, bump up to the same major version.\n // Otherwise increment major.\n // 1.0.0-5 bumps to 1.0.0\n // 1.1.0 bumps to 2.0.0\n if (this.minor !== 0 ||\n this.patch !== 0 ||\n this.prerelease.length === 0) {\n this.major++\n }\n this.minor = 0\n this.patch = 0\n this.prerelease = []\n break\n case 'minor':\n // If this is a pre-minor version, bump up to the same minor version.\n // Otherwise increment minor.\n // 1.2.0-5 bumps to 1.2.0\n // 1.2.1 bumps to 1.3.0\n if (this.patch !== 0 || this.prerelease.length === 0) {\n this.minor++\n }\n this.patch = 0\n this.prerelease = []\n break\n case 'patch':\n // If this is not a pre-release version, it will increment the patch.\n // If it is a pre-release it will bump up to the same patch version.\n // 1.2.0-5 patches to 1.2.0\n // 1.2.0 patches to 1.2.1\n if (this.prerelease.length === 0) {\n this.patch++\n }\n this.prerelease = []\n break\n // This probably shouldn't be used publicly.\n // 1.0.0 \"pre\" would become 1.0.0-0 which is the wrong direction.\n case 'pre':\n if (this.prerelease.length === 0) {\n this.prerelease = [0]\n } else {\n var i = this.prerelease.length\n while (--i >= 0) {\n if (typeof this.prerelease[i] === 'number') {\n this.prerelease[i]++\n i = -2\n }\n }\n if (i === -1) {\n // didn't increment anything\n this.prerelease.push(0)\n }\n }\n if (identifier) {\n // 1.2.0-beta.1 bumps to 1.2.0-beta.2,\n // 1.2.0-beta.fooblz or 1.2.0-beta bumps to 1.2.0-beta.0\n if (this.prerelease[0] === identifier) {\n if (isNaN(this.prerelease[1])) {\n this.prerelease = [identifier, 0]\n }\n } else {\n this.prerelease = [identifier, 0]\n }\n }\n break\n\n default:\n throw new Error('invalid increment argument: ' + release)\n }\n this.format()\n this.raw = this.version\n return this\n}\n\nexports.inc = inc\nfunction inc (version, release, loose, identifier) {\n if (typeof (loose) === 'string') {\n identifier = loose\n loose = undefined\n }\n\n try {\n return new SemVer(version, loose).inc(release, identifier).version\n } catch (er) {\n return null\n }\n}\n\nexports.diff = diff\nfunction diff (version1, version2) {\n if (eq(version1, version2)) {\n return null\n } else {\n var v1 = parse(version1)\n var v2 = parse(version2)\n var prefix = ''\n if (v1.prerelease.length || v2.prerelease.length) {\n prefix = 'pre'\n var defaultResult = 'prerelease'\n }\n for (var key in v1) {\n if (key === 'major' || key === 'minor' || key === 'patch') {\n if (v1[key] !== v2[key]) {\n return prefix + key\n }\n }\n }\n return defaultResult // may be undefined\n }\n}\n\nexports.compareIdentifiers = compareIdentifiers\n\nvar numeric = /^[0-9]+$/\nfunction compareIdentifiers (a, b) {\n var anum = numeric.test(a)\n var bnum = numeric.test(b)\n\n if (anum && bnum) {\n a = +a\n b = +b\n }\n\n return a === b ? 0\n : (anum && !bnum) ? -1\n : (bnum && !anum) ? 1\n : a < b ? -1\n : 1\n}\n\nexports.rcompareIdentifiers = rcompareIdentifiers\nfunction rcompareIdentifiers (a, b) {\n return compareIdentifiers(b, a)\n}\n\nexports.major = major\nfunction major (a, loose) {\n return new SemVer(a, loose).major\n}\n\nexports.minor = minor\nfunction minor (a, loose) {\n return new SemVer(a, loose).minor\n}\n\nexports.patch = patch\nfunction patch (a, loose) {\n return new SemVer(a, loose).patch\n}\n\nexports.compare = compare\nfunction compare (a, b, loose) {\n return new SemVer(a, loose).compare(new SemVer(b, loose))\n}\n\nexports.compareLoose = compareLoose\nfunction compareLoose (a, b) {\n return compare(a, b, true)\n}\n\nexports.compareBuild = compareBuild\nfunction compareBuild (a, b, loose) {\n var versionA = new SemVer(a, loose)\n var versionB = new SemVer(b, loose)\n return versionA.compare(versionB) || versionA.compareBuild(versionB)\n}\n\nexports.rcompare = rcompare\nfunction rcompare (a, b, loose) {\n return compare(b, a, loose)\n}\n\nexports.sort = sort\nfunction sort (list, loose) {\n return list.sort(function (a, b) {\n return exports.compareBuild(a, b, loose)\n })\n}\n\nexports.rsort = rsort\nfunction rsort (list, loose) {\n return list.sort(function (a, b) {\n return exports.compareBuild(b, a, loose)\n })\n}\n\nexports.gt = gt\nfunction gt (a, b, loose) {\n return compare(a, b, loose) > 0\n}\n\nexports.lt = lt\nfunction lt (a, b, loose) {\n return compare(a, b, loose) < 0\n}\n\nexports.eq = eq\nfunction eq (a, b, loose) {\n return compare(a, b, loose) === 0\n}\n\nexports.neq = neq\nfunction neq (a, b, loose) {\n return compare(a, b, loose) !== 0\n}\n\nexports.gte = gte\nfunction gte (a, b, loose) {\n return compare(a, b, loose) >= 0\n}\n\nexports.lte = lte\nfunction lte (a, b, loose) {\n return compare(a, b, loose) <= 0\n}\n\nexports.cmp = cmp\nfunction cmp (a, op, b, loose) {\n switch (op) {\n case '===':\n if (typeof a === 'object')\n a = a.version\n if (typeof b === 'object')\n b = b.version\n return a === b\n\n case '!==':\n if (typeof a === 'object')\n a = a.version\n if (typeof b === 'object')\n b = b.version\n return a !== b\n\n case '':\n case '=':\n case '==':\n return eq(a, b, loose)\n\n case '!=':\n return neq(a, b, loose)\n\n case '>':\n return gt(a, b, loose)\n\n case '>=':\n return gte(a, b, loose)\n\n case '<':\n return lt(a, b, loose)\n\n case '<=':\n return lte(a, b, loose)\n\n default:\n throw new TypeError('Invalid operator: ' + op)\n }\n}\n\nexports.Comparator = Comparator\nfunction Comparator (comp, options) {\n if (!options || typeof options !== 'object') {\n options = {\n loose: !!options,\n includePrerelease: false\n }\n }\n\n if (comp instanceof Comparator) {\n if (comp.loose === !!options.loose) {\n return comp\n } else {\n comp = comp.value\n }\n }\n\n if (!(this instanceof Comparator)) {\n return new Comparator(comp, options)\n }\n\n comp = comp.trim().split(/\\s+/).join(' ')\n debug('comparator', comp, options)\n this.options = options\n this.loose = !!options.loose\n this.parse(comp)\n\n if (this.semver === ANY) {\n this.value = ''\n } else {\n this.value = this.operator + this.semver.version\n }\n\n debug('comp', this)\n}\n\nvar ANY = {}\nComparator.prototype.parse = function (comp) {\n var r = this.options.loose ? safeRe[t.COMPARATORLOOSE] : safeRe[t.COMPARATOR]\n var m = comp.match(r)\n\n if (!m) {\n throw new TypeError('Invalid comparator: ' + comp)\n }\n\n this.operator = m[1] !== undefined ? m[1] : ''\n if (this.operator === '=') {\n this.operator = ''\n }\n\n // if it literally is just '>' or '' then allow anything.\n if (!m[2]) {\n this.semver = ANY\n } else {\n this.semver = new SemVer(m[2], this.options.loose)\n }\n}\n\nComparator.prototype.toString = function () {\n return this.value\n}\n\nComparator.prototype.test = function (version) {\n debug('Comparator.test', version, this.options.loose)\n\n if (this.semver === ANY || version === ANY) {\n return true\n }\n\n if (typeof version === 'string') {\n try {\n version = new SemVer(version, this.options)\n } catch (er) {\n return false\n }\n }\n\n return cmp(version, this.operator, this.semver, this.options)\n}\n\nComparator.prototype.intersects = function (comp, options) {\n if (!(comp instanceof Comparator)) {\n throw new TypeError('a Comparator is required')\n }\n\n if (!options || typeof options !== 'object') {\n options = {\n loose: !!options,\n includePrerelease: false\n }\n }\n\n var rangeTmp\n\n if (this.operator === '') {\n if (this.value === '') {\n return true\n }\n rangeTmp = new Range(comp.value, options)\n return satisfies(this.value, rangeTmp, options)\n } else if (comp.operator === '') {\n if (comp.value === '') {\n return true\n }\n rangeTmp = new Range(this.value, options)\n return satisfies(comp.semver, rangeTmp, options)\n }\n\n var sameDirectionIncreasing =\n (this.operator === '>=' || this.operator === '>') &&\n (comp.operator === '>=' || comp.operator === '>')\n var sameDirectionDecreasing =\n (this.operator === '<=' || this.operator === '<') &&\n (comp.operator === '<=' || comp.operator === '<')\n var sameSemVer = this.semver.version === comp.semver.version\n var differentDirectionsInclusive =\n (this.operator === '>=' || this.operator === '<=') &&\n (comp.operator === '>=' || comp.operator === '<=')\n var oppositeDirectionsLessThan =\n cmp(this.semver, '<', comp.semver, options) &&\n ((this.operator === '>=' || this.operator === '>') &&\n (comp.operator === '<=' || comp.operator === '<'))\n var oppositeDirectionsGreaterThan =\n cmp(this.semver, '>', comp.semver, options) &&\n ((this.operator === '<=' || this.operator === '<') &&\n (comp.operator === '>=' || comp.operator === '>'))\n\n return sameDirectionIncreasing || sameDirectionDecreasing ||\n (sameSemVer && differentDirectionsInclusive) ||\n oppositeDirectionsLessThan || oppositeDirectionsGreaterThan\n}\n\nexports.Range = Range\nfunction Range (range, options) {\n if (!options || typeof options !== 'object') {\n options = {\n loose: !!options,\n includePrerelease: false\n }\n }\n\n if (range instanceof Range) {\n if (range.loose === !!options.loose &&\n range.includePrerelease === !!options.includePrerelease) {\n return range\n } else {\n return new Range(range.raw, options)\n }\n }\n\n if (range instanceof Comparator) {\n return new Range(range.value, options)\n }\n\n if (!(this instanceof Range)) {\n return new Range(range, options)\n }\n\n this.options = options\n this.loose = !!options.loose\n this.includePrerelease = !!options.includePrerelease\n\n // First reduce all whitespace as much as possible so we do not have to rely\n // on potentially slow regexes like \\s*. This is then stored and used for\n // future error messages as well.\n this.raw = range\n .trim()\n .split(/\\s+/)\n .join(' ')\n\n // First, split based on boolean or ||\n this.set = this.raw.split('||').map(function (range) {\n return this.parseRange(range.trim())\n }, this).filter(function (c) {\n // throw out any that are not relevant for whatever reason\n return c.length\n })\n\n if (!this.set.length) {\n throw new TypeError('Invalid SemVer Range: ' + this.raw)\n }\n\n this.format()\n}\n\nRange.prototype.format = function () {\n this.range = this.set.map(function (comps) {\n return comps.join(' ').trim()\n }).join('||').trim()\n return this.range\n}\n\nRange.prototype.toString = function () {\n return this.range\n}\n\nRange.prototype.parseRange = function (range) {\n var loose = this.options.loose\n // `1.2.3 - 1.2.4` => `>=1.2.3 <=1.2.4`\n var hr = loose ? safeRe[t.HYPHENRANGELOOSE] : safeRe[t.HYPHENRANGE]\n range = range.replace(hr, hyphenReplace)\n debug('hyphen replace', range)\n // `> 1.2.3 < 1.2.5` => `>1.2.3 <1.2.5`\n range = range.replace(safeRe[t.COMPARATORTRIM], comparatorTrimReplace)\n debug('comparator trim', range, safeRe[t.COMPARATORTRIM])\n\n // `~ 1.2.3` => `~1.2.3`\n range = range.replace(safeRe[t.TILDETRIM], tildeTrimReplace)\n\n // `^ 1.2.3` => `^1.2.3`\n range = range.replace(safeRe[t.CARETTRIM], caretTrimReplace)\n\n // normalize spaces\n range = range.split(/\\s+/).join(' ')\n\n // At this point, the range is completely trimmed and\n // ready to be split into comparators.\n\n var compRe = loose ? safeRe[t.COMPARATORLOOSE] : safeRe[t.COMPARATOR]\n var set = range.split(' ').map(function (comp) {\n return parseComparator(comp, this.options)\n }, this).join(' ').split(/\\s+/)\n if (this.options.loose) {\n // in loose mode, throw out any that are not valid comparators\n set = set.filter(function (comp) {\n return !!comp.match(compRe)\n })\n }\n set = set.map(function (comp) {\n return new Comparator(comp, this.options)\n }, this)\n\n return set\n}\n\nRange.prototype.intersects = function (range, options) {\n if (!(range instanceof Range)) {\n throw new TypeError('a Range is required')\n }\n\n return this.set.some(function (thisComparators) {\n return (\n isSatisfiable(thisComparators, options) &&\n range.set.some(function (rangeComparators) {\n return (\n isSatisfiable(rangeComparators, options) &&\n thisComparators.every(function (thisComparator) {\n return rangeComparators.every(function (rangeComparator) {\n return thisComparator.intersects(rangeComparator, options)\n })\n })\n )\n })\n )\n })\n}\n\n// take a set of comparators and determine whether there\n// exists a version which can satisfy it\nfunction isSatisfiable (comparators, options) {\n var result = true\n var remainingComparators = comparators.slice()\n var testComparator = remainingComparators.pop()\n\n while (result && remainingComparators.length) {\n result = remainingComparators.every(function (otherComparator) {\n return testComparator.intersects(otherComparator, options)\n })\n\n testComparator = remainingComparators.pop()\n }\n\n return result\n}\n\n// Mostly just for testing and legacy API reasons\nexports.toComparators = toComparators\nfunction toComparators (range, options) {\n return new Range(range, options).set.map(function (comp) {\n return comp.map(function (c) {\n return c.value\n }).join(' ').trim().split(' ')\n })\n}\n\n// comprised of xranges, tildes, stars, and gtlt's at this point.\n// already replaced the hyphen ranges\n// turn into a set of JUST comparators.\nfunction parseComparator (comp, options) {\n debug('comp', comp, options)\n comp = replaceCarets(comp, options)\n debug('caret', comp)\n comp = replaceTildes(comp, options)\n debug('tildes', comp)\n comp = replaceXRanges(comp, options)\n debug('xrange', comp)\n comp = replaceStars(comp, options)\n debug('stars', comp)\n return comp\n}\n\nfunction isX (id) {\n return !id || id.toLowerCase() === 'x' || id === '*'\n}\n\n// ~, ~> --> * (any, kinda silly)\n// ~2, ~2.x, ~2.x.x, ~>2, ~>2.x ~>2.x.x --> >=2.0.0 <3.0.0\n// ~2.0, ~2.0.x, ~>2.0, ~>2.0.x --> >=2.0.0 <2.1.0\n// ~1.2, ~1.2.x, ~>1.2, ~>1.2.x --> >=1.2.0 <1.3.0\n// ~1.2.3, ~>1.2.3 --> >=1.2.3 <1.3.0\n// ~1.2.0, ~>1.2.0 --> >=1.2.0 <1.3.0\nfunction replaceTildes (comp, options) {\n return comp.trim().split(/\\s+/).map(function (comp) {\n return replaceTilde(comp, options)\n }).join(' ')\n}\n\nfunction replaceTilde (comp, options) {\n var r = options.loose ? safeRe[t.TILDELOOSE] : safeRe[t.TILDE]\n return comp.replace(r, function (_, M, m, p, pr) {\n debug('tilde', comp, _, M, m, p, pr)\n var ret\n\n if (isX(M)) {\n ret = ''\n } else if (isX(m)) {\n ret = '>=' + M + '.0.0 <' + (+M + 1) + '.0.0'\n } else if (isX(p)) {\n // ~1.2 == >=1.2.0 <1.3.0\n ret = '>=' + M + '.' + m + '.0 <' + M + '.' + (+m + 1) + '.0'\n } else if (pr) {\n debug('replaceTilde pr', pr)\n ret = '>=' + M + '.' + m + '.' + p + '-' + pr +\n ' <' + M + '.' + (+m + 1) + '.0'\n } else {\n // ~1.2.3 == >=1.2.3 <1.3.0\n ret = '>=' + M + '.' + m + '.' + p +\n ' <' + M + '.' + (+m + 1) + '.0'\n }\n\n debug('tilde return', ret)\n return ret\n })\n}\n\n// ^ --> * (any, kinda silly)\n// ^2, ^2.x, ^2.x.x --> >=2.0.0 <3.0.0\n// ^2.0, ^2.0.x --> >=2.0.0 <3.0.0\n// ^1.2, ^1.2.x --> >=1.2.0 <2.0.0\n// ^1.2.3 --> >=1.2.3 <2.0.0\n// ^1.2.0 --> >=1.2.0 <2.0.0\nfunction replaceCarets (comp, options) {\n return comp.trim().split(/\\s+/).map(function (comp) {\n return replaceCaret(comp, options)\n }).join(' ')\n}\n\nfunction replaceCaret (comp, options) {\n debug('caret', comp, options)\n var r = options.loose ? safeRe[t.CARETLOOSE] : safeRe[t.CARET]\n return comp.replace(r, function (_, M, m, p, pr) {\n debug('caret', comp, _, M, m, p, pr)\n var ret\n\n if (isX(M)) {\n ret = ''\n } else if (isX(m)) {\n ret = '>=' + M + '.0.0 <' + (+M + 1) + '.0.0'\n } else if (isX(p)) {\n if (M === '0') {\n ret = '>=' + M + '.' + m + '.0 <' + M + '.' + (+m + 1) + '.0'\n } else {\n ret = '>=' + M + '.' + m + '.0 <' + (+M + 1) + '.0.0'\n }\n } else if (pr) {\n debug('replaceCaret pr', pr)\n if (M === '0') {\n if (m === '0') {\n ret = '>=' + M + '.' + m + '.' + p + '-' + pr +\n ' <' + M + '.' + m + '.' + (+p + 1)\n } else {\n ret = '>=' + M + '.' + m + '.' + p + '-' + pr +\n ' <' + M + '.' + (+m + 1) + '.0'\n }\n } else {\n ret = '>=' + M + '.' + m + '.' + p + '-' + pr +\n ' <' + (+M + 1) + '.0.0'\n }\n } else {\n debug('no pr')\n if (M === '0') {\n if (m === '0') {\n ret = '>=' + M + '.' + m + '.' + p +\n ' <' + M + '.' + m + '.' + (+p + 1)\n } else {\n ret = '>=' + M + '.' + m + '.' + p +\n ' <' + M + '.' + (+m + 1) + '.0'\n }\n } else {\n ret = '>=' + M + '.' + m + '.' + p +\n ' <' + (+M + 1) + '.0.0'\n }\n }\n\n debug('caret return', ret)\n return ret\n })\n}\n\nfunction replaceXRanges (comp, options) {\n debug('replaceXRanges', comp, options)\n return comp.split(/\\s+/).map(function (comp) {\n return replaceXRange(comp, options)\n }).join(' ')\n}\n\nfunction replaceXRange (comp, options) {\n comp = comp.trim()\n var r = options.loose ? safeRe[t.XRANGELOOSE] : safeRe[t.XRANGE]\n return comp.replace(r, function (ret, gtlt, M, m, p, pr) {\n debug('xRange', comp, ret, gtlt, M, m, p, pr)\n var xM = isX(M)\n var xm = xM || isX(m)\n var xp = xm || isX(p)\n var anyX = xp\n\n if (gtlt === '=' && anyX) {\n gtlt = ''\n }\n\n // if we're including prereleases in the match, then we need\n // to fix this to -0, the lowest possible prerelease value\n pr = options.includePrerelease ? '-0' : ''\n\n if (xM) {\n if (gtlt === '>' || gtlt === '<') {\n // nothing is allowed\n ret = '<0.0.0-0'\n } else {\n // nothing is forbidden\n ret = '*'\n }\n } else if (gtlt && anyX) {\n // we know patch is an x, because we have any x at all.\n // replace X with 0\n if (xm) {\n m = 0\n }\n p = 0\n\n if (gtlt === '>') {\n // >1 => >=2.0.0\n // >1.2 => >=1.3.0\n // >1.2.3 => >= 1.2.4\n gtlt = '>='\n if (xm) {\n M = +M + 1\n m = 0\n p = 0\n } else {\n m = +m + 1\n p = 0\n }\n } else if (gtlt === '<=') {\n // <=0.7.x is actually <0.8.0, since any 0.7.x should\n // pass. Similarly, <=7.x is actually <8.0.0, etc.\n gtlt = '<'\n if (xm) {\n M = +M + 1\n } else {\n m = +m + 1\n }\n }\n\n ret = gtlt + M + '.' + m + '.' + p + pr\n } else if (xm) {\n ret = '>=' + M + '.0.0' + pr + ' <' + (+M + 1) + '.0.0' + pr\n } else if (xp) {\n ret = '>=' + M + '.' + m + '.0' + pr +\n ' <' + M + '.' + (+m + 1) + '.0' + pr\n }\n\n debug('xRange return', ret)\n\n return ret\n })\n}\n\n// Because * is AND-ed with everything else in the comparator,\n// and '' means \"any version\", just remove the *s entirely.\nfunction replaceStars (comp, options) {\n debug('replaceStars', comp, options)\n // Looseness is ignored here. star is always as loose as it gets!\n return comp.trim().replace(safeRe[t.STAR], '')\n}\n\n// This function is passed to string.replace(re[t.HYPHENRANGE])\n// M, m, patch, prerelease, build\n// 1.2 - 3.4.5 => >=1.2.0 <=3.4.5\n// 1.2.3 - 3.4 => >=1.2.0 <3.5.0 Any 3.4.x will do\n// 1.2 - 3.4 => >=1.2.0 <3.5.0\nfunction hyphenReplace ($0,\n from, fM, fm, fp, fpr, fb,\n to, tM, tm, tp, tpr, tb) {\n if (isX(fM)) {\n from = ''\n } else if (isX(fm)) {\n from = '>=' + fM + '.0.0'\n } else if (isX(fp)) {\n from = '>=' + fM + '.' + fm + '.0'\n } else {\n from = '>=' + from\n }\n\n if (isX(tM)) {\n to = ''\n } else if (isX(tm)) {\n to = '<' + (+tM + 1) + '.0.0'\n } else if (isX(tp)) {\n to = '<' + tM + '.' + (+tm + 1) + '.0'\n } else if (tpr) {\n to = '<=' + tM + '.' + tm + '.' + tp + '-' + tpr\n } else {\n to = '<=' + to\n }\n\n return (from + ' ' + to).trim()\n}\n\n// if ANY of the sets match ALL of its comparators, then pass\nRange.prototype.test = function (version) {\n if (!version) {\n return false\n }\n\n if (typeof version === 'string') {\n try {\n version = new SemVer(version, this.options)\n } catch (er) {\n return false\n }\n }\n\n for (var i = 0; i < this.set.length; i++) {\n if (testSet(this.set[i], version, this.options)) {\n return true\n }\n }\n return false\n}\n\nfunction testSet (set, version, options) {\n for (var i = 0; i < set.length; i++) {\n if (!set[i].test(version)) {\n return false\n }\n }\n\n if (version.prerelease.length && !options.includePrerelease) {\n // Find the set of versions that are allowed to have prereleases\n // For example, ^1.2.3-pr.1 desugars to >=1.2.3-pr.1 <2.0.0\n // That should allow `1.2.3-pr.2` to pass.\n // However, `1.2.4-alpha.notready` should NOT be allowed,\n // even though it's within the range set by the comparators.\n for (i = 0; i < set.length; i++) {\n debug(set[i].semver)\n if (set[i].semver === ANY) {\n continue\n }\n\n if (set[i].semver.prerelease.length > 0) {\n var allowed = set[i].semver\n if (allowed.major === version.major &&\n allowed.minor === version.minor &&\n allowed.patch === version.patch) {\n return true\n }\n }\n }\n\n // Version has a -pre, but it's not one of the ones we like.\n return false\n }\n\n return true\n}\n\nexports.satisfies = satisfies\nfunction satisfies (version, range, options) {\n try {\n range = new Range(range, options)\n } catch (er) {\n return false\n }\n return range.test(version)\n}\n\nexports.maxSatisfying = maxSatisfying\nfunction maxSatisfying (versions, range, options) {\n var max = null\n var maxSV = null\n try {\n var rangeObj = new Range(range, options)\n } catch (er) {\n return null\n }\n versions.forEach(function (v) {\n if (rangeObj.test(v)) {\n // satisfies(v, range, options)\n if (!max || maxSV.compare(v) === -1) {\n // compare(max, v, true)\n max = v\n maxSV = new SemVer(max, options)\n }\n }\n })\n return max\n}\n\nexports.minSatisfying = minSatisfying\nfunction minSatisfying (versions, range, options) {\n var min = null\n var minSV = null\n try {\n var rangeObj = new Range(range, options)\n } catch (er) {\n return null\n }\n versions.forEach(function (v) {\n if (rangeObj.test(v)) {\n // satisfies(v, range, options)\n if (!min || minSV.compare(v) === 1) {\n // compare(min, v, true)\n min = v\n minSV = new SemVer(min, options)\n }\n }\n })\n return min\n}\n\nexports.minVersion = minVersion\nfunction minVersion (range, loose) {\n range = new Range(range, loose)\n\n var minver = new SemVer('0.0.0')\n if (range.test(minver)) {\n return minver\n }\n\n minver = new SemVer('0.0.0-0')\n if (range.test(minver)) {\n return minver\n }\n\n minver = null\n for (var i = 0; i < range.set.length; ++i) {\n var comparators = range.set[i]\n\n comparators.forEach(function (comparator) {\n // Clone to avoid manipulating the comparator's semver object.\n var compver = new SemVer(comparator.semver.version)\n switch (comparator.operator) {\n case '>':\n if (compver.prerelease.length === 0) {\n compver.patch++\n } else {\n compver.prerelease.push(0)\n }\n compver.raw = compver.format()\n /* fallthrough */\n case '':\n case '>=':\n if (!minver || gt(minver, compver)) {\n minver = compver\n }\n break\n case '<':\n case '<=':\n /* Ignore maximum versions */\n break\n /* istanbul ignore next */\n default:\n throw new Error('Unexpected operation: ' + comparator.operator)\n }\n })\n }\n\n if (minver && range.test(minver)) {\n return minver\n }\n\n return null\n}\n\nexports.validRange = validRange\nfunction validRange (range, options) {\n try {\n // Return '*' instead of '' so that truthiness works.\n // This will throw if it's invalid anyway\n return new Range(range, options).range || '*'\n } catch (er) {\n return null\n }\n}\n\n// Determine if version is less than all the versions possible in the range\nexports.ltr = ltr\nfunction ltr (version, range, options) {\n return outside(version, range, '<', options)\n}\n\n// Determine if version is greater than all the versions possible in the range.\nexports.gtr = gtr\nfunction gtr (version, range, options) {\n return outside(version, range, '>', options)\n}\n\nexports.outside = outside\nfunction outside (version, range, hilo, options) {\n version = new SemVer(version, options)\n range = new Range(range, options)\n\n var gtfn, ltefn, ltfn, comp, ecomp\n switch (hilo) {\n case '>':\n gtfn = gt\n ltefn = lte\n ltfn = lt\n comp = '>'\n ecomp = '>='\n break\n case '<':\n gtfn = lt\n ltefn = gte\n ltfn = gt\n comp = '<'\n ecomp = '<='\n break\n default:\n throw new TypeError('Must provide a hilo val of \"<\" or \">\"')\n }\n\n // If it satisifes the range it is not outside\n if (satisfies(version, range, options)) {\n return false\n }\n\n // From now on, variable terms are as if we're in \"gtr\" mode.\n // but note that everything is flipped for the \"ltr\" function.\n\n for (var i = 0; i < range.set.length; ++i) {\n var comparators = range.set[i]\n\n var high = null\n var low = null\n\n comparators.forEach(function (comparator) {\n if (comparator.semver === ANY) {\n comparator = new Comparator('>=0.0.0')\n }\n high = high || comparator\n low = low || comparator\n if (gtfn(comparator.semver, high.semver, options)) {\n high = comparator\n } else if (ltfn(comparator.semver, low.semver, options)) {\n low = comparator\n }\n })\n\n // If the edge version comparator has a operator then our version\n // isn't outside it\n if (high.operator === comp || high.operator === ecomp) {\n return false\n }\n\n // If the lowest version comparator has an operator and our version\n // is less than it then it isn't higher than the range\n if ((!low.operator || low.operator === comp) &&\n ltefn(version, low.semver)) {\n return false\n } else if (low.operator === ecomp && ltfn(version, low.semver)) {\n return false\n }\n }\n return true\n}\n\nexports.prerelease = prerelease\nfunction prerelease (version, options) {\n var parsed = parse(version, options)\n return (parsed && parsed.prerelease.length) ? parsed.prerelease : null\n}\n\nexports.intersects = intersects\nfunction intersects (r1, r2, options) {\n r1 = new Range(r1, options)\n r2 = new Range(r2, options)\n return r1.intersects(r2)\n}\n\nexports.coerce = coerce\nfunction coerce (version, options) {\n if (version instanceof SemVer) {\n return version\n }\n\n if (typeof version === 'number') {\n version = String(version)\n }\n\n if (typeof version !== 'string') {\n return null\n }\n\n options = options || {}\n\n var match = null\n if (!options.rtl) {\n match = version.match(safeRe[t.COERCE])\n } else {\n // Find the right-most coercible string that does not share\n // a terminus with a more left-ward coercible string.\n // Eg, '1.2.3.4' wants to coerce '2.3.4', not '3.4' or '4'\n //\n // Walk through the string checking with a /g regexp\n // Manually set the index so as to pick up overlapping matches.\n // Stop when we get a match that ends at the string end, since no\n // coercible string can be more right-ward without the same terminus.\n var next\n while ((next = safeRe[t.COERCERTL].exec(version)) &&\n (!match || match.index + match[0].length !== version.length)\n ) {\n if (!match ||\n next.index + next[0].length !== match.index + match[0].length) {\n match = next\n }\n safeRe[t.COERCERTL].lastIndex = next.index + next[1].length + next[2].length\n }\n // leave it in a clean state\n safeRe[t.COERCERTL].lastIndex = -1\n }\n\n if (match === null) {\n return null\n }\n\n return parse(match[2] +\n '.' + (match[3] || '0') +\n '.' + (match[4] || '0'), options)\n}\n","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports._readLinuxVersionFile = exports._getOsVersion = exports._findMatch = void 0;\nconst semver = __importStar(require(\"semver\"));\nconst core_1 = require(\"@actions/core\");\n// needs to be require for core node modules to be mocked\n/* eslint @typescript-eslint/no-require-imports: 0 */\nconst os = require(\"os\");\nconst cp = require(\"child_process\");\nconst fs = require(\"fs\");\nfunction _findMatch(versionSpec, stable, candidates, archFilter) {\n return __awaiter(this, void 0, void 0, function* () {\n const platFilter = os.platform();\n let result;\n let match;\n let file;\n for (const candidate of candidates) {\n const version = candidate.version;\n core_1.debug(`check ${version} satisfies ${versionSpec}`);\n if (semver.satisfies(version, versionSpec) &&\n (!stable || candidate.stable === stable)) {\n file = candidate.files.find(item => {\n core_1.debug(`${item.arch}===${archFilter} && ${item.platform}===${platFilter}`);\n let chk = item.arch === archFilter && item.platform === platFilter;\n if (chk && item.platform_version) {\n const osVersion = module.exports._getOsVersion();\n if (osVersion === item.platform_version) {\n chk = true;\n }\n else {\n chk = semver.satisfies(osVersion, item.platform_version);\n }\n }\n return chk;\n });\n if (file) {\n core_1.debug(`matched ${candidate.version}`);\n match = candidate;\n break;\n }\n }\n }\n if (match && file) {\n // clone since we're mutating the file list to be only the file that matches\n result = Object.assign({}, match);\n result.files = [file];\n }\n return result;\n });\n}\nexports._findMatch = _findMatch;\nfunction _getOsVersion() {\n // TODO: add windows and other linux, arm variants\n // right now filtering on version is only an ubuntu and macos scenario for tools we build for hosted (python)\n const plat = os.platform();\n let version = '';\n if (plat === 'darwin') {\n version = cp.execSync('sw_vers -productVersion').toString();\n }\n else if (plat === 'linux') {\n // lsb_release process not in some containers, readfile\n // Run cat /etc/lsb-release\n // DISTRIB_ID=Ubuntu\n // DISTRIB_RELEASE=18.04\n // DISTRIB_CODENAME=bionic\n // DISTRIB_DESCRIPTION=\"Ubuntu 18.04.4 LTS\"\n const lsbContents = module.exports._readLinuxVersionFile();\n if (lsbContents) {\n const lines = lsbContents.split('\\n');\n for (const line of lines) {\n const parts = line.split('=');\n if (parts.length === 2 &&\n (parts[0].trim() === 'VERSION_ID' ||\n parts[0].trim() === 'DISTRIB_RELEASE')) {\n version = parts[1]\n .trim()\n .replace(/^\"/, '')\n .replace(/\"$/, '');\n break;\n }\n }\n }\n }\n return version;\n}\nexports._getOsVersion = _getOsVersion;\nfunction _readLinuxVersionFile() {\n const lsbReleaseFile = '/etc/lsb-release';\n const osReleaseFile = '/etc/os-release';\n let contents = '';\n if (fs.existsSync(lsbReleaseFile)) {\n contents = fs.readFileSync(lsbReleaseFile).toString();\n }\n else if (fs.existsSync(osReleaseFile)) {\n contents = fs.readFileSync(osReleaseFile).toString();\n }\n return contents;\n}\nexports._readLinuxVersionFile = _readLinuxVersionFile;\n//# sourceMappingURL=manifest.js.map","/**\n * Convert array of 16 byte values to UUID string format of the form:\n * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX\n */\nvar byteToHex = [];\nfor (var i = 0; i < 256; ++i) {\n byteToHex[i] = (i + 0x100).toString(16).substr(1);\n}\n\nfunction bytesToUuid(buf, offset) {\n var i = offset || 0;\n var bth = byteToHex;\n // join used to fix memory issue caused by concatenation: https://bugs.chromium.org/p/v8/issues/detail?id=3175#c4\n return ([\n bth[buf[i++]], bth[buf[i++]],\n bth[buf[i++]], bth[buf[i++]], '-',\n bth[buf[i++]], bth[buf[i++]], '-',\n bth[buf[i++]], bth[buf[i++]], '-',\n bth[buf[i++]], bth[buf[i++]], '-',\n bth[buf[i++]], bth[buf[i++]],\n bth[buf[i++]], bth[buf[i++]],\n bth[buf[i++]], bth[buf[i++]]\n ]).join('');\n}\n\nmodule.exports = bytesToUuid;\n","// Unique ID creation requires a high quality random # generator. In node.js\n// this is pretty straight-forward - we use the crypto API.\n\nvar crypto = require('crypto');\n\nmodule.exports = function nodeRNG() {\n return crypto.randomBytes(16);\n};\n","var rng = require('./lib/rng');\nvar bytesToUuid = require('./lib/bytesToUuid');\n\nfunction v4(options, buf, offset) {\n var i = buf && offset || 0;\n\n if (typeof(options) == 'string') {\n buf = options === 'binary' ? new Array(16) : null;\n options = null;\n }\n options = options || {};\n\n var rnds = options.random || (options.rng || rng)();\n\n // Per 4.4, set bits for version and `clock_seq_hi_and_reserved`\n rnds[6] = (rnds[6] & 0x0f) | 0x40;\n rnds[8] = (rnds[8] & 0x3f) | 0x80;\n\n // Copy bytes to buffer, if provided\n if (buf) {\n for (var ii = 0; ii < 16; ++ii) {\n buf[i + ii] = rnds[ii];\n }\n }\n\n return buf || bytesToUuid(rnds);\n}\n\nmodule.exports = v4;\n","\"use strict\";\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\n}) : (function(o, m, k, k2) {\n if (k2 === undefined) k2 = k;\n o[k2] = m[k];\n}));\nvar __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\n}) : function(o, v) {\n o[\"default\"] = v;\n});\nvar __importStar = (this && this.__importStar) || function (mod) {\n if (mod && mod.__esModule) return mod;\n var result = {};\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\n __setModuleDefault(result, mod);\n return result;\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.RetryHelper = void 0;\nconst core = __importStar(require(\"@actions/core\"));\n/**\n * Internal class for retries\n */\nclass RetryHelper {\n constructor(maxAttempts, minSeconds, maxSeconds) {\n if (maxAttempts < 1) {\n throw new Error('max attempts should be greater than or equal to 1');\n }\n this.maxAttempts = maxAttempts;\n this.minSeconds = Math.floor(minSeconds);\n this.maxSeconds = Math.floor(maxSeconds);\n if (this.minSeconds > this.maxSeconds) {\n throw new Error('min seconds should be less than or equal to max seconds');\n }\n }\n execute(action, isRetryable) {\n return __awaiter(this, void 0, void 0, function* () {\n let attempt = 1;\n while (attempt < this.maxAttempts) {\n // Try\n try {\n return yield action();\n }\n catch (err) {\n if (isRetryable && !isRetryable(err)) {\n throw err;\n }\n core.info(err.message);\n }\n // Sleep\n const seconds = this.getSleepAmount();\n core.info(`Waiting ${seconds} seconds before trying again`);\n yield this.sleep(seconds);\n attempt++;\n }\n // Last attempt\n return yield action();\n });\n }\n getSleepAmount() {\n return (Math.floor(Math.random() * (this.maxSeconds - this.minSeconds + 1)) +\n this.minSeconds);\n }\n sleep(seconds) {\n return __awaiter(this, void 0, void 0, function* () {\n return new Promise(resolve => setTimeout(resolve, seconds * 1000));\n });\n }\n}\nexports.RetryHelper = RetryHelper;\n//# sourceMappingURL=retry-helper.js.map","import { mkdir, mkdirSync, stat, statSync, } from 'fs';\nexport const optsArg = (opts) => {\n if (!opts) {\n opts = { mode: 0o777 };\n }\n else if (typeof opts === 'object') {\n opts = { mode: 0o777, ...opts };\n }\n else if (typeof opts === 'number') {\n opts = { mode: opts };\n }\n else if (typeof opts === 'string') {\n opts = { mode: parseInt(opts, 8) };\n }\n else {\n throw new TypeError('invalid options argument');\n }\n const resolved = opts;\n const optsFs = opts.fs || {};\n opts.mkdir = opts.mkdir || optsFs.mkdir || mkdir;\n opts.mkdirAsync = opts.mkdirAsync\n ? opts.mkdirAsync\n : async (path, options) => {\n return new Promise((res, rej) => resolved.mkdir(path, options, (er, made) => er ? rej(er) : res(made)));\n };\n opts.stat = opts.stat || optsFs.stat || stat;\n opts.statAsync = opts.statAsync\n ? opts.statAsync\n : async (path) => new Promise((res, rej) => resolved.stat(path, (err, stats) => (err ? rej(err) : res(stats))));\n opts.statSync = opts.statSync || optsFs.statSync || statSync;\n opts.mkdirSync = opts.mkdirSync || optsFs.mkdirSync || mkdirSync;\n return resolved;\n};\n//# sourceMappingURL=opts-arg.js.map","import { dirname } from 'path';\nimport { optsArg } from './opts-arg.js';\nexport const mkdirpManualSync = (path, options, made) => {\n const parent = dirname(path);\n const opts = { ...optsArg(options), recursive: false };\n if (parent === path) {\n try {\n return opts.mkdirSync(path, opts);\n }\n catch (er) {\n // swallowed by recursive implementation on posix systems\n // any other error is a failure\n const fer = er;\n if (fer && fer.code !== 'EISDIR') {\n throw er;\n }\n return;\n }\n }\n try {\n opts.mkdirSync(path, opts);\n return made || path;\n }\n catch (er) {\n const fer = er;\n if (fer && fer.code === 'ENOENT') {\n return mkdirpManualSync(path, opts, mkdirpManualSync(parent, opts, made));\n }\n if (fer && fer.code !== 'EEXIST' && fer && fer.code !== 'EROFS') {\n throw er;\n }\n try {\n if (!opts.statSync(path).isDirectory())\n throw er;\n }\n catch (_) {\n throw er;\n }\n }\n};\nexport const mkdirpManual = Object.assign(async (path, options, made) => {\n const opts = optsArg(options);\n opts.recursive = false;\n const parent = dirname(path);\n if (parent === path) {\n return opts.mkdirAsync(path, opts).catch(er => {\n // swallowed by recursive implementation on posix systems\n // any other error is a failure\n const fer = er;\n if (fer && fer.code !== 'EISDIR') {\n throw er;\n }\n });\n }\n return opts.mkdirAsync(path, opts).then(() => made || path, async (er) => {\n const fer = er;\n if (fer && fer.code === 'ENOENT') {\n return mkdirpManual(parent, opts).then((made) => mkdirpManual(path, opts, made));\n }\n if (fer && fer.code !== 'EEXIST' && fer.code !== 'EROFS') {\n throw er;\n }\n return opts.statAsync(path).then(st => {\n if (st.isDirectory()) {\n return made;\n }\n else {\n throw er;\n }\n }, () => {\n throw er;\n });\n });\n}, { sync: mkdirpManualSync });\n//# sourceMappingURL=mkdirp-manual.js.map","import { dirname } from 'path';\nexport const findMade = async (opts, parent, path) => {\n // we never want the 'made' return value to be a root directory\n if (path === parent) {\n return;\n }\n return opts.statAsync(parent).then(st => (st.isDirectory() ? path : undefined), // will fail later\n // will fail later\n er => {\n const fer = er;\n return fer && fer.code === 'ENOENT'\n ? findMade(opts, dirname(parent), parent)\n : undefined;\n });\n};\nexport const findMadeSync = (opts, parent, path) => {\n if (path === parent) {\n return undefined;\n }\n try {\n return opts.statSync(parent).isDirectory() ? path : undefined;\n }\n catch (er) {\n const fer = er;\n return fer && fer.code === 'ENOENT'\n ? findMadeSync(opts, dirname(parent), parent)\n : undefined;\n }\n};\n//# sourceMappingURL=find-made.js.map","import { dirname } from 'path';\nimport { findMade, findMadeSync } from './find-made.js';\nimport { mkdirpManual, mkdirpManualSync } from './mkdirp-manual.js';\nimport { optsArg } from './opts-arg.js';\nexport const mkdirpNativeSync = (path, options) => {\n const opts = optsArg(options);\n opts.recursive = true;\n const parent = dirname(path);\n if (parent === path) {\n return opts.mkdirSync(path, opts);\n }\n const made = findMadeSync(opts, path);\n try {\n opts.mkdirSync(path, opts);\n return made;\n }\n catch (er) {\n const fer = er;\n if (fer && fer.code === 'ENOENT') {\n return mkdirpManualSync(path, opts);\n }\n else {\n throw er;\n }\n }\n};\nexport const mkdirpNative = Object.assign(async (path, options) => {\n const opts = { ...optsArg(options), recursive: true };\n const parent = dirname(path);\n if (parent === path) {\n return await opts.mkdirAsync(path, opts);\n }\n return findMade(opts, path).then((made) => opts\n .mkdirAsync(path, opts)\n .then(m => made || m)\n .catch(er => {\n const fer = er;\n if (fer && fer.code === 'ENOENT') {\n return mkdirpManual(path, opts);\n }\n else {\n throw er;\n }\n }));\n}, { sync: mkdirpNativeSync });\n//# sourceMappingURL=mkdirp-native.js.map","const platform = process.env.__TESTING_MKDIRP_PLATFORM__ || process.platform;\nimport { parse, resolve } from 'path';\nexport const pathArg = (path) => {\n if (/\\0/.test(path)) {\n // simulate same failure that node raises\n throw Object.assign(new TypeError('path must be a string without null bytes'), {\n path,\n code: 'ERR_INVALID_ARG_VALUE',\n });\n }\n path = resolve(path);\n if (platform === 'win32') {\n const badWinChars = /[*|\"<>?:]/;\n const { root } = parse(path);\n if (badWinChars.test(path.substring(root.length))) {\n throw Object.assign(new Error('Illegal characters in path.'), {\n path,\n code: 'EINVAL',\n });\n }\n }\n return path;\n};\n//# sourceMappingURL=path-arg.js.map","import { mkdir, mkdirSync } from 'fs';\nimport { optsArg } from './opts-arg.js';\nconst version = process.env.__TESTING_MKDIRP_NODE_VERSION__ || process.version;\nconst versArr = version.replace(/^v/, '').split('.');\nconst hasNative = +versArr[0] > 10 || (+versArr[0] === 10 && +versArr[1] >= 12);\nexport const useNativeSync = !hasNative\n ? () => false\n : (opts) => optsArg(opts).mkdirSync === mkdirSync;\nexport const useNative = Object.assign(!hasNative\n ? () => false\n : (opts) => optsArg(opts).mkdir === mkdir, {\n sync: useNativeSync,\n});\n//# sourceMappingURL=use-native.js.map","import { mkdirpManual, mkdirpManualSync } from './mkdirp-manual.js';\nimport { mkdirpNative, mkdirpNativeSync } from './mkdirp-native.js';\nimport { optsArg } from './opts-arg.js';\nimport { pathArg } from './path-arg.js';\nimport { useNative, useNativeSync } from './use-native.js';\n/* c8 ignore start */\nexport { mkdirpManual, mkdirpManualSync } from './mkdirp-manual.js';\nexport { mkdirpNative, mkdirpNativeSync } from './mkdirp-native.js';\nexport { useNative, useNativeSync } from './use-native.js';\n/* c8 ignore stop */\nexport const mkdirpSync = (path, opts) => {\n path = pathArg(path);\n const resolved = optsArg(opts);\n return useNativeSync(resolved)\n ? mkdirpNativeSync(path, resolved)\n : mkdirpManualSync(path, resolved);\n};\nexport const sync = mkdirpSync;\nexport const manual = mkdirpManual;\nexport const manualSync = mkdirpManualSync;\nexport const native = mkdirpNative;\nexport const nativeSync = mkdirpNativeSync;\nexport const mkdirp = Object.assign(async (path, opts) => {\n path = pathArg(path);\n const resolved = optsArg(opts);\n return useNative(resolved)\n ? mkdirpNative(path, resolved)\n : mkdirpManual(path, resolved);\n}, {\n mkdirpSync,\n mkdirpNative,\n mkdirpNativeSync,\n mkdirpManual,\n mkdirpManualSync,\n sync: mkdirpSync,\n native: mkdirpNative,\n nativeSync: mkdirpNativeSync,\n manual: mkdirpManual,\n manualSync: mkdirpManualSync,\n useNative,\n useNativeSync,\n});\n//# sourceMappingURL=index.js.map","import { isArch } from \"../utils/env/isArch.js\"\n\nconst defaultLLVM = process.platform === \"darwin\" && process.arch === \"x64\"\n ? \"15.0.7\"\n : \"18.1.8\"\n\n/**\n * Default versions for the tools\n * DefaultUbuntuVersion overrides the default version for the tools on Ubuntu\n */\nexport const DefaultVersions: Record<string, string | undefined> = {\n // https://github.com/llvm/llvm-project/releases\n llvm: defaultLLVM,\n clang: defaultLLVM,\n \"clang++\": defaultLLVM,\n \"clang-tidy\": defaultLLVM,\n clangtidy: defaultLLVM,\n \"clang-format\": defaultLLVM,\n clangformat: defaultLLVM,\n ninja: \"1.12.1\", // https://github.com/ninja-build/ninja/releases\n cmake: \"3.30.4\", // https://github.com/Kitware/CMake/releases\n meson: \"1.5.2\", // https://github.com/mesonbuild/meson/releases\n kcov: \"42\", // https://github.com/SimonKagstrom/kcov/releases\n task: \"3.39.2\", // https://github.com/go-task/task/releases\n doxygen: isArch() ? \"1.12.0-2\" : \"1.12.0\", // https://www.doxygen.nl/download.html // https://packages.ubuntu.com/search?suite=all&arch=any&searchon=names&keywords=doxygen // https://formulae.brew.sh/formula/doxygen // https://archlinux.org/packages/extra/x86_64/doxygen/\n gcc: process.platform === \"win32\"\n ? \"14.2.0posix-18.1.8-12.0.0-ucrt-r1\"\n : \"\", // use the default version on Ubuntu, Fedora, Arch, macOS, etc.\n // mingw: isArch() ? \"12.2.0-1\" : \"8\", // https://archlinux.org/packages/extra/x86_64/mingw-w64-gcc/\n powershell: \"7.4.5\",\n}\n\nexport const MinVersions: Record<string, string | undefined> = {\n pip: \"22.2.0\",\n python: \"3.7.9\",\n}\n\n/// If an ubuntu versions is not in this map:\n// - the newer ubuntu versions use the first entry (e.g. v20),\n// - the older ones use \"\"\nexport const DefaultUbuntuVersion: Record<string, Record<number, string> | undefined> = {\n // https://packages.ubuntu.com/search?suite=all&arch=any&searchon=names&keywords=mingw-w64\n mingw: {\n 24: \"8.0.0-1\",\n 22: \"8.0.0-1\",\n 20: \"7.0.0-2\",\n },\n gcovr: {\n 24: \"6.0\",\n 22: \"6.0\",\n 20: \"6.0\",\n 18: \"5.0\",\n },\n meson: {\n 24: \"1.0.0\",\n 22: \"1.0.0\",\n 20: \"1.0.0\",\n 18: \"0.61.4\",\n },\n nala: {\n 24: \"\",\n 22: \"\",\n 21: \"legacy\",\n 20: \"legacy\",\n 18: \"legacy\",\n 16: \"legacy\",\n 14: \"legacy\",\n },\n kcov: {\n 24: \"42-binary\",\n 22: \"42-binary\",\n 20: \"40-binary\", // https://github.com/SimonKagstrom/kcov/releases\n 18: \"40\",\n 16: \"40\",\n 14: \"40\",\n },\n doxygen: {\n 24: \"1.11.0\",\n 22: \"1.11.0\",\n 20: \"1.10.0\",\n 18: \"1.10.0\",\n },\n}\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getUbuntuVersion = void 0;\nconst child_process_1 = require(\"child_process\");\nfunction isSystemError(e) {\n return 'errno' in e;\n}\nfunction command(exe, args) {\n return new Promise((resolve, reject) => {\n child_process_1.execFile(exe, args, { encoding: 'utf8', shell: false }, (error, stdout, stderr) => {\n if (error) {\n if (isSystemError(error) && error.code === 'ENOENT') {\n resolve(null); // When lsb_release is not found\n return;\n }\n reject(new Error(`Could not execute \\`${exe} ${args.join(' ')}\\`: ${error} (stderr=${stderr})`));\n return;\n }\n resolve(stdout);\n });\n });\n}\nasync function getUbuntuVersion() {\n if (process.platform !== 'linux') {\n return [];\n }\n const stdout = await command('lsb_release', ['-a']);\n if (stdout === null) {\n return [];\n }\n const reDistributor = /^Distributor ID:\\s*(.+)$/;\n const reDescription = /^Description:\\s*Ubuntu\\s+(\\d+)\\.(\\d+)(?:\\.(\\d+))?/;\n const reRelease = /^Release:\\s*(\\d+)\\.(\\d+)(?:\\.(\\d+))?$/;\n let description = null;\n let release = null;\n let distributorFound = false;\n for (const line of stdout.split('\\n')) {\n const m = line.match(reDistributor);\n if (m !== null) {\n const distributor = m[1];\n if (distributor !== 'Ubuntu') {\n return [];\n }\n distributorFound = true;\n }\n const desc = line.match(reDescription);\n if (desc) {\n description = desc;\n }\n const rel = line.match(reRelease);\n if (rel) {\n release = rel;\n }\n if (distributorFound && description && release) {\n break;\n }\n }\n if (!distributorFound) {\n return [];\n }\n for (const m of [description, release]) {\n if (m) {\n const ss = [m[1], m[2]];\n if (m[3]) {\n ss.push(m[3]);\n }\n return ss.map(s => parseInt(s, 10));\n }\n }\n return [];\n}\nexports.getUbuntuVersion = getUbuntuVersion;\n//# sourceMappingURL=index.js.map","import os from 'node:os';\n\nconst nameMap = new Map([\n\t[24, ['Sequoia', '15']],\n\t[23, ['Sonoma', '14']],\n\t[22, ['Ventura', '13']],\n\t[21, ['Monterey', '12']],\n\t[20, ['Big Sur', '11']],\n\t[19, ['Catalina', '10.15']],\n\t[18, ['Mojave', '10.14']],\n\t[17, ['High Sierra', '10.13']],\n\t[16, ['Sierra', '10.12']],\n\t[15, ['El Capitan', '10.11']],\n\t[14, ['Yosemite', '10.10']],\n\t[13, ['Mavericks', '10.9']],\n\t[12, ['Mountain Lion', '10.8']],\n\t[11, ['Lion', '10.7']],\n\t[10, ['Snow Leopard', '10.6']],\n\t[9, ['Leopard', '10.5']],\n\t[8, ['Tiger', '10.4']],\n\t[7, ['Panther', '10.3']],\n\t[6, ['Jaguar', '10.2']],\n\t[5, ['Puma', '10.1']],\n]);\n\nexport default function macosRelease(release) {\n\trelease = Number((release || os.release()).split('.')[0]);\n\n\tconst [name, version] = nameMap.get(release) || ['Unknown', ''];\n\n\treturn {\n\t\tname,\n\t\tversion,\n\t};\n}\n","import macosRelease from \"macos-release\"\nimport memoize from \"memoizee\"\n\n/**\n * Get macOS version\n *\n * @returns {number[]} - The macOS version as an array of numbers\n */\nfunction macosVersion_() {\n if (process.platform !== \"darwin\") {\n return []\n }\n\n const { version } = macosRelease()\n return version.split(\".\").map((v) => Number.parseInt(v, 10))\n}\nexport const macosVersion = memoize(macosVersion_)\n","import { tmpdir } from \"os\"\nimport { dirname, join } from \"path\"\nimport { execRootSync } from \"admina\"\nimport { error, info } from \"ci-log\"\nimport { readFile, writeFile } from \"fs/promises\"\nimport { DownloaderHelper } from \"node-downloader-helper\"\nimport { hasNala, installAptPack, qualifiedNeededAptPackage } from \"setup-apt\"\nimport which from \"which\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\n\nlet binDir: string | undefined\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport async function setupNala(version: string, _setupDir: string, _arch: string) {\n if (!isUbuntu()) {\n return undefined\n }\n if (typeof binDir === \"string\") {\n return { binDir }\n }\n\n const maybeBinDir = which.sync(\"nala\", { nothrow: true })\n if (maybeBinDir !== null) {\n binDir = dirname(maybeBinDir)\n return { binDir }\n }\n\n await installAptPack([{ name: \"python3-apt\" }])\n\n binDir = \"/usr/bin\" // eslint-disable-line require-atomic-updates\n\n // If nala is available in the default repositories, install it\n try {\n const nalaPack = await qualifiedNeededAptPackage({ name: \"nala\", version })\n if (nalaPack !== undefined) {\n await installAptPack([{ name: nalaPack }])\n return { binDir }\n }\n } catch (err) {\n // ignore\n info(`Failed to install nala: ${err}`)\n }\n\n // Nala is not available in the default repositories\n // Check if the legacy version is available\n try {\n const nalaLegacyPack = await qualifiedNeededAptPackage({ name: \"nala-legacy\" })\n if (nalaLegacyPack !== undefined) {\n await installAptPack([{ name: nalaLegacyPack }], true)\n return { binDir }\n }\n } catch (err) {\n // ignore\n info(`Failed to install nala-legacy: ${err}`)\n }\n\n // Install via the installer script\n await setupNalaViaInstaller()\n\n return { binDir }\n}\n\nasync function setupNalaViaInstaller() {\n const installer = new DownloaderHelper(\n \"https://gitlab.com/volian/volian-archive/-/raw/main/install-nala.sh\",\n tmpdir(),\n { fileName: \"install-nala.sh\" },\n )\n installer.on(\"error\", (err) => {\n throw new Error(`Failed to download install-nala.sh: ${err}`)\n })\n await installer.start()\n\n const installerPath = join(tmpdir(), \"install-nala.sh\")\n\n // Patch the installer script to not use sudo explicitly\n const script = await readFile(installerPath, \"utf8\")\n await writeFile(installerPath, script.replace(/sudo/g, \"\"))\n\n await installAptPack([{ name: \"wget\" }])\n\n try {\n execRootSync(\"bash\", [installerPath])\n } catch (err) {\n error(`Failed to install nala via installer: ${err}`)\n execRootSync(\"apt\", [\"install\", \"-y\", \"-t\", \"nala\", \"nala\"])\n }\n}\n\nexport function bashWithNala(script: string) {\n if (hasNala()) {\n return `apt-get() { nala $@; }; export -f apt-get; ${script}; unset -f apt-get`\n }\n return script\n}\n","import { dirname, join } from \"path\"\nimport { grantUserWriteAccess } from \"admina\"\nimport { info, notice } from \"ci-log\"\nimport { addPath } from \"envosman\"\nimport { execaSync } from \"execa\"\nimport { pathExists } from \"path-exists\"\nimport { addShExt, addShRelativePrefix } from \"patha\"\nimport { installAptPack } from \"setup-apt\"\nimport which from \"which\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport type { InstallationInfo } from \"../utils/setup/setupBin.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\n\nlet hasVCPKG = false\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport async function setupVcpkg(version: string, setupDir: string, _arch: string): Promise<InstallationInfo> {\n if (!hasVCPKG || which.sync(\"vcpkg\", { nothrow: true }) === null) {\n if (process.platform === \"linux\") {\n // vcpkg download and extraction dependencies\n if (isArch()) {\n await Promise.all([\n setupPacmanPack(\"curl\"),\n setupPacmanPack(\"zip\"),\n setupPacmanPack(\"unzip\"),\n setupPacmanPack(\"tar\"),\n setupPacmanPack(\"git\"),\n setupPacmanPack(\"pkg-config\"),\n ])\n } else if (hasDnf()) {\n await setupDnfPack([\n { name: \"curl\" },\n { name: \"zip\" },\n { name: \"unzip\" },\n { name: \"tar\" },\n { name: \"git\" },\n { name: \"pkg-config\" },\n ])\n } else if (isUbuntu()) {\n await installAptPack([\n { name: \"curl\" },\n { name: \"zip\" },\n { name: \"unzip\" },\n { name: \"tar\" },\n { name: \"git\" },\n { name: \"pkg-config\" },\n ])\n }\n }\n\n // clone if not already exists\n if (!(await pathExists(join(setupDir, addShExt(\"bootstrap-vcpkg\", \".bat\"))))) {\n execaSync(\"git\", [\"clone\", \"https://github.com/microsoft/vcpkg\"], { cwd: dirname(setupDir), stdio: \"inherit\" })\n } else {\n notice(`Vcpkg folder already exists at ${setupDir}. Skipping the clone`)\n }\n\n // if version specified, checkout the version\n if (version !== \"\" && version !== \"true\") {\n info(`Checking out vcpkg version ${version}`)\n execaSync(\"git\", [\"checkout\", version], {\n cwd: setupDir,\n stdio: \"inherit\",\n })\n }\n\n // bootstrap vcpkg\n execaSync(addShExt(addShRelativePrefix(\"bootstrap-vcpkg\"), \".bat\"), {\n cwd: setupDir,\n shell: true,\n stdio: \"inherit\",\n })\n\n await grantUserWriteAccess(setupDir)\n\n await addPath(setupDir, rcOptions)\n // eslint-disable-next-line require-atomic-updates\n hasVCPKG = true\n return { binDir: setupDir }\n }\n\n return { binDir: dirname(which.sync(\"vcpkg\")) }\n}\n","import { setupBrew } from \"setup-brew\"\nimport { setupBazel } from \"./bazel/bazel.js\"\nimport { setupCcache } from \"./ccache/ccache.js\"\nimport { setupChocolatey } from \"./chocolatey/chocolatey.js\"\nimport { setupCmake } from \"./cmake/cmake.js\"\nimport { setupCmakelang } from \"./cmakelang/cmakelang.js\"\nimport { setupConan } from \"./conan/conan.js\"\nimport { setupCppcheck } from \"./cppcheck/cppcheck.js\"\nimport { setupCpplint } from \"./cpplint/cpplint.js\"\nimport { setupDoxygen } from \"./doxygen/doxygen.js\"\nimport { setupFlawfinder } from \"./flawfinder/flawfinder.js\"\nimport { setupGcc } from \"./gcc/gcc.js\"\nimport { setupMingw } from \"./gcc/mingw.js\"\nimport { setupGcovr } from \"./gcovr/gcovr.js\"\nimport { setupGraphviz } from \"./graphviz/graphviz.js\"\nimport { setupInfer } from \"./infer/infer.js\"\nimport { setupKcov } from \"./kcov/kcov.js\"\nimport { setupLizard } from \"./lizard/lizard.js\"\nimport { setupAppleClang } from \"./llvm/apple-clang.js\"\nimport { setupClangFormat, setupClangTools, setupLLVM } from \"./llvm/llvm.js\"\nimport { setupMake } from \"./make/make.js\"\nimport { setupMeson } from \"./meson/meson.js\"\nimport { setupMSVC } from \"./msvc/msvc.js\"\nimport { setupNala } from \"./nala/nala.js\"\nimport { setupNinja } from \"./ninja/ninja.js\"\nimport { setupOpencppcoverage } from \"./opencppcoverage/opencppcoverage.js\"\nimport { setupPowershell } from \"./powershell/powershell.js\"\nimport { setupPython } from \"./python/python.js\"\nimport { setupSccache } from \"./sccache/sccache.js\"\nimport { setupSevenZip } from \"./sevenzip/sevenzip.js\"\nimport { setupTask } from \"./task/task.js\"\nimport { setupVcpkg } from \"./vcpkg/vcpkg.js\"\nimport { setupVCVarsall } from \"./vcvarsall/vcvarsall.js\"\n\nexport const llvmSetups = { llvm: setupLLVM, clang: setupLLVM, \"clang++\": setupLLVM } as const\nexport const gccSetups = { gcc: setupGcc, \"g++\": setupGcc } as const\nexport const mingwSetups = { mingw: setupMingw } as const\nexport const msvcSetups = {\n msvc: setupMSVC,\n cl: setupMSVC,\n msbuild: setupMSVC,\n visualstudio: setupMSVC,\n} as const\nexport const appleClangSetups = {\n appleclang: setupAppleClang,\n applellvm: setupAppleClang,\n \"apple-clang\": setupAppleClang,\n \"apple-llvm\": setupAppleClang,\n} as const\n\nconst cmakeLangSetups = {\n cmakelang: setupCmakelang,\n \"cmake-lint\": setupCmakelang,\n \"cmake-format\": setupCmakelang,\n cmakelint: setupCmakelang,\n cmakeformat: setupCmakelang,\n} as const\n\nexport const llvmTools = [\"llvm\", \"clang\", \"clang++\", \"clang-tidy\", \"clang-format\", \"clangtidy\", \"clangformat\"]\n\n/** The setup functions */\nexport const setups = {\n nala: setupNala,\n brew: setupBrew,\n choco: setupChocolatey,\n python: setupPython,\n powershell: setupPowershell,\n pwsh: setupPowershell,\n ...llvmSetups,\n ...gccSetups,\n ...mingwSetups,\n ...msvcSetups,\n ...appleClangSetups,\n ...cmakeLangSetups,\n cmake: setupCmake,\n ninja: setupNinja,\n vcpkg: setupVcpkg,\n bazel: setupBazel,\n conan: setupConan,\n meson: setupMeson,\n gcovr: setupGcovr,\n opencppcoverage: setupOpencppcoverage,\n OpenCppCoverage: setupOpencppcoverage,\n ccache: setupCcache,\n sccache: setupSccache,\n doxygen: setupDoxygen,\n graphviz: setupGraphviz,\n cppcheck: setupCppcheck,\n cpplint: setupCpplint,\n flawfinder: setupFlawfinder,\n lizard: setupLizard,\n infer: setupInfer,\n \"clang-tidy\": setupClangTools,\n clangtidy: setupClangTools,\n \"clang-format\": setupClangFormat,\n clangformat: setupClangFormat,\n vcvarsall: setupVCVarsall,\n kcov: setupKcov,\n make: setupMake,\n task: setupTask,\n sevenzip: setupSevenZip,\n \"7zip\": setupSevenZip,\n \"7z\": setupSevenZip,\n} as const\n\nexport type ToolName = keyof typeof setups\n\n/** The tools that can be installed */\nexport const tools = Object.keys(setups) as Array<ToolName>\n\n/** The possible inputs to the program */\nexport type Inputs = keyof typeof setups | \"compiler\" | \"architecture\" | \"timeout\"\n\n/** An array of possible inputs */\nexport const inputs: Array<Inputs> = [\"compiler\", \"architecture\", \"timeout\", ...tools]\n","import { execRootSync } from \"admina\"\nimport { addAptKeyViaURL, installAptPack } from \"setup-apt\"\nimport { installBrewPack } from \"setup-brew\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport async function setupBazel(version: string, _setupDir: string, _arch: string) {\n switch (process.platform) {\n case \"win32\": {\n // install bazelisk because it contains both\n return setupChocoPack(\"bazelisk\", version)\n }\n case \"darwin\": {\n // install bazelisk because it contains both\n return installBrewPack(\"bazelisk\", version)\n }\n case \"linux\": {\n if (isArch()) {\n throw new Error(\"installing bazel on Arch linux is not supported yet\")\n } else if (hasDnf()) {\n // https://bazel.build/install/redhat\n await setupDnfPack([{ name: \"dnf-plugins-core\" }])\n execRootSync(\"dnf\", [\"copr\", \"enable\", \"vbatts/bazel\"])\n return setupDnfPack([{ name: \"bazel4\" }])\n } else if (isUbuntu()) {\n // https://bazel.build/install/ubuntu\n const keyFileName = await addAptKeyViaURL({\n fileName: \"bazel-archive-keyring.gpg\",\n keyUrl: \"https://bazel.build/bazel-release.pub.gpg\",\n })\n execRootSync(\"bash\", [\n \"-c\",\n `echo \"deb [arch=amd64 signed-by=${keyFileName}] https://storage.googleapis.com/bazel-apt stable jdk1.8\" | tee /etc/apt/sources.list.d/bazel.list`,\n ])\n return installAptPack([{ name: \"bazel\", version }], true)\n }\n throw new Error(\"Unsupported linux distribution\")\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n}\n","import { setupPipPack } from \"../utils/setup/setupPipPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport function setupConan(version: string | undefined, _setupDir: string, _arch: string) {\n return setupPipPack(\"conan\", version)\n}\n","import { setupPipPack } from \"../utils/setup/setupPipPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport function setupMeson(version: string | undefined, _setupDir: string, _arch: string) {\n return setupPipPack(\"meson\", version)\n}\n","import { installAptPack } from \"setup-apt\"\nimport { installBrewPack } from \"setup-brew\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport function setupCcache(version: string, _setupDir: string, _arch: string) {\n switch (process.platform) {\n case \"win32\": {\n return setupChocoPack(\"ccache\", version)\n }\n case \"darwin\": {\n return installBrewPack(\"ccache\", version)\n }\n case \"linux\": {\n if (isArch()) {\n return setupPacmanPack(\"ccache\", version)\n } else if (hasDnf()) {\n return setupDnfPack([{ name: \"ccache\", version }])\n } else if (isUbuntu()) {\n return installAptPack([{ name: \"ccache\", version }])\n }\n throw new Error(\"Unsupported linux distribution\")\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n}\n","import { installBrewPack } from \"setup-brew\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport function setupSccache(version: string, _setupDir: string, _arch: string) {\n switch (process.platform) {\n case \"win32\": {\n return setupChocoPack(\"sccache\", version)\n }\n case \"linux\":\n case \"darwin\": {\n return installBrewPack(\"sccache\", version)\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n}\n","import { addPath } from \"envosman\"\nimport { installAptPack } from \"setup-apt\"\nimport { installBrewPack } from \"setup-brew\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport async function setupCppcheck(version: string | undefined, _setupDir: string, _arch: string) {\n switch (process.platform) {\n case \"win32\": {\n await setupChocoPack(\"cppcheck\", version)\n const binDir = await activateWinCppcheck()\n return { binDir }\n }\n case \"darwin\": {\n return installBrewPack(\"cppcheck\", version)\n }\n case \"linux\": {\n if (isArch()) {\n return setupPacmanPack(\"cppcheck\", version)\n } else if (hasDnf()) {\n return setupDnfPack([{ name: \"ccache\", version }])\n } else if (isUbuntu()) {\n return installAptPack([{ name: \"cppcheck\", version }])\n }\n throw new Error(\"Unsupported linux distribution\")\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n}\n\nasync function activateWinCppcheck() {\n const binDir = \"C:/Program Files/Cppcheck\"\n await addPath(binDir, rcOptions)\n return binDir\n}\n","import { setupPipPack } from \"../utils/setup/setupPipPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport function setupCpplint(version: string | undefined, _setupDir: string, _arch: string) {\n return setupPipPack(\"cpplint\", version)\n}\n","import { setupPipPack } from \"../utils/setup/setupPipPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport function setupFlawfinder(version: string | undefined, _setupDir: string, _arch: string) {\n return setupPipPack(\"flawfinder\", version)\n}\n","import { setupPipPack } from \"../utils/setup/setupPipPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport function setupLizard(version: string | undefined, _setupDir: string, _arch: string) {\n return setupPipPack(\"lizard\", version)\n}\n","import { join } from \"path\"\nimport { addPath } from \"envosman\"\nimport { installAptPack } from \"setup-apt\"\nimport { getBrewDir, installBrewPack } from \"setup-brew\"\nimport { rcOptions } from \"../cli-options.js\"\nimport { hasDnf } from \"../utils/env/hasDnf.js\"\nimport { isArch } from \"../utils/env/isArch.js\"\nimport { isUbuntu } from \"../utils/env/isUbuntu.js\"\nimport { setupChocoPack } from \"../utils/setup/setupChocoPack.js\"\nimport { setupDnfPack } from \"../utils/setup/setupDnfPack.js\"\nimport { setupPacmanPack } from \"../utils/setup/setupPacmanPack.js\"\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport async function setupMake(version: string, _setupDir: string, _arch: string) {\n switch (process.platform) {\n case \"win32\": {\n return setupChocoPack(\"make\", version)\n }\n case \"darwin\": {\n await installBrewPack(\"make\", version)\n\n const gnuBinDir = join(getBrewDir(), \"opt/make/libexec/gnubin\")\n await addPath(gnuBinDir, rcOptions)\n return { binDir: gnuBinDir }\n }\n case \"linux\": {\n if (isArch()) {\n return setupPacmanPack(\"make\", version)\n } else if (hasDnf()) {\n return setupDnfPack([{ name: \"make\", version }])\n } else if (isUbuntu()) {\n return installAptPack([{ name: \"make\", version }])\n }\n throw new Error(\"Unsupported linux distribution\")\n }\n default: {\n throw new Error(\"Unsupported platform\")\n }\n }\n}\n","#!/usr/bin/env node\n/* eslint-disable node/shebang */\n\nimport { GITHUB_ACTIONS, isCI } from \"ci-info\"\nimport { error, info, success, warning } from \"ci-log\"\nimport { finalizeRC } from \"envosman\"\nimport numerous from \"numerous\"\nimport numerousLocale from \"numerous/locales/en.js\"\nimport timeDelta from \"time-delta\"\nimport timeDeltaLocale from \"time-delta/locales/en.js\"\nimport { untildifyUser } from \"untildify-user\"\nimport { checkUpdates } from \"./check-updates.js\"\nimport { parseArgs, printHelp, rcOptions } from \"./cli-options.js\"\nimport { getCompilerInfo, installCompiler } from \"./compilers.js\"\nimport { installTool } from \"./installTool.js\"\nimport { type Inputs, llvmTools, tools } from \"./tool.js\"\nimport { isArch } from \"./utils/env/isArch.js\"\nimport { ubuntuVersion } from \"./utils/env/ubuntu_version.js\"\nimport { setupPacmanPack } from \"./utils/setup/setupPacmanPack.js\"\nimport { syncVersions } from \"./versions/versions.js\"\n\n/** The main entry function */\nasync function main(args: string[]): Promise<number> {\n let checkUpdatePromise = Promise.resolve()\n if (!GITHUB_ACTIONS) {\n checkUpdatePromise = checkUpdates()\n process.env.ACTIONS_ALLOW_UNSECURE_COMMANDS = \"true\"\n }\n\n // parse options using mri or github actions\n const opts = parseArgs(args)\n\n // print help\n if (opts.help) {\n printHelp()\n }\n\n // cpu architecture\n const arch = opts.architecture ?? process.arch\n\n // the installation dir for the tools that are downloaded directly\n const setupCppDir = process.env.SETUP_CPP_DIR ?? untildifyUser(\"~\")\n\n // report messages\n const successMessages: string[] = []\n const errorMessages: string[] = []\n\n const timeFormatter = timeDelta.create({ autoloadLocales: true })\n timeDelta.addLocale(timeDeltaLocale as timeDelta.Locale)\n numerous.addLocale(numerousLocale as numerous.Locale)\n let time1: number\n let time2: number\n\n // installing the specified tools\n\n const osVersion = await ubuntuVersion()\n\n const compilerInfo = opts.compiler !== undefined ? getCompilerInfo(opts.compiler) : undefined\n\n // sync the version for the llvm tools\n if (!syncVersions(opts, [...llvmTools, \"compiler\"] as Inputs[], compilerInfo)) {\n error(\"The same version must be used for llvm, clang-format and clang-tidy\")\n return 1\n }\n\n if (isArch() && typeof opts.cppcheck === \"string\" && typeof opts.gcovr === \"string\") {\n info(\"installing python-pygments to avoid conflicts with cppcheck and gcovr on Arch linux\")\n await setupPacmanPack(\"python-pygments\")\n }\n\n // loop over the tools and run their setup function\n\n let failedFast = false\n for (const tool of tools) {\n // fail fast inside CI when any tool fails\n if (isCI && errorMessages.length !== 0) {\n failedFast = true\n break\n }\n\n // get the version or \"true\" or undefined for this tool from the options\n const version = opts[tool]\n\n // skip if undefined\n if (version !== undefined) {\n // running the setup function for this tool\n time1 = Date.now()\n // eslint-disable-next-line no-await-in-loop\n await installTool(\n tool,\n version,\n osVersion,\n arch,\n setupCppDir,\n successMessages,\n errorMessages,\n Number.parseFloat(opts.timeout ?? \"20\") * 60 * 1000,\n )\n time2 = Date.now()\n info(`took ${timeFormatter.format(time1, time2) || \"0 seconds\"}`)\n }\n }\n\n if (!failedFast && compilerInfo !== undefined) {\n // install the specified compiler\n const time1Compiler = Date.now()\n await installCompiler(\n compilerInfo.compiler,\n compilerInfo.version,\n osVersion,\n setupCppDir,\n arch,\n successMessages,\n errorMessages,\n )\n const time2Compiler = Date.now()\n info(`took ${timeFormatter.format(time1Compiler, time2Compiler) || \"0 seconds\"}`)\n }\n\n await finalizeRC(rcOptions)\n\n if (successMessages.length === 0 && errorMessages.length === 0) {\n warning(\"setup-cpp was called without any arguments. Nothing to do.\")\n return 0\n }\n\n // report the messages in the end\n for (const tool of successMessages) {\n success(tool)\n }\n for (const tool of errorMessages) {\n error(tool)\n }\n\n info(\"setup-cpp finished\")\n\n if (!GITHUB_ACTIONS) {\n switch (process.platform) {\n case \"win32\": {\n warning(\"Run `RefreshEnv.cmd` or restart your shell to update the environment.\")\n break\n }\n case \"linux\":\n case \"darwin\": {\n warning(\"Run `source ~/.cpprc` or restart your shell to update the environment.\")\n break\n }\n default: {\n // nothing\n }\n }\n }\n\n await checkUpdatePromise\n\n return errorMessages.length === 0 ? 0 : 1 // exit with non-zero if any error message\n}\n\n// Run main\nmain(process.argv)\n .then((ret) => {\n process.exitCode = ret\n })\n .catch((err) => {\n error(\"main() panicked!\")\n error(err as string | Error)\n process.exitCode = 1\n })\n","import { warning } from \"ci-log\"\nimport updateNotifier from \"simple-update-notifier\"\nimport packageJson from \"../package-version.json\"\n\n// auto self update notifier\nexport async function checkUpdates() {\n try {\n await updateNotifier({ pkg: packageJson })\n } catch (err) {\n warning(`Failed to check for updates: ${err instanceof Error ? err.message + err.stack : err}`)\n }\n}\n","import { join } from \"path\"\nimport { endGroup, startGroup } from \"@actions/core\"\nimport { error, info } from \"ci-log\"\nimport semverValid from \"semver/functions/valid\"\nimport { getSuccessMessage } from \"./cli-options.js\"\nimport { setupGcc } from \"./gcc/gcc.js\"\nimport { setupMingw } from \"./gcc/mingw.js\"\nimport { activateGcovGCC, activateGcovLLVM } from \"./gcovr/gcovr.js\"\nimport { setupAppleClang } from \"./llvm/apple-clang.js\"\nimport { setupLLVM } from \"./llvm/llvm.js\"\nimport { setupMSVC } from \"./msvc/msvc.js\"\nimport { appleClangSetups, gccSetups, llvmSetups, mingwSetups, msvcSetups } from \"./tool.js\"\nimport type { InstallationInfo } from \"./utils/setup/setupBin.js\"\nimport { getVersion } from \"./versions/versions.js\"\n\nexport type CompilerInfo = {\n compiler: string\n version: string | undefined\n}\n\n/**\n * Detecting the compiler version. Divide the given string by `-` and use the second element as the version\n *\n * @param compilerAndVersion - The compiler and version string\n * @returns The compiler and version\n *\n * @nothrow It doesn't throw any error, but it logs the error if it fails to parse the compiler info\n */\nexport function getCompilerInfo(compilerAndVersion: string): CompilerInfo {\n try {\n const compilerAndMaybeVersion = compilerAndVersion.split(\"-\")\n const compiler = compilerAndMaybeVersion[0]\n if (1 in compilerAndMaybeVersion) {\n const maybeVersion = compilerAndMaybeVersion[1]\n if (semverValid(maybeVersion) === null) {\n info(`Invalid semver version ${maybeVersion} used for the compiler.`)\n }\n return { compiler, version: maybeVersion }\n }\n return { compiler, version: undefined }\n } catch (err) {\n error(`Failed to parse the compiler info ${compilerAndVersion}: ${err}`)\n return { compiler: compilerAndVersion, version: undefined }\n }\n}\n\n/** Installing the specified compiler */\nexport async function installCompiler(\n compiler: string,\n version: string | undefined,\n osVersion: number[] | null,\n setupCppDir: string,\n arch: string,\n successMessages: string[],\n errorMessages: string[],\n) {\n let installationInfo: InstallationInfo | undefined | void | null // null means the compiler is not supported\n try {\n // install the compiler. We allow some aliases for the compiler name\n startGroup(`Installing ${compiler} ${version ?? \"\"}`)\n if (compiler in llvmSetups) {\n installationInfo = await setupLLVM(\n getVersion(\"llvm\", version, osVersion),\n join(setupCppDir, \"llvm\"),\n arch,\n )\n await activateGcovLLVM()\n } else if (compiler in gccSetups) {\n const gccVersion = getVersion(\"gcc\", version, osVersion)\n installationInfo = await setupGcc(gccVersion, join(setupCppDir, \"gcc\"), arch)\n await activateGcovGCC(gccVersion)\n } else if (compiler in mingwSetups) {\n const gccVersion = getVersion(\"mingw\", version, osVersion)\n installationInfo = await setupMingw(gccVersion, join(setupCppDir, \"gcc\"), arch)\n await activateGcovGCC(gccVersion)\n } else if (compiler in msvcSetups) {\n installationInfo = await setupMSVC(\n getVersion(\"msvc\", version, osVersion),\n join(setupCppDir, \"msvc\"),\n arch,\n )\n } else if (compiler in appleClangSetups) {\n await setupAppleClang()\n } else {\n installationInfo = null\n errorMessages.push(`Unsupported compiler ${compiler}`)\n }\n } catch (err) {\n error(err as string | Error)\n errorMessages.push(`Failed to install the ${compiler} ${version}`)\n }\n\n if (installationInfo !== null) {\n successMessages.push(getSuccessMessage(compiler, installationInfo))\n }\n\n endGroup()\n}\n"],"names":["issueCommand","command","properties","message","cmd","Command","process","stdout","write","os","EOL","getProxyUrl","reqUrl","usingSsl","protocol","hostname","host","hostLower","toLowerCase","startsWith","isLoopbackAddress","noProxy","env","reqPort","port","Number","upperReqHosts","toUpperCase","push","upperNoProxyItem","split","map","x","trim","filter","some","endsWith","checkBypass","proxyVar","DecodedURL","TunnelingAgent","options","self","this","proxyOptions","proxy","maxSockets","http","Agent","defaultMaxSockets","requests","sockets","on","socket","localAddress","toOptions","i","len","length","pending","splice","request","onSocket","destroy","removeSocket","createSecureSocket","cb","prototype","createSocket","call","hostHeader","getHeader","tlsOptions","mergeOptions","servername","replace","secureSocket","tls","connect","indexOf","target","arguments","overrides","keys","Object","j","keyLen","k","__awaiter","thisArg","_arguments","P","generator","Promise","resolve","reject","fulfilled","value","step","next","e","rejected","result","done","then","apply","defineProperty","exports","summary","markdownSummary","SUMMARY_DOCS_URL","SUMMARY_ENV_VAR","os_1","require$$0","fs_1","require$$1","access","appendFile","writeFile","promises","_summary","constructor","_buffer","filePath","_filePath","pathFromEnv","Error","constants","R_OK","W_OK","_a","wrap","tag","content","attrs","htmlAttrs","entries","key","join","overwrite","writeFunc","encoding","emptyBuffer","clear","stringify","isEmptyBuffer","addRaw","text","addEOL","addCodeBlock","code","lang","assign","element","addList","items","ordered","listItems","item","addTable","rows","tableBody","row","cells","cell","header","data","colspan","rowspan","addDetails","label","addImage","src","alt","width","height","addHeading","level","includes","addSeparator","addBreak","addQuote","cite","addLink","href","rmRF","inputPath","ioUtil","IS_WINDOWS","test","rm","force","maxRetries","recursive","retryDelay","err","mkdirP","fsPath","assert_1$1","ok","mkdir","findInPath","tool","extensions","extension","path","delimiter","isRooted","tryGetExecutablePath","sep","directories","PATH","p","matches","directory","cpDirRecursive","sourceDir","destDir","currentDepth","files","readdir","fileName","srcFile","destFile","lstat","isDirectory","copyFile","chmod","stat","mode","isSymbolicLink","unlink","symlinkFull","readlink","symlink","exists","exec","commandLine","args","commandArgs","tr","argStringToArray","toolPath","slice","concat","ToolRunner","__createBinding","create","o","m","k2","enumerable","get","__setModuleDefault","v","__importStar","mod","__esModule","hasOwnProperty","exec_1","getExecOutput","string_decoder_1","toolrunner","events","child","require$$2","require$$3","io","require$$4","require$$5","timers_1","require$$6","platform","EventEmitter","_debug","listeners","debug","_getCommandString","noPrefix","_getSpawnFileName","_getSpawnArgs","_isCmdFile","a","windowsVerbatimArguments","_windowsQuoteCmdArg","_processLineBuffer","strBuffer","onLine","s","n","substring","argline","_endsWith","str","end","upperToolPath","arg","_uvQuoteCmdArg","cmdSpecialChars","needsQuotes","char","reverse","quoteHit","_cloneExecOptions","cwd","silent","failOnStdErr","ignoreReturnCode","delay","outStream","errStream","stderr","_getSpawnOptions","argv0","which","optionsNonNull","state","ExecState","cp","spawn","stdbuffer","line","stdline","errbuffer","processStderr","errline","processError","processExited","processClosed","CheckComplete","processExitCode","error","exitCode","emit","removeAllListeners","input","stdin","argString","append","c","escaped","inQuotes","charAt","timeout","_setResult","setTimeout","HandleTimeout","clearTimeout","_b","stdoutDecoder","StringDecoder","stderrDecoder","originalStdoutListener","originalStdErrListener","getInput","name","val","required","trimWhitespace","command_1","utils_1","toCommandProperties","startGroup","issue","endGroup","desc","getOwnPropertyDescriptor","writable","configurable","toPlatformPath","toWin32Path","toPosixPath","getIDToken","getState","saveState","group","info","notice","warning","isDebug","setFailed","setCommandEcho","setOutput","getBooleanInput","getMultilineInput","addPath","setSecret","exportVariable","ExitCode","file_command_1","oidc_utils_1","oidcUtils","OidcClient","http_client_1","auth_1","core_1","createHttpClient","allowRetry","maxRetry","requestOptions","allowRetries","HttpClient","BearerCredentialHandler","getRequestToken","token","getIDTokenUrl","runtimeUrl","getCall","id_token_url","httpclient","res","getJson","catch","statusCode","id_token","audience","encodeURIComponent","convertedVal","toCommandValue","issueFileCommand","prepareKeyValueMessage","secret","inputs","TypeError","enabled","Failure","fn","aud","summary_1","summary_2","path_utils_1","pathUtils","pth","require$$7","__importDefault","default","getDetails","isMacOS","isWindows","arch","isLinux","version","_c","_d","match","GITHUB_ACTIONS","core.error","console","log","msg","core.warning","core.notice","core.info","isPlainObject","getPrototypeOf","Symbol","toStringTag","iterator","isexe","er","is","core","ignoreErrors","resolveCommandAttempt","parsed","withoutPathExt","hasCustomCwd","shouldSwitchCwd","chdir","disabled","resolved","sync","getPathKey","pathExt","notFoundError","original","syscall","errno","spawnargs","verifyENOENT","status","isWin","file","parse","spawned","enoent","hookChildProcess","pathKey","find","toPath","urlOrPath","URL","fileURLToPath","stripFinalNewline","stripFinalNewlineString","ArrayBuffer","isView","BYTES_PER_ELEMENT","stripFinalNewlineBinary","isStream","stream","checkOpen","readable","pipe","isWritableStream","writableObjectMode","destroyed","isReadableStream","read","readableObjectMode","isDuplexStream","r","return","h","preventCancel","getReader","t","u","prettyMilliseconds","milliseconds","isBigInt","isFinite","sign","colonNotation","compact","formatSubMilliseconds","separateMilliseconds","verbose","unitCount","secondsDecimalDigits","millisecondsDecimalDigits","add","long","short","valueString","isZero","String","wholeDigits","repeat","Math","max","word","count","days","trunc","hours","minutes","seconds","microseconds","toZeroIfInfinity","nanoseconds","parseNumber","parseBigint","parseMilliseconds","BigInt","millisecondsAndBelow","roundedMilliseconds","ceil","round","millisecondsString","toFixed","parseFloat","secondsFixed","floor","decimalDigits","secondsString","keepDecimalsOnWholeSeconds","separator","mergeStreams","streams","Array","isArray","validateStream","objectMode","highWaterMark","getHighWaterMark","passThroughStream","MergedStream","writableHighWaterMark","readableHighWaterMark","execPowershell","startupFlags","execOptions","stdio","execa.execa","powershell","maybePwsh","nothrow","maybePowerShell","getPowerShell","_write","_writableState","async","getStream","inputStream","maxBuffer","Infinity","bufferStream","rejectPromise","getBufferedLength","BufferConstants","MAX_LENGTH","bufferedData","getBufferedValue","streamPipelinePromisified","MaxBufferError","execa","handleArguments","joinCommand","escapedCommand","getEscapedCommand","logCommand","validateTimeout","childProcess","dummySpawned","ChildProcess","errorPromise","makeError","all","timedOut","isCanceled","killed","mergePromise","spawnedPromise","signal","getSpawnedPromise","timedPromise","killSignal","timeoutId","timeoutPromise","kill","timeoutKill","safeSpawnedPromise","finally","race","setupTimeout","processDone","cleanup","detached","removeExitHandler","onExit","setExitHandler","spawnedKill","bind","cancel","spawnedCancel","handlePromiseOnce","onetime","stdoutResult","stderrResult","allResult","buffer","stdoutPromise","getStreamPromise","stderrPromise","allPromise","getBufferedData","getSpawnedResult","handleOutput","returnedError","aborted","failed","inputFile","validateInputOptions","createReadStream","handleInput","mixed","mergeStream","makeAllStream","pipeStdout","pipeToTarget","pipeStderr","pipeAll","addPipeMethods","execaSync","readFileSync","getInputSync","handleInputSync","spawnSync","set","getuid","CI","parseCommand","b","l","y","S","f","R","SUDO_USER","w","statSync","getOwnPropertyNames","getOwnPropertySymbols","mixin$1","source","sourceObject","forEach","symbol","globalThis_1","isImplemented","globalThis","naiveFallback","window","implementation","__global__","isSymbol","validateSymbol","es6Symbol","global","validTypes","object","toPrimitive","SymbolPolyfill","HiddenSymbol","isNativeSafe","d","NativeSymbol","generateName","objPrototype","created","ie11BugWorkaround","postfix","gs","setupStandardSymbols","standardSymbols","defineProperties","hasInstance","isConcatSpreadable","search","species","unscopables","setupSymbolRegistry","registry","symbolRegistry","for","keyFor","ignore","description","polyfill","__description__","__name__","toString","valueOf","from","arr","iteratorSymbol","isArguments","objToString","id","isFunction","isFunctionStringTag","RegExp","toPosInt","callable","validValue","isValue","isString","Function","shim","arrayLike","Context","getIterator","mapFn","charCodeAt","numberIsNaN","isNan","isNaN","NaN","objHasOwnProperty","abs","eIndexOf","searchElement","fromIndex","obj","targetObj","index","ensureCallable","byObserver","Observer","queue","currentQueue","node","document","createTextNode","callback","shift","observe","characterData","nextTick","queueMicrotask","MutationObserver","WebKitMutationObserver","setImmediate","isCallable","isPromise","isPromiseModule","objectMap","primitiveSet","ensureString","ensureValue","stringifiable","validateStringifiable","validateStringifiableValue","toShortString","safeToString","toShortStringRepresentation","string","JSON","supportedModes","registeredExtensions","promise","conf","waiting","cache","isFailed","onSuccess","onFailure","delete","resolvedMode","nextTickFailure","context","oldCache","pathExists","fsPromises","untildifyUser","maybeHomeDir","isSudo","homedir","userHomeDir","tildeRegex","addRCHeader","rcHeader","guard","rcPath","readFile","addSourceToTargetRc","sourceRcString","targetRcPath","addEnv","valGiven","givenOptions","escapeSpace","defaultRcPath","shouldEscapeSpace","spaceEscaped","escapeQuote","escapeString","addEnvSystem","sourceRCInRc","ignoredPaths","checkedPath","isIgnoredPath","ghAddPath","addPathSystem","addLocale","localeData","locales","pluralize","unit","config","unitTypeData","locale","lookupOrder","unitTypeLookupOrder","unshift","unitType","Set","getLocaleDataForUnitType","numerous","SPACE_CHARACTERS","Range","range","parseOptions","loose","includePrerelease","raw","Comparator","formatted","parseRange","first","isNullSet","isAny","comps","format","memoKey","FLAG_INCLUDE_PRERELEASE","FLAG_LOOSE","cached","re","HYPHENRANGELOOSE","HYPHENRANGE","hyphenReplace","COMPARATORTRIM","comparatorTrimReplace","TILDETRIM","tildeTrimReplace","CARETTRIM","caretTrimReplace","rangeList","comp","parseComparator","replaceGTE0","COMPARATORLOOSE","rangeMap","Map","comparators","size","has","values","intersects","thisComparators","isSatisfiable","rangeComparators","every","thisComparator","rangeComparator","SemVer","testSet","safeRe","remainingComparators","testComparator","pop","otherComparator","replaceCarets","replaceTildes","replaceXRanges","replaceStars","isX","replaceTilde","TILDELOOSE","TILDE","_","M","pr","ret","replaceCaret","z","CARETLOOSE","CARET","replaceXRange","XRANGELOOSE","XRANGE","gtlt","xM","xm","xp","STAR","GTE0PRE","GTE0","incPr","$0","fM","fm","fp","fpr","fb","to","tM","tm","tp","tpr","prerelease","semver","ANY","allowed","major","minor","patch","operator","COMPARATOR","cmp","__generator","body","verb","op","g","ops","trys","sent","throw","toArr","any","toVal","out","opts","old","nxt","boolean","addUpdateAlternativesToRc","rcOptions","priority","execRoot","updateAptAlternatives","sourceRC","getAptEnv","apt","DEBIAN_FRONTEND","LANG","LC_ALL","hasNala","getApt","escapeStringRegexp","isAptPackInstalled","pack","filterAndQualifyAptPackages","packages","qualifiedNeededAptPackage","qualified","aptPackageType","AptPackageType","NameDashVersion","NameEqualsVersion","Name","getAptArg","escapeRegex","showStdout","updatedRepos","None","updateAptReposMemoized","installAptPack","update","allRepositories","flatMap","repository","repo","initAptMemoized","execRootSync","aptTimeout","defaultExecOptions","installAddAptRepo","addAptRepository","addRepositories","needToInstall","binDir","addAptKeyViaURL","keyServer","defaultKeyServer","keyStorePath","assertGpgFileName","addAptKeyViaServer","addAptKeys","isExecaError","retryErrors","stack","keyUrl","defaultKeyStorePath","dlPath","tmpdir","dl","DownloaderHelper","start","initGpg","s$1","setupBrew","maybeBinDir","dirname","getDownloadPath","NONINTERACTIVE","getBrewBinDir","getBrewDir","installBrewPack","cask","hasBrew","brewPath","hasDnf","hasDnfCache","isArch","isArchCache","isUbuntu","isUbuntuCache","setupChocolatey","_version","_setupDir","_arch","SystemRoot","chocoPath","ALLUSERSPROFILE","maybeChoco","ChocolateyInstall","setupChocoPack","hasChoco","TMP","TEMP","Path","extendEnv","setupDnfPack","getDnfArg","setupPacmanPack","aur","pacman","yayBuildDir","isRoot","createdBuilderUser","didUpdate","didInit","runInstall","availableVersions","matchAll","pacmanSiVersionRegex","availablePacmanVersions","E","N","findAllVersions","toolName","versions","_getCacheDirectory","fs","existsSync","children","readdirSync","isExplicitVersion","fullPath","_createExtractFolder","dest","_getTempDirectory","v4_1","_createToolPath","folderPath","clean","core$1","markerPath","_completeToolPath","fs$1","writeFileSync","versionSpec","valid","evaluateVersions","sort","gt","potential","satisfies","cacheDirectory","assert_1","tempDirectory","_getGlobal","defaultValue","retryAsPromised","optionsInput","$current","backoffBase","backoffExponent","report","Date","toLocaleTimeString","backoffTimeout","lastError","TimeoutError","current","shouldRetry","pow","setupSevenZip","getArchiveType","ext","extract7Zip","sevenZip","getSevenZip","grantUserWriteAccess","extractExe","extractZip","extractTarByExe","stripComponents","flags","archiveType","installTarDependencies","setupBin","getPackageInfo","setupDir","RUNNER_TEMP","RUNNER_TOOL_CACHE","url","binRelativeDir","binFileName","extractedFolderName","extractFunction","dir","installDir","binFile","givenExtractFunction","downloaded","retry","downloadedFilePath","now","basename","downloadTool","tryDownload","getExtractFunction","downloadExtractInstall","maybeGetInput","CACHE_TOOLS","cacheDir","cacheInstallation","getCmakePackageInfo","semVersion","semverCoerce","isOld","semverLte","osArchStr","x86_64","x86","arm64","folderName","addExeExt","setupCmake","isBinUptoDate","givenFile","targetVersion","versionRegex","defaultVersionRegex","givenVersion","execout","version_output","getBinVersion","semverCompare","quoteIfHasSpace","quoteChar","setupPython","installInfo","foundPython","findPython","bin","setupActionsPython","import","brewPythonPrefix","brewPythonBin","setupPythonSystem","findOrSetupPython","require$$0$2","foundPip","maybePip","findPip","ensurePipUpgrade","setupPipPackSystem","setupPip","findOrSetupPip","hasPipx","setupPipPackWithPython","upgrade","usePipx","setupVenv","setupPipx","isLibrary","setupWheel","pythonBin","isPythonUpToDate","rootDir","pathParse","root","pythonDirs","pythonDir","candidate","pythonBinPath","MinVersions","pythonBinPaths","pipCandidate","isPipUptoDate","pip","pipPaths","pipPath","err1","err2","getVersion","osVersion","isVersionDefault","DefaultUbuntuVersion","toolLinuxVersions","osVersionMaj","satisfyingVersion","parseInt","getDefaultLinuxVersion","DefaultVersions","detectUsingOsVersion","versionMatch","setupPipPack","ubuntuVersion","getPython","givenPython","user","isPipx","nameOnly","installed","python","pipxOut","venvs","venv","metadata","main_package","package_or_url","package","pipxPackageInstalled","pipPackageIsInstalled","finishPipxPackageInstall","finishPipPackageInstall","hasPackage","pipHasPackage","nameAndVersion","upgradeFlag","userFlag","PIPX_HOME","getPipxHome","PIPX_BIN_DIR","getPipxBinDir","pythonBaseExecPrefix","addPythonBaseExecPrefix","dirs","dirIndex","findIndex","exist","whichDir","findBinDir","addPythonPrefix","setupCmakelang","setupGraphviz","activateGraphviz","setupDmg","ArchiveHdi","dmg","entry","extract","getDoxygenPackageInfo","setupMacOSSDK","xcrun","sdkroot","addGccLoggingMatcher","matcherPath","loadAssetList","matchAsset","assets","origTags","versionMap","filterMapTag","origTag","mappedTag","versionSatisfies","semverSatisfies","versionRange","semverValid","coercedVersion","semverCoercedRangeIfInvalid","candidateTags","candidateTag","assetNames","filterName","matchAssetName","keywords","optionalKeywords","candidates","keyword","candidateScores","score","maxScore","setupMingw","installationInfo","getMinGWPackageInfo","setupChocoMingw","activateMinGW","mingwAssets","runtime","extractMinGWRuntime","threadModel","extractMinGWThreadModel","exceptionModel","extractMingwExceptionModel","asset","x64","ia32","assetName","assetVersion","assetCoerce","setupGcc","gccExe","exe1","exe2","tag1","tag2","v1","v2","compare","localeCompare","compareVersion","versionStdout","getGccCmdVersion","majorVersion","semverMajor","activateGcc","activateGcovGCC","gccVersion","gccSemver","gccMajor","getInferPackageInfo","getAssetKeywords","ghAsset","getNinjaPackageInfo","ninjaPlatform","getNinjaPlatformArch","setupNinja","getDownloadKcovPackageInfo","getBuildKcovPackageInfo","buildKcov","cmake","getCmake","buildDir","setupAppleClang","vsversion_to_versionnumber","vsversion","VsYearVersion","vsversion_to_year","year","ver","findVcvarsall","vsversion_number","version_pattern","upper_bound","pattern","child_process","execSync","installationPath","findWithVswhere","years","YEARS","prog_files","PROGRAM_FILES","ed","EDITIONS","PROGRAM_FILES_X86","isPathVariable","setupVCVarsall","VCTargetsPath","toolset","sdk","uwp","spectre","setupMSVCDevCmd","getArch","installTool","setupCppDir","successMessages","errorMessages","fallback","customTimers","timer","cancelablePromise","getAbortedReason","addEventListener","timeoutError","pTimeout","hasLLVM","llvmTools","setupVersion","setupFunction","setups","getSuccessMessage","installToolImpl","getLLVMPackageInfo","ubuntuVer","ubuntuMin","armv7","powerpc64le","sparc64","websiteAsset","getLLVMAssetURL","setupLLVM","setupLLVMWithoutActivation","ld","LD_LIBRARY_PATH","dyld","DYLD_LIBRARY_PATH","llvmMajor","majorLLVMVersion","actPromises","activateLLVM","setupClangFormat","setupLLVMOnly","LLVMPackages","ClangFormat","setupClangTools","All","installationFolder","installerScript","installerPath","neededPackages","givenScript","target_path","script","NODE_DEBUG","debugScript","nonInteractiveScript","choosePackages","installingPack","regexp","isAptPackRegexInstalled","info$1","removeConflictingPackages","useNalaScript","patchAptLLVMScript","shell","setupLLVMApt","llvmBinaryDeps","coeredVersion","semverCoerceIfInvalid","addLLVMLoggingMatcher","setupMSVC","versionGiven","vcvarsall_path","addMSVCLoggingMatcher","setupOpencppcoverage","activateOpencppcoverage","getPowerShellPackageInfo","getPowershellUrl","arm","arm32","aarch64","setupPowershell","ubuntuVerSplitted","setupPowershellSystem","getTaskPackageInfo","taskPlatform","getTaskPlatform","taskArch","getTaskArch","checkEnv","vendors","constant","isPR","vendor","isCI","ne","BUILD_ID","BUILD_NUMBER","CI_APP_ID","CI_BUILD_ID","CI_BUILD_NUMBER","CI_NAME","CONTINUOUS_INTEGRATION","RUN_ID","utils","annotationProperties","title","startLine","endLine","col","startColumn","endColumn","__createBinding$4","cmdStr","escapeData","__createBinding$3","fileCommand","crypto","fs$4","appendFileSync","randomUUID","convertedValue","_decodedUsername","_decodedPassword","base","super","decodeURIComponent","username","password","https","util","tunnel","httpOverHttp","agent","httpsOverHttp","defaultPort","httpOverHttps","httpsOverHttps","inherits","addRequest","req","onFree","onCloseOrRemove","removeListener","onConnect","head","connectReq","placeholder","connectOptions","method","headers","proxyAuth","Buffer","useChunkedEncodingByDefault","once","cause","pos","HttpCodes","Headers","MediaTypes","HttpRedirectCodes","MovedPermanently","ResourceMoved","SeeOther","TemporaryRedirect","PermanentRedirect","HttpResponseRetryCodes","BadGateway","ServiceUnavailable","GatewayTimeout","RetryableHttpVerbs","HttpClientError","setPrototypeOf","HttpClientResponse","readBody","output","alloc","chunk","readBodyBuffer","chunks","userAgent","handlers","_ignoreSslError","_socketTimeout","_allowRedirects","_allowRedirectDowngrade","_maxRedirects","_allowRetries","_maxRetries","_agent","_proxyAgent","_proxyAgentDispatcher","_keepAlive","_disposed","ignoreSslError","socketTimeout","allowRedirects","allowRedirectDowngrade","maxRedirects","keepAlive","requestUrl","additionalHeaders","del","post","put","sendStream","Accept","_getExistingOrDefaultHeader","ApplicationJson","_processResponse","postJson","ContentType","putJson","patchJson","parsedUrl","_prepareRequest","maxTries","response","numTries","requestRaw","Unauthorized","authenticationHandler","handler","canHandleAuthentication","handleAuthentication","redirectsRemaining","redirectUrl","parsedRedirectUrl","_performExponentialBackoff","dispose","requestRawWithCallback","onResult","handleResult","callbackCalled","byteLength","httpModule","sock","getAgent","serverUrl","_getAgent","getAgentDispatcher","proxyUrl","pm.getProxyUrl","_getProxyAgentDispatcher","pathname","_mergeHeaders","prepareRequest","lowercaseKeys","_default","clientHeader","useProxy","globalAgent","agentOptions","tunnelAgent","overHttps","tunnel.httpsOverHttps","tunnel.httpsOverHttp","tunnel.httpOverHttps","tunnel.httpOverHttp","rejectUnauthorized","proxyAgent","uri","pipelining","requestTls","retryNumber","ms","min","contents","NotFound","deserializeDates","reduce","auth","PersonalAccessTokenCredentialHandler","BasicCredentialHandler","isUnixExecutable","stats","gid","getgid","uid","getCmdPath","UV_FS_O_EXLOCK","rmdir","rename","open","READONLY","O_RDONLY","useStat","normalizeSeparators","isFile","upperExt","extname","validExt","originalFilePath","upperName","actualName","__createBinding$2","mkdirP_1","mv","copySourceDirectory","readCopyOptions","destStat","newDest","relative","destExists","check","ciInfo","safeNormalizeFileUrl","fileString","normalizeFileUrl","normalizeDenoExecPath","isDenoExecPath","normalizeParameters","rawFile","rawArguments","rawOptions","commandArguments","commandArgument","normalizedArguments","nullByteArgument","normalizedArgument","objectToString","isUint8Array","bufferToUint8Array","Uint8Array","byteOffset","textEncoder","TextEncoder","stringToUint8Array","encode","textDecoder","TextDecoder","uint8ArrayToString","uint8Array","decode","joinToUint8Array","uint8ArraysOrStrings","concatUint8Arrays","stringsToUint8Arrays","uint8ArrayOrString","uint8Arrays","getJoinLength","joinLength","parseTemplate","templates","expressions","tokens","template","nextTokens","leadingWhitespaces","trailingWhitespaces","splitByWhitespaces","newTokens","concatTokens","expression","expressionTokens","parseExpression","rawTemplate","templateStart","DELIMITERS","templateIndex","rawIndex","rawCharacter","nextRawCharacter","ESCAPE_LENGTH","isSeparated","at","typeOfExpression","getSubprocessResult","isStandardStream","STANDARD_STREAMS","STANDARD_STREAMS_ALIASES","getStreamName","fdNumber","normalizeFdSpecificOption","optionName","optionBaseArray","getStdioLength","optionArray","normalizeFdSpecificValue","addDefaultValue","optionValue","normalizeOptionObject","fill","fdName","compareFdName","parseFdName","fdNameA","fdNameB","getFdNameOrder","parseFd","regexpResult","FD_REGEXP","DEFAULT_OPTIONS","lines","debuglog","FD_SPECIFIC_OPTIONS","getFdSpecificValue","isVerbose","getFdVerbose","isFullVerbose","getFdGenericVerbose","isVerboseFunction","fdVerbose","VERBOSE_VALUES","findLast","escapeLines","stripVTControlCharacters","escapeControlCharacters","replaceAll","SPECIAL_CHAR_REGEXP","character","escapeControlCharacter","commonEscape","COMMON_ESCAPES","codepoint","codePointAt","codepointHex","ASTRAL_START","padStart","getSpecialCharRegExp","NO_ESCAPE_REGEXP","common","circleQuestionMark","questionMarkPrefix","square","squareDarkShade","squareMediumShade","squareLightShade","squareTop","squareBottom","squareLeft","squareRight","squareCenter","bullet","dot","ellipsis","pointerSmall","triangleUp","triangleUpSmall","triangleDown","triangleDownSmall","triangleLeftSmall","triangleRightSmall","home","heart","musicNote","musicNoteBeamed","arrowUp","arrowDown","arrowLeft","arrowRight","arrowLeftRight","arrowUpDown","almostEqual","notEqual","lessOrEqual","greaterOrEqual","identical","infinity","subscriptZero","subscriptOne","subscriptTwo","subscriptThree","subscriptFour","subscriptFive","subscriptSix","subscriptSeven","subscriptEight","subscriptNine","oneHalf","oneThird","oneQuarter","oneFifth","oneSixth","oneEighth","twoThirds","twoFifths","threeQuarters","threeFifths","threeEighths","fourFifths","fiveSixths","fiveEighths","sevenEighths","lineBold","lineDouble","lineDashed0","lineDashed1","lineDashed2","lineDashed3","lineDashed4","lineDashed5","lineDashed6","lineDashed7","lineDashed8","lineDashed9","lineDashed10","lineDashed11","lineDashed12","lineDashed13","lineDashed14","lineDashed15","lineVertical","lineVerticalBold","lineVerticalDouble","lineVerticalDashed0","lineVerticalDashed1","lineVerticalDashed2","lineVerticalDashed3","lineVerticalDashed4","lineVerticalDashed5","lineVerticalDashed6","lineVerticalDashed7","lineVerticalDashed8","lineVerticalDashed9","lineVerticalDashed10","lineVerticalDashed11","lineDownLeft","lineDownLeftArc","lineDownBoldLeftBold","lineDownBoldLeft","lineDownLeftBold","lineDownDoubleLeftDouble","lineDownDoubleLeft","lineDownLeftDouble","lineDownRight","lineDownRightArc","lineDownBoldRightBold","lineDownBoldRight","lineDownRightBold","lineDownDoubleRightDouble","lineDownDoubleRight","lineDownRightDouble","lineUpLeft","lineUpLeftArc","lineUpBoldLeftBold","lineUpBoldLeft","lineUpLeftBold","lineUpDoubleLeftDouble","lineUpDoubleLeft","lineUpLeftDouble","lineUpRight","lineUpRightArc","lineUpBoldRightBold","lineUpBoldRight","lineUpRightBold","lineUpDoubleRightDouble","lineUpDoubleRight","lineUpRightDouble","lineUpDownLeft","lineUpBoldDownBoldLeftBold","lineUpBoldDownBoldLeft","lineUpDownLeftBold","lineUpBoldDownLeftBold","lineUpDownBoldLeftBold","lineUpDownBoldLeft","lineUpBoldDownLeft","lineUpDoubleDownDoubleLeftDouble","lineUpDoubleDownDoubleLeft","lineUpDownLeftDouble","lineUpDownRight","lineUpBoldDownBoldRightBold","lineUpBoldDownBoldRight","lineUpDownRightBold","lineUpBoldDownRightBold","lineUpDownBoldRightBold","lineUpDownBoldRight","lineUpBoldDownRight","lineUpDoubleDownDoubleRightDouble","lineUpDoubleDownDoubleRight","lineUpDownRightDouble","lineDownLeftRight","lineDownBoldLeftBoldRightBold","lineDownLeftBoldRightBold","lineDownBoldLeftRight","lineDownBoldLeftBoldRight","lineDownBoldLeftRightBold","lineDownLeftRightBold","lineDownLeftBoldRight","lineDownDoubleLeftDoubleRightDouble","lineDownDoubleLeftRight","lineDownLeftDoubleRightDouble","lineUpLeftRight","lineUpBoldLeftBoldRightBold","lineUpLeftBoldRightBold","lineUpBoldLeftRight","lineUpBoldLeftBoldRight","lineUpBoldLeftRightBold","lineUpLeftRightBold","lineUpLeftBoldRight","lineUpDoubleLeftDoubleRightDouble","lineUpDoubleLeftRight","lineUpLeftDoubleRightDouble","lineUpDownLeftRight","lineUpBoldDownBoldLeftBoldRightBold","lineUpDownBoldLeftBoldRightBold","lineUpBoldDownLeftBoldRightBold","lineUpBoldDownBoldLeftRightBold","lineUpBoldDownBoldLeftBoldRight","lineUpBoldDownLeftRight","lineUpDownBoldLeftRight","lineUpDownLeftBoldRight","lineUpDownLeftRightBold","lineUpBoldDownBoldLeftRight","lineUpDownLeftBoldRightBold","lineUpBoldDownLeftBoldRight","lineUpBoldDownLeftRightBold","lineUpDownBoldLeftBoldRight","lineUpDownBoldLeftRightBold","lineUpDoubleDownDoubleLeftDoubleRightDouble","lineUpDoubleDownDoubleLeftRight","lineUpDownLeftDoubleRightDouble","lineCross","lineBackslash","lineSlash","mainSymbols","tick","cross","squareSmall","squareSmallFilled","circle","circleFilled","circleDotted","circleDouble","circleCircle","circleCross","circlePipe","radioOn","radioOff","checkboxOn","checkboxOff","checkboxCircleOn","checkboxCircleOff","pointer","triangleUpOutline","triangleLeft","triangleRight","lozenge","lozengeOutline","hamburger","smiley","mustache","star","play","nodejs","oneSeventh","oneNinth","oneTenth","fallbackSymbols","figures","TERM","TERM_PROGRAM","WT_SESSION","TERMINUS_SUBLIME","ConEmuTask","TERMINAL_EMULATOR","isUnicodeSupported","hasColors","tty","WriteStream","close","openCode","closeCode","lastIndex","bold","gray","redBright","yellowBright","padField","field","padding","getFinalIcon","ICONS","piped","ipc","duration","identity","COLORS","applyVerboseFunction","verboseLine","verboseObject","verboseFunction","printedLine","appendNewline","verboseLog","type","verboseMessage","verboseInfo","getVerboseObject","finalLines","printedLines","getVerboseFunction","applyVerboseOnLines","getPrintedLines","STDERR_FD","commandId","timestamp","getPrintedLine","timestampString","getHours","getMinutes","getSeconds","getMilliseconds","serializeTimestamp","icon","color","defaultVerboseFunction","serializeVerboseMessage","messageString","inspect","TAB_SIZE","getCommandId","COMMAND_ID","getStartTime","hrtime","bigint","getDurationMs","startTime","handleCommand","fileAndArguments","fileAndArgument","quoteString","escapedArgument","allowedValues","allowedValue","validateVerbose","getVerboseInfo","TESTING_WINDOWS","checkStat","checkPathExt","pathext","PATHEXT","substr","checkMode","myUid","myGid","ug","isexe_1","OSTYPE","COLON","getNotFoundError","getPathInfo","opt","colon","pathEnv","pathExtExe","found","ppRaw","pathPart","pCmd","subStep","ii","which_1","cur","ex","environment","pathKeyModule","metaCharsRegExp","_escape","argument","doubleEscapeMetaChars","shebangRegex","resolveCommand","escape","readShebang","fd","openSync","readSync","closeSync","binary","shebangCommand","isExecutableRegExp","isCmdShimRegExp","commandFile","shebang","detectShebang","needsShell","forceShell","needsDoubleEscapeMetaChars","normalize","shellCommand","comspec","parseNonShell","originalEmit","arg1","verifyENOENTSync","crossSpawnModule","_parse","_enoent","promisify","execFileCallback","npmRunPathEnv","pathName","pathOption","preferLocal","execPath","addExecPath","cwdPath","pathParts","startPath","previousPath","currentPath","traversePathUp","applyPreferLocal$1","applyExecPath$1","npmRunPath","DiscardedError","setErrorName","ErrorClass","execaErrorSymbol","isErrorInstance","ExecaError","ExecaSyncError","getRealtimeSignal","number","SIGRTMIN","action","standard","SIGNALS","forced","getSignals","realtimeSignals","normalizeSignal","defaultNumber","signals","name2","constantSignal","supported","getSignalByName","signalsByName","fromEntries","getSignalsByName","findSignalByNumber","signalA","signalsA","SIGRTMAX","getSignalByNumber","getSignalsByNumber","normalizeSignalArgument","signalNameOrInteger","isInteger","normalizeSignalInteger","normalizeSignalName","getAvailableSignals","signalInteger","signalsIntegerToName","signalName","getAvailableSignalNames","getAvailableSignalIntegers","signalIntegerTwo","getSignalDescription","subprocessKill","forceKillAfterDelay","onInternalError","controller","signalOrError","errorArgument","parseKillArguments","emitKillError","killResult","setKillTimeout$1","setKillTimeout","killOnTimeout","controllerSignal","isForcefullyTerminated","onAbortedSignal","mainSignal","stopSignal","throwOnCancel","subprocess","cancelSignal","gracefulCancel","terminateOnCancel","terminationReason","reason","validateIpcMethod","methodName","isSubprocess","isConnected","validateIpcOption","validateConnection","getMethodName","getOtherProcessName","getStrictResponseError","SERIALIZATION_ERROR_CODES","SERIALIZATION_ERROR_MESSAGES","parameters","getNamespaceName","disconnect","anyProcess","connected","createDeferred","methods","getToStream","destination","isWritable","fileDescriptors","SUBPROCESS_OPTIONS","getFdNumber","destinationStream","getInvalidStdioOptionMessage","getFromStream","sourceStream","WeakMap","parseFdNumber","validateFdNumber","validOptions","getOptionName","fileDescriptor","getUsedDescriptor","direction","getInvalidStdioOption","serializeOptionValue","usedDescriptor","incrementMaxListeners","eventEmitter","maxListenersIncrement","maxListeners","getMaxListeners","setMaxListeners","addAbortListener","addReference","channel","reference","addReferenceCount","refCounted","removeReference","removeReferenceCount","unrefCounted","onMessage","ipcEmitter","wrappedMessage","handleStrictResponse","handleAbort","INCOMING_MESSAGES","incomingMessages","waitForOutgoingMessages","scheduler","yield","handleStrictRequest","onDisconnect","boundOnMessage","redoAddedReferences","getIpcEmitter","IPC_EMITTERS","forwardEvents","undoAddedReferences","validateStrictDeadlock","outgoingMessages","REQUEST_TYPE","hasListeners","STRICT_RESPONSES","isDeadlock","RESPONSE_TYPE","hasMessageListeners","sendMessage","waitForStrictResponse","deferred","AbortController","throwOnDisconnect","throwOnStrictDeadlockError","throwOnMissingStrict","abort","throwOnStrictDisconnect","OUTGOING_MESSAGES","onMessageSent","listenerCount","getMinListenerCount","strict","sendMessageAsync","handleSendStrict","outgoingMessagesState","outgoingMessage","startSendMessage","sendOneMessage","endSendMessage","sendMethod","getSendMethod","handleEpipeError","serializationErrorMessage","isSerializationError","handleSerializationError","PROCESS_SEND_METHODS","send","getCancelSignal","startIpc","cancelController","cancelListening","GRACEFUL_CANCEL_TYPE","abortOnDisconnect","throwOnGracefulCancel","sendOnAbort","getReason","sendAbort","DOMException","throwOnTimeout","killAfterTimeout","validateIpcInput","advanced","ipcInput","serialize","json","sendIpcInput","TEXT_ENCODINGS","BINARY_ENCODINGS","ENCODINGS","ENCODING_ALIASES","ucs2","serializeEncoding","getDefaultCwd","normalizeOptions","cwdString","normalizeCwd","processedFile","processedArguments","processedOptions","shouldHandleNode","nodePath","nodeOptions","execArgv","nodeOption","formerNodePath","normalizedNodePath","resolvedNodePath","newOptions","handleNodeOption","initialOptions","crossSpawn","fdOptions","optionsCopy","normalizeFdSpecificOptions","addDefaultOptions","correctEncoding","lowerEncoding","getCorrectEncoding","correctEncodings","validateEncoding","serialization","validateIpcInputOption","validateCancelSignal","validateGracefulCancel","getEnv","normalizeKillSignal","DEFAULT_FORCE_KILL_TIMEOUT","normalizeForceKillAfterDelay","localDir","localDirectory","windowsHide","envOption","LF","CR","LF_BINARY","subarray","CR_BINARY","c$2","releaseLock","getAsyncIterable","nodeImports","getStreamIterable","asyncIterator","handleStreamEnd","finished","getStreamContents","init","convertChunk","getSize","truncateChunk","addChunk","getFinalChunk","finalize","asyncIterable","convertedChunk","getChunkType","appendChunk","appendFinalChunk","normalizedError","chunkSize","newLength","addNewChunk","truncatedChunk","typeOfChunk","isBuffer","prototypeName","noop","getContentsProperty","throwObjectStream","getLengthProperty","arrayMethods","arrayBuffer","dataView","typedArray","others","useUint8Array","useUint8ArrayWithOffset","getNewContentsLength","SCALE_FACTOR","hasArrayBufferResize","arrayBufferMethods","previousLength","newContents","maxByteLength","resize","resizeArrayBuffer","resizeArrayBufferSlow","useTextDecoder","stringMethods","finalChunk","checkIpcMaxBuffer","ipcOutput","maxBufferInfo","getMaxBufferSync","stdoutMaxBuffer","getErrorPrefix","originalError","isMaxBuffer","errorCode","signalDescription","isGracefullyCanceled","forcefulSuffix","getForcefulSuffix","streamName","threshold","getMaxBufferInfo","getMaxBufferMessage","serializeMessageItem","messageItem","makeSuccessResult","omitUndefinedProperties","durationMs","isTerminated","pipedFrom","makeEarlyError","isSync","rawExitCode","rawSignal","timeoutDuration","normalizeExitPayload","originalMessage","shortMessage","prefix","escapedOriginalMessage","cwdStat","fixCwdError","getOriginalMessage","ipcMessage","serializeIpcMessage","messagePart","Boolean","serializeMessagePart","createMessages","getFinalError","getErrorProperties","logDuration","prettyMs","logError","logResult","getStdioItemType","isAsyncGenerator","isSyncGenerator","isUrl","isFilePathObject","isWebStream","isNodeStream","isAsyncIterableObject","isIterableObject","isTransformStream","getTransformStreamType","transform","isTransformOptions","getTransformObjectType","getDuplexType","getGeneratorObjectType","validateNonGeneratorType","final","typeName","checkUndefinedOption","checkBooleanOption","isGenerator","isPlainObj","isFilePathString","KNOWN_STDIO_STRINGS","isObject","TRANSFORM_TYPES","FILE_TYPES","SPECIAL_DUPLICATE_TYPES_SYNC","SPECIAL_DUPLICATE_TYPES","FORBID_DUPLICATE_TYPES","TYPE_TO_MESSAGE","asyncGenerator","fileUrl","fileNumber","webStream","nodeStream","webTransform","duplex","native","iterable","getTransformObjectModes","newTransforms","getOutputObjectModes","getInputObjectModes","getTransforms","stdioItems","transforms","stdioItem","normalizeTransform","sortTransforms","normalizeDuplex","normalizeTransformStream","normalizeGenerator","binaryOption","preserveNewlines","KNOWN_DIRECTIONS","anyDirection","alwaysInput","guessStreamDirection","isNodeReadableStream","isNodeWritableStream","standardStreamDirection","getStandardStreamDirection","hasAlias","alias","stdioOption","isOutputPipeOnly","getTargetFd","targetFdNumber","getTargetFdNumber","isatty","standardStreamIndex","getStandardStream","standardStream","handleInputOptions","handleInputOption","handleInputFileOption","getInputType","getInputFileType","getDuplicateStreamInstance","otherStdioItems","duplicateStdioItems","hasSameValue","differentStdioItem","throwOnDuplicateStream","secondValue","handleStdio","addProperties","stdioArray","getStdioArray","normalizeStdioSync","normalizeIpcStdioArray","normalizeStdioOption","initialFileDescriptors","getFileDescriptor","getFinalFileDescriptors","forwardStdio","initialStdioItems","isStdioArray","initializeStdioItems","directions","getStdioItemDirection","getStreamDirection","targetFd","handleNativeStreamSync","handleNativeStreamAsync","handleNativeStream","normalizedStdioItems","normalizeTransforms","lastTransform","getFdObjectMode","validateFileObjectMode","stdioItemOne","indexOne","stdioItemTwo","indexTwo","filterDuplicates","initializeStdioItem","validateStdioArray","validateStreams","INVALID_STDIO_ARRAY_OPTIONS","validateFileStdio","isRegularUrl","isUnknownStdioString","fileStdioItem","getFinalFileDescriptor","cleanupCustomStreams","finalStdioItems","addStreamProperties","duplicateStream","getOtherStdioItems","duplicateStdioItem","validateDuplicateTransform","validateDuplicateStreamSync","getDuplicateStream","forbiddenIfSync","throwInvalidSyncValue","addPropertiesSync","stripNewline","getStripFinalNewline","stripFinalNewlineFunction","getSplitLinesGenerator","skipped","initializeSplitLines","splitLinesSync","splitLinesItemSync","previousChunks","splitGenerator","linesFinal","newlineLength","getNewlineLength","concatString","isWindowsNewline","getAppendNewlineGenerator","appendNewlineGenerator","unixNewline","windowsNewline","concatBytes","linesStringInfo","linesUint8ArrayInfo","newline","firstChunk","secondChunk","getValidateTransformInput","validateStringTransformInput","getValidateTransformReturn","validateObjectTransformReturn","validateStringTransformReturn","validateEmptyReturn","getEncodingTransformGenerator","encodingUint8ArrayGenerator","stringDecoder","encodingStringGenerator","encodingStringFinal","lastChunk","pushChunks","callbackify","getChunks","getChunksArguments","transformStream","currentIterable","transformChunk","generators","identityGenerator","transformedChunk","finalChunks","generatorFinalChunks","destroyTransform","pushChunksSync","getChunksSync","runTransformSync","transformChunkSync","finalChunksSync","generatorFinalChunksSync","generatorToStream","addInternalGenerators","transformAsync","finalAsync","transformMethod","finalMethod","destroyMethod","Transform","getDefaultHighWaterMark","flush","runGeneratorsSync","isInput","reversedGenerators","addInputOptionSync","allStdioItems","transformedContents","applySingleInputGeneratorsSync","validateSerializable","invalidItem","shouldLogOutput","fdUsesVerbose","PIPED_STDIO_VALUES","isPipingStream","_readableState","pipes","logLine","runOutputGeneratorsSync","serializeChunks","serializedResult","decoder","strings","finalString","uint8ArraysToStrings","joinToString","finalResult","logOutputSync","linesArray","logLinesSync","writeToFiles","outputFiles","pathString","waitForSubprocessExit","waitForSuccessfulExit","exitPromise","isSubprocessErrorExit","isFailedExit","getResultError","normalizeSyncOptions","validateSyncOptions","throwInvalidSyncOption","spawnSubprocessSync","syncResult","runSubprocessSync","resultError","isMaxBufferSync","getExitResultSync","truncatedResult","maxBufferValue","truncateMaxBufferSync","uint8ArrayResult","returnedResult","transformOutputResultSync","transformOutputSync","stdioOutput","getAllSync","getSyncResult","getInputFdNumbers","addInputOptionsSync","normalizedOptions","normalizeSpawnSyncOptions","getOneMessage","getOneMessageAsync","getMessage","throwOnStrictError","throwOnEarlyDisconnect","getEachMessage","loopOnMessages","shouldAwait","stopOnDisconnect","abortOnStrictError","iterateOnMessages","throwIfStrictError","getIpcMethods","createDummyStream","PassThrough","Readable","Writable","Duplex","handleDummyPromise","forbiddenIfAsync","fromWeb","addPropertiesAsync","createWriteStream","highWaterMarks","PassThroughStream","ended","onFinished","unpipeEvent","streamPromises","onMergedStreamFinished","streamPromise","endWhenStreamsDone","remove","unpipe","updateMaxListeners","PASSTHROUGH_LISTENERS_COUNT","onMergedStreamEnd","onInputStreamsUnpipe","errorOrAbortStream","unpipedStream","PASSTHROUGH_LISTENERS_PER_STREAM","afterMergedStreamFinished","onInputStreamEnd","onInputStreamUnpipe","abortStream","endStream","isAbortError","errorStream","increment","pipeStreams","onSourceFinish","onDestinationFinish","endDestinationStream","abortSourceStream","pipeTransform","streamProperty","SUBPROCESS_STREAM_PROPERTIES","pipeStdioItem","pipeGroups","setStandardStreamMaxListeners","outputStream","outputStreams","MAX_LISTENERS_INCREMENT","signals$2","processOk","reallyExit","pid","kExitEmitter","ObjectDefineProperty","Emitter","emitted","afterExit","exit","random","ev","list","SignalExitBase","hupSig","emitter","originalProcessEmit","originalProcessReallyExit","sigListeners","loaded","sig","__signal_exit_emitter__","unload","load","alwaysLast","processEmit","processReallyExit","listener","og","getDestination","boundOptions","createNested","firstArgument","pipeArguments","mapDestinationArguments","pipeOptions","createNonCommandError","sourceOptions","PIPE_COMMAND_MESSAGE","waitForBothSubprocesses","subprocessPromises","sourceStatus","sourceReason","sourceResult","destinationStatus","destinationReason","destinationResult","MERGED_STREAMS","unpipeOnAbort","unpipeSignal","unpipeContext","unpipeOnSignalAbort","mergedStream","pipeToSubprocess","sourceInfo","normalizedInfo","sourcePromise","destinationError","getDestinationStream","sourceError","getSourceStream","normalizePipeArguments","handlePipePromise","getSubprocessPromises","getPipeArgumentsError","handlePipeArgumentsError","maxListenersController","pipeMoreSubprocessStream","pipeFirstSubprocessStream","cleanupMergedStreamsMap","pipeSubprocessStream","allSettled","iterateOnSubprocessStream","subprocessStdout","shouldEncode","stopReadingOnExit","iterateOnStream","shouldSplit","iterateForResult","onStreamEnd","allMixed","stopReadingOnStreamEnd","onStdoutChunk","HIGH_WATER_MARK","highWatermark","iterateOnData","DEFAULT_OBJECT_HIGH_WATER_MARK","getGenerators","getStreamOutput","streamInfo","logPromise","logOutputAsync","resumeStream","stripFinalNewlineValue","linesIterable","logLines","readableFlowing","resume","getStreamAsArray","getStreamAsArrayBuffer","handleBufferedData","getMaxBufferUnit","handleMaxBuffer","waitForStream","isSameDirection","stopOnExit","handleStdinDestroy","abortController","stdinCleanedUp","originalStreams","originalStdin","spyOnStdinDestroy","subprocessStdin","_destroy","destroyArguments","setStdinCleanedUp","signalCode","handleStreamError","shouldIgnoreStreamError","propagating","isStreamEpipe","isStreamAbort","isInputFileDescriptor","waitForSubprocessStream","getAllStream","bufferStdout","bufferStderr","getAllMixed","logIpcOutput","getBufferedIpcOutput","ipcOutputPromise","waitForSubprocessResult","spawnPayload","exitPayload","waitForExitOrError","waitForExit","stdioPromises","waitForStdioStreams","waitForAllStream","bufferArray","maxBufferArray","shouldLogIpc","waitForIpcOutput","originalPromises","waitForOriginalStreams","customStreamsEndPromises","waitForCustomStreamsEnd","throwOnSubprocessError","stdioPromise","addConcurrentStream","concurrentStreams","waitName","weakMap","waitForConcurrentStreams","isSubprocessExit","safeWaitForSubprocessStdin","waitForSubprocessStdin","waitForSubprocessStdout","waitForSubprocess","destroyOtherStream","isOpen","createReadable","waitReadableDestroy","getSubprocessStdout","readableEncoding","getReadableOptions","onStdoutDataDone","getReadableMethods","onReadableDestroy","onStdoutFinished","onStdoutData","onRead","destroyOtherReadable","createWritable","waitWritableFinal","waitWritableDestroy","getSubprocessStdin","getWritableMethods","onWritableDestroy","onStdinFinished","onWrite","onWritableFinal","safeWaitForSubprocessStdout","destroyOtherWritable","createDuplex","onDuplexDestroy","createIterable","iterateOnStdoutData","addConvertedStreams","readableDestroy","writableFinal","writableDestroy","nativePromisePrototype","descriptors","property","Reflect","handleAsyncArguments","handleAsyncOptions","handleStdioAsync","spawnSubprocessAsync","extraStdio","createDummyStreams","earlyError","handleEarlyError","inputStreams","pipeOutputAsync","cleanupOnExit","addIpcMethods","handlePromise","errorInfo","stdioResults","stdioResult","getAsyncResult","mergeOption","boundOptionValue","DEEP_OPTIONS","createExeca","mapArguments","deepOptions","setBoundExeca","boundExeca","execaArguments","callBoundExeca","nextArguments","parseArguments","syncOptions","handleStdioSync","handleSyncArguments","execaCoreSync","descriptor","execaCoreAsync","callArguments","parseTemplates","initialFile","initialArguments","mergedOptions","unusedArguments","parseCommandString","trimmedCommand","SPACES_REGEXP","previousToken","mapScriptSync","getScriptOptions","getScriptStdinOption","getIpcExport","posix","promises_1","myGroups","groups","getgroups","win32","peSplit","__exportStar","impl","_ISEXE_TEST_PLATFORM_","isexeSync","rSlash","rRel","optPath","optPathExt","optDelimiter","getPathPart","envPart","withExt","lib","pathEnvPart","previous","applyPreferLocal","execPathString","applyExecPath","copyProperty","ignoreNonConfigurable","toDescriptor","fromDescriptor","canCopyProperty","wrappedToString","withName","fromBody","toStringDescriptor","toStringName","calledFunctions","function_","returnValue","callCount","functionName","displayName","arguments_","ownKeys","fromPrototype","changePrototype","newToString","changeToString","mimicFunction","execaMessage","isError","aliases","assert","module","EE","infinite","equal","signalExitModule","event","emit$1","process$3","signalExit","shouldForceKill","getForceKillAfterTimeout","unref","forceKillAfterTimeout","isSigterm","SIGTERM","isExecaChildProcess","array","setEncoding","pipeline","getStreamModule","sources","it","isEmpty","normalizeArgs","DOUBLE_QUOTES_REGEXP","escapeArg","verboseDefault","date","getTimestamp","normalizeStdio","$","A","systemdrive","opts1","forEach$2","process$2","toPosInteger","toInteger","resolveLength","optsLength","fnLength","isAsync","validCallable","objPropertyIsEnumerable","propertyIsEnumerable","compareFn","defVal","foo","bar","trzy","shim$3","function","captureStackTrace","generate","mixin","arg2","possibleTypes","undefined","isPrototype","classRe","functionToString","contains","searchString","isPlainFunction","normalizeOpts","dModule","dscr","off","__eeOnceListener__","__ee__","resolveArgs","customError","defineLength","ee","resolveResolve","resolvers","configure","memLength","extDel","extGet","extHas","normalizer","getListeners","setListeners","deleteListeners","memoized","userNormalizer","resolveNormalize","profileName","updateEnv","__memoized__","_get","_has","plain","extFn","__profiler__","memoizee","primitive","getPrimitiveFixed","currentLength","lastId","get1","argsMap","getFixed","aFrom","tbi","currentCallback","currentContext","currentArgs","last","origCb","resultArray","maxAge","maxTimeout","validTimeout","timeouts","preFetchAge","preFetchTimeouts","preFetch","lruQueue","limit","hit","oldIndex","nuIndex","refCounter","deleteRef","getRefCount","memoize","is_posix_os","release","windows_version_regex","given_path","major_release","os_build","should_not_escape","regexEscape","matchOperatorsRe","escapeQuotesModule","chars","escapeChar","regex","variants","checkLocale","hasLocale","commonjsRequire","__dirname","requireLocale","isNode","timeUnits","defaultConfig","span","autoloadLocales","firstDate","secondDate","autoload","localeId","require","ensureLocaleLoadedOrThrow","difference","results","divider","getDifference","parts","one","other","months","weeks","narrow","MAX_SAFE_COMPONENT_LENGTH","MAX_SAFE_BUILD_LENGTH","MAX_SAFE_INTEGER","RELEASE_TYPES","SEMVER_SPEC_VERSION","debug_1","LETTERDASHNUMBER","safeRegexReplacements","createToken","isGlobal","safe","makeSafeRegex","NUMERICIDENTIFIER","NUMERICIDENTIFIERLOOSE","NONNUMERICIDENTIFIER","PRERELEASEIDENTIFIER","PRERELEASEIDENTIFIERLOOSE","BUILDIDENTIFIER","MAINVERSION","PRERELEASE","BUILD","FULLPLAIN","MAINVERSIONLOOSE","PRERELEASELOOSE","LOOSEPLAIN","XRANGEIDENTIFIER","XRANGEIDENTIFIERLOOSE","GTLT","XRANGEPLAIN","XRANGEPLAINLOOSE","COERCEPLAIN","COERCE","COERCEFULL","LONETILDE","LONECARET","looseOption","freeze","emptyOpts","parseOptions_1","numeric","compareIdentifiers","anum","bnum","identifiers","rcompareIdentifiers","LOOSE","FULL","num","build","compareMain","comparePre","compareBuild","inc","identifier","identifierBase","parse_1","throwErrors","valid_1","major_1","compare_1","compareBuild_1","versionA","versionB","gt_1","lt_1","eq_1","neq_1","gte_1","lte_1","eq","neq","gte","lt","lte","cmp_1","coerce_1","rtl","coerceRtlRegex","COERCERTLFULL","COERCERTL","lrucache","firstKey","satisfies_1","outside_1","hilo","gtfn","ltefn","ltfn","ecomp","high","low","comparator","outside","minimumVersionWithPreRelease","minimumVersion","simpleSubset","sub","dom","eqSet","gtltComp","higher","lower","hasDomLT","hasDomGT","higherGT","lowerLT","needDomLTPre","needDomGTPre","internalRe","diff","version1","version2","comparison","v1Higher","highVersion","lowVersion","highHasPre","require$$9","require$$13","rcompare","compareLoose","require$$16","rsort","require$$19","require$$20","require$$21","require$$22","require$$23","require$$24","require$$25","coerce","require$$26","require$$27","require$$28","require$$29","toComparators","maxSatisfying","maxSV","rangeObj","minSatisfying","minSV","minVersion","minver","setMin","compver","validRange","require$$35","gtr","ltr","r1","r2","simplifyRange","prev","ranges","simplified","subset","sawNonNull","OUTER","simpleSub","simpleDom","isSub","packageJson","npm_package_json","npm_config_user_agent","isNpm6","isNpm7","isNpm","isYarn","isNpmOrYarn","homeDirectory","configDir","XDG_CONFIG_HOME","getConfigFile","packageName","getDistVersion","distTag","hasNewVersion","pkg","updateCheckInterval","alwaysRun","lastUpdateCheck","latestVersion","mkdirSync","configFile","getLastUpdate","getTime","err_1","isTTY","shouldNotifyInNpmScript","_i","lines_1","padEnd","borderedText","_interopRequireWildcard","_possibleConstructorReturn","ReferenceError","DH_STATES","_typeof","_createClass","_url","_events","IDLE","SKIPPED","STARTED","DOWNLOADING","RETRY","PAUSED","RESUMED","STOPPED","FINISHED","FAILED","_classCallCheck","__proto__","captureRejections","__validate","requestURL","__defaultOpts","override","forceResume","removeOnStop","removeOnFail","progressThrottle","httpRequestOptions","httpsRequestOptions","resumeOnIncomplete","resumeIfFileExists","resumeOnIncompleteMaxRetry","__opts","__pipes","__total","__downloaded","__progress","__retryCount","__retryTimeout","__resumeRetryCount","__states","__promise","__request","__response","__isAborted","__isResumed","__isResumable","__isRedirected","__destFolder","__statsEstimate","time","bytes","prevBytes","throttleTime","__fileName","__filePath","updateOptions","_inherits","__start","getTotalSize","total","__getFilePath","__getFilesizeInBytes","resumeFromFile","__fileStream","__requestAbort","__closeFileStream","__setState","__reqOptions","__emitStop","__headers","__getReqOptions","__initProtocol","progress","speed","__protocol","__isRequireRedirect","location","__getFileNameFromHeaders","__downloadRequest","__onError","__onTimeout","__resetStats","__startDownload","skip","skipSmaller","totalSize","downloadedSize","isResumed","__calculateStats","__onFinished","__hasFinished","incomplete","onDiskSize","__retry","__removeFile","__getFileNameFromOpts","__uniqFileNameSync","prevPath","prevFileName","getStats","throwIfNoEntry","accessSync","F_OK","__resolvePending","toInstall","npath","first2chars","nFileName","nFilepath","O","I","T","W","q","B","tok","makeSafeRe","tb","defaultResult","rangeTmp","sameDirectionIncreasing","sameDirectionDecreasing","sameSemVer","differentDirectionsInclusive","oppositeDirectionsLessThan","oppositeDirectionsGreaterThan","compRe","_readLinuxVersionFile","_getOsVersion","_findMatch","stable","archFilter","platFilter","chk","platform_version","plat","lsbContents","lsbReleaseFile","osReleaseFile","byteToHex","rng","randomBytes","bytesToUuid","buf","offset","__createBinding$1","retryHelper","RetryHelper","maxAttempts","minSeconds","maxSeconds","execute","isRetryable","attempt","core$2","getSleepAmount","sleep","toolCache","findFromManifest","getManifestFromRepo","find_1","cacheFile","cacheDir_1","extractXar","extractTar","extract7z","downloadTool_1","HTTPError","mm","httpm","require$$8","require$$10","rnds","require$$12","retry_helper_1","httpStatusCode","HTTPError_1","IS_MAC","authorization","statusMessage","readStream","responseMessageFactory","succeeded","downloadToolAttempt","_7zPath","originalCwd","powershellPath","extractTar_1","versionOutput","isGnuTar","destArg","fileArg","xarPath","extractZip_1","escapedFile","escapedDest","pwshPath","extractZipWin","unzipPath","extractZipNix","destPath","itemName","sourceFile","targetFile","destFolder","cachePath","getManifestFromRepo_1","owner","branch","releases","treeUrl","manifestUrl","tree","versionsRaw","findFromManifest_1","manifest","dist","previousError","optsArg","optsFs","mkdirAsync","rej","made","statAsync","mkdirpManualSync","parent","fer","mkdirpManual","st","findMade","findMadeSync","mkdirpNativeSync","mkdirpNative","__TESTING_MKDIRP_PLATFORM__","pathArg","badWinChars","versArr","__TESTING_MKDIRP_NODE_VERSION__","hasNative","useNativeSync","useNative","mkdirpSync","mkdirp","nativeSync","manual","manualSync","defaultLLVM","llvm","clang","clangtidy","clangformat","ninja","meson","kcov","task","doxygen","gcc","mingw","gcovr","nala","base_exec_prefix","unique","getUbuntuVersion_1","getUbuntuVersion","child_process_1","exe","execFile","reDistributor","reDescription","reRelease","distributorFound","rel","ss","versionSplitted","pipxHome","compatHome","pipxBinDir","nameMap","macosVersion","macosRelease","AbortError","getDOMException","errorMessage","vsversion_to_versionnumber_1","VSWHERE_PATH","findVcvarsall_1","setupMSVCDevCmd_1","process$1","arch_aliases","win64","vcvars","cmd_output_parts","old_environment","vcvars_output","new_environment","error_messages","old_env_vars","new_value","_1","setupLLVMDeps","dlErr","hasVCPKG","llvmSetups","gccSetups","mingwSetups","msvcSetups","msvc","cl","msbuild","visualstudio","appleClangSetups","appleclang","applellvm","cmakeLangSetups","cmakelang","cmakelint","cmakeformat","nalaPack","nalaLegacyPack","installer","setupNalaViaInstaller","brew","choco","pwsh","vcpkg","addShExt","addShRelativePrefix","bazel","conan","opencppcoverage","OpenCppCoverage","ccache","sccache","activateWinDoxygen","graphviz","cppcheck","activateWinCppcheck","cpplint","flawfinder","lizard","infer","vcvarsall","versionSplit","addVPrefix","installMethod","version_number","removeVPrefix","make","gnuBinDir","sevenzip","tools","checkUpdatePromise","updateNotifier","checkUpdates","ACTIONS_ALLOW_UNSECURE_COMMANDS","idx","alibi","unknown","defaults","mri","inp","parseArgs","help","table","documentation","coverage","architecture","SETUP_CPP_DIR","timeFormatter","timeDelta","time1","time2","timeDeltaLocale","numerousLocale","compilerInfo","compiler","compilerAndVersion","compilerAndMaybeVersion","maybeVersion","getCompilerInfo","toolsGiven","syncCompiler","toolsInUse","toolsNonDefaultVersion","syncVersions","failedFast","time1Compiler","installCompiler","time2Compiler","uniqueEntries","finalizeRC","main","argv"],"mappings":";whBAsCA,SAASA,EAAaC,EAASC,EAAYC,GACvC,MAAMC,EAAM,IAAIC,GAAQJ,EAASC,EAAYC,GAC7CG,QAAQC,OAAOC,MAAMJ,KAAiBK,GAAGC,IAC7C,CCzCO,SAASC,EAAYC,GAClB,MAAAC,EAA+B,WAApBD,EAAOE,SACpB,GAwBD,SAAqBF,GACpB,IAACA,EAAOG,SACD,OAAA,EAGP,GAsCR,SAA2BC,GACjB,MAAAC,EAAYD,EAAKE,cACvB,MAAsB,cAAdD,GACJA,EAAUE,WAAW,SACrBF,EAAUE,WAAW,UACrBF,EAAUE,WAAW,oBAC7B,CA5CQC,CADYR,EAAOG,UAEZ,OAAA,EAEL,MAAAM,EAAUf,QAAQgB,IAAc,UAAKhB,QAAQgB,IAAc,UAAK,GACtE,IAAKD,EACM,OAAA,EAGP,IAAAE,EACAX,EAAOY,KACGD,EAAAE,OAAOb,EAAOY,MAEC,UAApBZ,EAAOE,SACFS,EAAA,GAEe,WAApBX,EAAOE,WACFS,EAAA,KAGd,MAAMG,EAAgB,CAACd,EAAOG,SAASY,eAChB,iBAAZJ,GACPG,EAAcE,KAAK,GAAGF,EAAc,MAAMH,KAG9C,IAAA,MAAWM,KAAoBR,EAC1BS,MAAM,KACNC,KAAIC,GAAKA,EAAEC,OAAON,gBAClBO,QAAOF,GAAKA,IACT,GAAqB,MAArBH,GACAH,EAAcS,MAAKH,GAAKA,IAAMH,GAC1BG,EAAEI,SAAS,IAAIP,IACdA,EAAiBV,W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,OAAOzN,IACNwI,EAAM,oBACNA,EAAMxI,GACN7L,QAAQsU,SAAW,CAAA","x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10,12,13,14,15,16,17,18,19,20,21,22,23,24,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,72,73,74,75,76,80,95,96,97,122,125,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256,257,258,259,260,261,262,263,264,265,266,267,268,269,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,287,288,289,290,291,292,293,294,295,296,297,298,299,300,301,302,303,304,305,306,307,308,309,310,311,312,313,314,315,316,317,318,319,320,321,322,323,324,325,326,327,328,329,330,331,332,333,334,335,336,337,338,339,340,341,342,343,344,345,346,347,348,349,350,351,352,353,354,355,356,357,358,359,360,361,362,363,364,365,366,367,368,369,370,371,372,373,374,375,376,377,378,379,380,381,382,383,384,385,386,387,388,389,390,391,392,393,394,398,400,401,402,403,404,405,406,407,408,409,410,411,412,414,415]}