From 02c04ee6e3231866b475dbbb10b66be10f2e3a9c Mon Sep 17 00:00:00 2001 From: npm CLI robot Date: Thu, 15 May 2025 17:15:03 +0000 Subject: [PATCH] deps: upgrade npm to 11.4.0 --- deps/npm/bin/npm.ps1 | 33 +- deps/npm/bin/npx.ps1 | 33 +- deps/npm/docs/content/commands/npm-adduser.md | 2 + deps/npm/docs/content/commands/npm-audit.md | 6 +- deps/npm/docs/content/commands/npm-ci.md | 6 +- deps/npm/docs/content/commands/npm-dedupe.md | 6 +- deps/npm/docs/content/commands/npm-exec.md | 2 +- .../docs/content/commands/npm-find-dupes.md | 6 +- deps/npm/docs/content/commands/npm-init.md | 14 + .../content/commands/npm-install-ci-test.md | 6 +- .../docs/content/commands/npm-install-test.md | 6 +- deps/npm/docs/content/commands/npm-install.md | 6 +- deps/npm/docs/content/commands/npm-link.md | 6 +- deps/npm/docs/content/commands/npm-login.md | 2 + deps/npm/docs/content/commands/npm-ls.md | 2 +- .../npm/docs/content/commands/npm-outdated.md | 1 + deps/npm/docs/content/commands/npm-pack.md | 6 +- deps/npm/docs/content/commands/npm-prune.md | 6 +- deps/npm/docs/content/commands/npm-rebuild.md | 6 +- deps/npm/docs/content/commands/npm-restart.md | 10 +- .../{npm-run-script.md => npm-run.md} | 20 +- .../docs/content/commands/npm-shrinkwrap.md | 2 +- deps/npm/docs/content/commands/npm-start.md | 10 +- deps/npm/docs/content/commands/npm-stop.md | 8 +- deps/npm/docs/content/commands/npm-test.md | 8 +- deps/npm/docs/content/commands/npm-update.md | 6 +- deps/npm/docs/content/commands/npm-version.md | 2 +- deps/npm/docs/content/commands/npm.md | 2 +- deps/npm/docs/content/commands/npx.md | 2 +- .../content/configuring-npm/package-json.md | 4 +- deps/npm/docs/content/using-npm/config.md | 31 +- deps/npm/docs/content/using-npm/developers.md | 1 - deps/npm/docs/content/using-npm/scripts.md | 7 +- deps/npm/docs/content/using-npm/workspaces.md | 2 +- deps/npm/docs/output/commands/npm-access.html | 6 +- .../npm/docs/output/commands/npm-adduser.html | 7 +- deps/npm/docs/output/commands/npm-audit.html | 12 +- deps/npm/docs/output/commands/npm-bugs.html | 6 +- deps/npm/docs/output/commands/npm-cache.html | 6 +- deps/npm/docs/output/commands/npm-ci.html | 12 +- .../docs/output/commands/npm-completion.html | 6 +- deps/npm/docs/output/commands/npm-config.html | 6 +- deps/npm/docs/output/commands/npm-dedupe.html | 12 +- .../docs/output/commands/npm-deprecate.html | 6 +- deps/npm/docs/output/commands/npm-diff.html | 6 +- .../docs/output/commands/npm-dist-tag.html | 6 +- deps/npm/docs/output/commands/npm-docs.html | 6 +- deps/npm/docs/output/commands/npm-doctor.html | 6 +- deps/npm/docs/output/commands/npm-edit.html | 6 +- deps/npm/docs/output/commands/npm-exec.html | 8 +- .../npm/docs/output/commands/npm-explain.html | 6 +- .../npm/docs/output/commands/npm-explore.html | 6 +- .../docs/output/commands/npm-find-dupes.html | 12 +- deps/npm/docs/output/commands/npm-fund.html | 6 +- .../docs/output/commands/npm-help-search.html | 6 +- deps/npm/docs/output/commands/npm-help.html | 6 +- deps/npm/docs/output/commands/npm-init.html | 17 +- .../output/commands/npm-install-ci-test.html | 12 +- .../output/commands/npm-install-test.html | 12 +- .../npm/docs/output/commands/npm-install.html | 12 +- deps/npm/docs/output/commands/npm-link.html | 12 +- deps/npm/docs/output/commands/npm-login.html | 7 +- deps/npm/docs/output/commands/npm-logout.html | 6 +- deps/npm/docs/output/commands/npm-ls.html | 8 +- deps/npm/docs/output/commands/npm-org.html | 6 +- .../docs/output/commands/npm-outdated.html | 7 +- deps/npm/docs/output/commands/npm-owner.html | 6 +- deps/npm/docs/output/commands/npm-pack.html | 12 +- deps/npm/docs/output/commands/npm-ping.html | 6 +- deps/npm/docs/output/commands/npm-pkg.html | 6 +- deps/npm/docs/output/commands/npm-prefix.html | 6 +- .../npm/docs/output/commands/npm-profile.html | 6 +- deps/npm/docs/output/commands/npm-prune.html | 12 +- .../npm/docs/output/commands/npm-publish.html | 6 +- deps/npm/docs/output/commands/npm-query.html | 6 +- .../npm/docs/output/commands/npm-rebuild.html | 12 +- deps/npm/docs/output/commands/npm-repo.html | 6 +- .../npm/docs/output/commands/npm-restart.html | 16 +- deps/npm/docs/output/commands/npm-root.html | 6 +- .../{npm-run-script.html => npm-run.html} | 28 +- deps/npm/docs/output/commands/npm-sbom.html | 6 +- deps/npm/docs/output/commands/npm-search.html | 6 +- .../docs/output/commands/npm-shrinkwrap.html | 8 +- deps/npm/docs/output/commands/npm-star.html | 6 +- deps/npm/docs/output/commands/npm-stars.html | 6 +- deps/npm/docs/output/commands/npm-start.html | 16 +- deps/npm/docs/output/commands/npm-stop.html | 14 +- deps/npm/docs/output/commands/npm-team.html | 6 +- deps/npm/docs/output/commands/npm-test.html | 14 +- deps/npm/docs/output/commands/npm-token.html | 6 +- .../docs/output/commands/npm-undeprecate.html | 6 +- .../docs/output/commands/npm-uninstall.html | 6 +- .../docs/output/commands/npm-unpublish.html | 6 +- deps/npm/docs/output/commands/npm-unstar.html | 6 +- deps/npm/docs/output/commands/npm-update.html | 12 +- .../npm/docs/output/commands/npm-version.html | 8 +- deps/npm/docs/output/commands/npm-view.html | 6 +- deps/npm/docs/output/commands/npm-whoami.html | 6 +- deps/npm/docs/output/commands/npm.html | 8 +- deps/npm/docs/output/commands/npx.html | 8 +- .../docs/output/configuring-npm/folders.html | 6 +- .../docs/output/configuring-npm/install.html | 6 +- .../output/configuring-npm/npm-global.html | 6 +- .../docs/output/configuring-npm/npm-json.html | 10 +- .../configuring-npm/npm-shrinkwrap-json.html | 6 +- .../docs/output/configuring-npm/npmrc.html | 6 +- .../output/configuring-npm/package-json.html | 10 +- .../configuring-npm/package-lock-json.html | 6 +- deps/npm/docs/output/using-npm/config.html | 32 +- .../using-npm/dependency-selectors.html | 6 +- .../npm/docs/output/using-npm/developers.html | 7 +- deps/npm/docs/output/using-npm/logging.html | 6 +- deps/npm/docs/output/using-npm/orgs.html | 6 +- .../docs/output/using-npm/package-spec.html | 6 +- deps/npm/docs/output/using-npm/registry.html | 6 +- deps/npm/docs/output/using-npm/removal.html | 6 +- deps/npm/docs/output/using-npm/scope.html | 6 +- deps/npm/docs/output/using-npm/scripts.html | 17 +- .../npm/docs/output/using-npm/workspaces.html | 8 +- deps/npm/lib/commands/access.js | 8 +- deps/npm/lib/commands/init.js | 9 +- deps/npm/lib/commands/install.js | 2 +- deps/npm/lib/commands/outdated.js | 14 +- deps/npm/lib/commands/profile.js | 37 +- deps/npm/lib/commands/restart.js | 2 +- .../lib/commands/{run-script.js => run.js} | 4 +- deps/npm/lib/commands/start.js | 2 +- deps/npm/lib/commands/stop.js | 2 +- deps/npm/lib/commands/test.js | 2 +- deps/npm/lib/commands/view.js | 10 +- deps/npm/lib/lifecycle-cmd.js | 4 +- deps/npm/lib/npm.js | 2 +- deps/npm/lib/utils/cmd-list.js | 8 +- deps/npm/lib/utils/reify-output.js | 34 +- deps/npm/man/man1/npm-access.1 | 2 +- deps/npm/man/man1/npm-adduser.1 | 4 +- deps/npm/man/man1/npm-audit.1 | 4 +- deps/npm/man/man1/npm-bugs.1 | 2 +- deps/npm/man/man1/npm-cache.1 | 2 +- deps/npm/man/man1/npm-ci.1 | 4 +- deps/npm/man/man1/npm-completion.1 | 2 +- deps/npm/man/man1/npm-config.1 | 2 +- deps/npm/man/man1/npm-dedupe.1 | 4 +- deps/npm/man/man1/npm-deprecate.1 | 2 +- deps/npm/man/man1/npm-diff.1 | 2 +- deps/npm/man/man1/npm-dist-tag.1 | 2 +- deps/npm/man/man1/npm-docs.1 | 2 +- deps/npm/man/man1/npm-doctor.1 | 2 +- deps/npm/man/man1/npm-edit.1 | 2 +- deps/npm/man/man1/npm-exec.1 | 4 +- deps/npm/man/man1/npm-explain.1 | 2 +- deps/npm/man/man1/npm-explore.1 | 2 +- deps/npm/man/man1/npm-find-dupes.1 | 4 +- deps/npm/man/man1/npm-fund.1 | 2 +- deps/npm/man/man1/npm-help-search.1 | 2 +- deps/npm/man/man1/npm-help.1 | 2 +- deps/npm/man/man1/npm-init.1 | 20 +- deps/npm/man/man1/npm-install-ci-test.1 | 4 +- deps/npm/man/man1/npm-install-test.1 | 4 +- deps/npm/man/man1/npm-install.1 | 4 +- deps/npm/man/man1/npm-link.1 | 4 +- deps/npm/man/man1/npm-login.1 | 4 +- deps/npm/man/man1/npm-logout.1 | 2 +- deps/npm/man/man1/npm-ls.1 | 4 +- deps/npm/man/man1/npm-org.1 | 2 +- deps/npm/man/man1/npm-outdated.1 | 4 +- deps/npm/man/man1/npm-owner.1 | 2 +- deps/npm/man/man1/npm-pack.1 | 4 +- deps/npm/man/man1/npm-ping.1 | 2 +- deps/npm/man/man1/npm-pkg.1 | 2 +- deps/npm/man/man1/npm-prefix.1 | 2 +- deps/npm/man/man1/npm-profile.1 | 2 +- deps/npm/man/man1/npm-prune.1 | 4 +- deps/npm/man/man1/npm-publish.1 | 2 +- deps/npm/man/man1/npm-query.1 | 2 +- deps/npm/man/man1/npm-rebuild.1 | 4 +- deps/npm/man/man1/npm-repo.1 | 2 +- deps/npm/man/man1/npm-restart.1 | 8 +- deps/npm/man/man1/npm-root.1 | 2 +- .../man/man1/{npm-run-script.1 => npm-run.1} | 12 +- deps/npm/man/man1/npm-sbom.1 | 2 +- deps/npm/man/man1/npm-search.1 | 2 +- deps/npm/man/man1/npm-shrinkwrap.1 | 4 +- deps/npm/man/man1/npm-star.1 | 2 +- deps/npm/man/man1/npm-stars.1 | 2 +- deps/npm/man/man1/npm-start.1 | 8 +- deps/npm/man/man1/npm-stop.1 | 6 +- deps/npm/man/man1/npm-team.1 | 2 +- deps/npm/man/man1/npm-test.1 | 6 +- deps/npm/man/man1/npm-token.1 | 2 +- deps/npm/man/man1/npm-undeprecate.1 | 2 +- deps/npm/man/man1/npm-uninstall.1 | 2 +- deps/npm/man/man1/npm-unpublish.1 | 2 +- deps/npm/man/man1/npm-unstar.1 | 2 +- deps/npm/man/man1/npm-update.1 | 4 +- deps/npm/man/man1/npm-version.1 | 4 +- deps/npm/man/man1/npm-view.1 | 2 +- deps/npm/man/man1/npm-whoami.1 | 2 +- deps/npm/man/man1/npm.1 | 4 +- deps/npm/man/man1/npx.1 | 4 +- deps/npm/man/man5/folders.5 | 2 +- deps/npm/man/man5/install.5 | 2 +- deps/npm/man/man5/npm-global.5 | 2 +- deps/npm/man/man5/npm-json.5 | 6 +- deps/npm/man/man5/npm-shrinkwrap-json.5 | 2 +- deps/npm/man/man5/npmrc.5 | 2 +- deps/npm/man/man5/package-json.5 | 6 +- deps/npm/man/man5/package-lock-json.5 | 2 +- deps/npm/man/man7/config.7 | 24 +- deps/npm/man/man7/dependency-selectors.7 | 2 +- deps/npm/man/man7/developers.7 | 4 +- deps/npm/man/man7/logging.7 | 2 +- deps/npm/man/man7/orgs.7 | 2 +- deps/npm/man/man7/package-spec.7 | 2 +- deps/npm/man/man7/registry.7 | 2 +- deps/npm/man/man7/removal.7 | 2 +- deps/npm/man/man7/scope.7 | 2 +- deps/npm/man/man7/scripts.7 | 10 +- deps/npm/man/man7/workspaces.7 | 4 +- .../node_modules/@npmcli/arborist/README.md | 60 +- .../arborist/lib/arborist/load-virtual.js | 12 + .../@npmcli/arborist/lib/arborist/reify.js | 49 +- .../@npmcli/arborist/package.json | 2 +- .../config/lib/definitions/definitions.js | 16 +- .../node_modules/@npmcli/config/package.json | 2 +- .../node_modules/@npmcli/query/package.json | 4 +- .../dist/__generated__/envelope.js | 2 +- .../dist/__generated__/events.js | 2 +- .../google/api/field_behavior.js | 2 +- .../dist/__generated__/google/protobuf/any.js | 2 +- .../google/protobuf/descriptor.js | 2 +- .../google/protobuf/timestamp.js | 2 +- .../dist/__generated__/sigstore_bundle.js | 2 +- .../dist/__generated__/sigstore_common.js | 21 +- .../dist/__generated__/sigstore_rekor.js | 2 +- .../dist/__generated__/sigstore_trustroot.js | 139 +- .../__generated__/sigstore_verification.js | 2 +- .../@sigstore/protobuf-specs/package.json | 2 +- .../node_modules/@sigstore/tuf/package.json | 4 +- .../npm/node_modules/@sigstore/tuf/seeds.json | 2 +- .../@sigstore/verify/dist/key/certificate.js | 18 +- .../@sigstore/verify/dist/key/index.js | 13 +- .../@sigstore/verify/dist/timestamp/tsa.js | 14 +- .../@sigstore/verify/dist/trust/filter.js | 4 +- .../@sigstore/verify/package.json | 4 +- deps/npm/node_modules/abbrev/lib/index.js | 5 +- deps/npm/node_modules/abbrev/package.json | 6 +- .../binary-extensions/binary-extensions.json | 1 + .../binary-extensions/package.json | 2 +- .../node_modules/hosted-git-info/lib/index.js | 48 + .../node_modules/hosted-git-info/package.json | 6 +- .../http-cache-semantics/index.js | 346 ++- .../http-cache-semantics/package.json | 12 +- .../init-package-json/lib/default-input.js | 22 +- .../init-package-json/package.json | 4 +- deps/npm/node_modules/libnpmaccess/README.md | 16 +- .../node_modules/libnpmaccess/package.json | 2 +- deps/npm/node_modules/libnpmdiff/package.json | 4 +- .../node_modules/libnpmexec/lib/run-script.js | 9 + deps/npm/node_modules/libnpmexec/package.json | 4 +- deps/npm/node_modules/libnpmfund/package.json | 4 +- deps/npm/node_modules/libnpmpack/package.json | 4 +- deps/npm/node_modules/libnpmteam/README.md | 34 +- deps/npm/node_modules/libnpmteam/package.json | 2 +- .../libnpmversion/lib/retrieve-tag.js | 2 +- .../node_modules/libnpmversion/package.json | 2 +- .../postcss-selector-parser/API.md | 6 +- .../dist/selectors/container.js | 25 +- .../postcss-selector-parser/package.json | 2 +- deps/npm/node_modules/semver/bin/semver.js | 2 + .../node_modules/semver/classes/comparator.js | 2 + deps/npm/node_modules/semver/classes/index.js | 2 + deps/npm/node_modules/semver/classes/range.js | 2 + .../npm/node_modules/semver/classes/semver.js | 7 +- .../node_modules/semver/functions/clean.js | 2 + deps/npm/node_modules/semver/functions/cmp.js | 2 + .../node_modules/semver/functions/coerce.js | 2 + .../semver/functions/compare-build.js | 2 + .../semver/functions/compare-loose.js | 2 + .../node_modules/semver/functions/compare.js | 2 + .../npm/node_modules/semver/functions/diff.js | 2 + deps/npm/node_modules/semver/functions/eq.js | 2 + deps/npm/node_modules/semver/functions/gt.js | 2 + deps/npm/node_modules/semver/functions/gte.js | 2 + deps/npm/node_modules/semver/functions/inc.js | 2 + deps/npm/node_modules/semver/functions/lt.js | 2 + deps/npm/node_modules/semver/functions/lte.js | 2 + .../node_modules/semver/functions/major.js | 2 + .../node_modules/semver/functions/minor.js | 2 + deps/npm/node_modules/semver/functions/neq.js | 2 + .../node_modules/semver/functions/parse.js | 2 + .../node_modules/semver/functions/patch.js | 2 + .../semver/functions/prerelease.js | 2 + .../node_modules/semver/functions/rcompare.js | 2 + .../node_modules/semver/functions/rsort.js | 2 + .../semver/functions/satisfies.js | 2 + .../npm/node_modules/semver/functions/sort.js | 2 + .../node_modules/semver/functions/valid.js | 2 + deps/npm/node_modules/semver/index.js | 2 + .../node_modules/semver/internal/constants.js | 2 + .../npm/node_modules/semver/internal/debug.js | 2 + .../semver/internal/identifiers.js | 2 + .../node_modules/semver/internal/lrucache.js | 2 + .../semver/internal/parse-options.js | 2 + deps/npm/node_modules/semver/internal/re.js | 12 +- deps/npm/node_modules/semver/package.json | 6 +- deps/npm/node_modules/semver/preload.js | 2 + deps/npm/node_modules/semver/ranges/gtr.js | 2 + .../node_modules/semver/ranges/intersects.js | 2 + deps/npm/node_modules/semver/ranges/ltr.js | 2 + .../semver/ranges/max-satisfying.js | 2 + .../semver/ranges/min-satisfying.js | 2 + .../node_modules/semver/ranges/min-version.js | 2 + .../npm/node_modules/semver/ranges/outside.js | 2 + .../node_modules/semver/ranges/simplify.js | 2 + deps/npm/node_modules/semver/ranges/subset.js | 2 + .../semver/ranges/to-comparators.js | 2 + deps/npm/node_modules/semver/ranges/valid.js | 2 + .../npm/node_modules/tinyglobby/dist/index.js | 4 +- .../node_modules/tinyglobby/dist/index.mjs | 4 +- .../node_modules/fdir/dist/api/walker.js | 5 +- .../node_modules/fdir/dist/builder/index.js | 2 +- .../node_modules/fdir/dist/utils.js | 6 +- .../tinyglobby/node_modules/fdir/package.json | 4 +- deps/npm/node_modules/tinyglobby/package.json | 14 +- deps/npm/package.json | 30 +- .../test/lib/commands/completion.js.test.cjs | 4 +- .../test/lib/commands/config.js.test.cjs | 2 + .../test/lib/commands/outdated.js.test.cjs | 53 +- .../test/lib/commands/publish.js.test.cjs | 2 +- .../test/lib/commands/run.js.test.cjs | 274 ++ .../test/lib/commands/view.js.test.cjs | 16 + .../tap-snapshots/test/lib/docs.js.test.cjs | 57 +- .../tap-snapshots/test/lib/npm.js.test.cjs | 120 +- .../test/lib/utils/reify-output.js.test.cjs | 2572 +++++++++++++++-- deps/npm/test/bin/windows-shims.js | 61 +- deps/npm/test/fixtures/mock-npm.js | 5 +- deps/npm/test/lib/commands/exec.js | 27 +- deps/npm/test/lib/commands/help-search.js | 2 +- deps/npm/test/lib/commands/init.js | 122 + deps/npm/test/lib/commands/install.js | 19 + deps/npm/test/lib/commands/outdated.js | 69 + deps/npm/test/lib/commands/profile.js | 160 +- .../lib/commands/{run-script.js => run.js} | 4 +- deps/npm/test/lib/commands/view.js | 29 + deps/npm/test/lib/lifecycle-cmd.js | 2 +- deps/npm/test/lib/npm.js | 4 +- deps/npm/test/lib/utils/reify-output.js | 28 +- 348 files changed, 4933 insertions(+), 1263 deletions(-) rename deps/npm/docs/content/commands/{npm-run-script.md => npm-run.md} (93%) rename deps/npm/docs/output/commands/{npm-run-script.html => npm-run.html} (93%) rename deps/npm/lib/commands/{run-script.js => run.js} (98%) rename deps/npm/man/man1/{npm-run-script.1 => npm-run.1} (91%) create mode 100644 deps/npm/tap-snapshots/test/lib/commands/run.js.test.cjs rename deps/npm/test/lib/commands/{run-script.js => run.js} (99%) diff --git a/deps/npm/bin/npm.ps1 b/deps/npm/bin/npm.ps1 index 04a1fd478ef9dd..77bc9a5777c80d 100644 --- a/deps/npm/bin/npm.ps1 +++ b/deps/npm/bin/npm.ps1 @@ -22,11 +22,34 @@ if (Test-Path $NPM_PREFIX_NPM_CLI_JS) { $NPM_CLI_JS=$NPM_PREFIX_NPM_CLI_JS } -# Support pipeline input -if ($MyInvocation.ExpectingInput) { - $input | & $NODE_EXE $NPM_CLI_JS $args -} else { - & $NODE_EXE $NPM_CLI_JS $args +if ($MyInvocation.Line) { # used "-Command" argument + if ($MyInvocation.Statement) { + $NPM_ARGS = $MyInvocation.Statement.Substring($MyInvocation.InvocationName.Length).Trim() + } else { + $NPM_OG_COMMAND = ( + [System.Management.Automation.InvocationInfo].GetProperty('ScriptPosition', [System.Reflection.BindingFlags] 'Instance, NonPublic') + ).GetValue($MyInvocation).Text + $NPM_ARGS = $NPM_OG_COMMAND.Substring($MyInvocation.InvocationName.Length).Trim() + } + + $NODE_EXE = $NODE_EXE.Replace("``", "````") + $NPM_CLI_JS = $NPM_CLI_JS.Replace("``", "````") + + # Support pipeline input + if ($MyInvocation.ExpectingInput) { + $input = (@($input) -join "`n").Replace("``", "````") + + Invoke-Expression "Write-Output `"$input`" | & `"$NODE_EXE`" `"$NPM_CLI_JS`" $NPM_ARGS" + } else { + Invoke-Expression "& `"$NODE_EXE`" `"$NPM_CLI_JS`" $NPM_ARGS" + } +} else { # used "-File" argument + # Support pipeline input + if ($MyInvocation.ExpectingInput) { + $input | & $NODE_EXE $NPM_CLI_JS $args + } else { + & $NODE_EXE $NPM_CLI_JS $args + } } exit $LASTEXITCODE diff --git a/deps/npm/bin/npx.ps1 b/deps/npm/bin/npx.ps1 index 28dae51b22ca93..e89536bf3542a0 100644 --- a/deps/npm/bin/npx.ps1 +++ b/deps/npm/bin/npx.ps1 @@ -22,11 +22,34 @@ if (Test-Path $NPM_PREFIX_NPX_CLI_JS) { $NPX_CLI_JS=$NPM_PREFIX_NPX_CLI_JS } -# Support pipeline input -if ($MyInvocation.ExpectingInput) { - $input | & $NODE_EXE $NPX_CLI_JS $args -} else { - & $NODE_EXE $NPX_CLI_JS $args +if ($MyInvocation.Line) { # used "-Command" argument + if ($MyInvocation.Statement) { + $NPX_ARGS = $MyInvocation.Statement.Substring($MyInvocation.InvocationName.Length).Trim() + } else { + $NPX_OG_COMMAND = ( + [System.Management.Automation.InvocationInfo].GetProperty('ScriptPosition', [System.Reflection.BindingFlags] 'Instance, NonPublic') + ).GetValue($MyInvocation).Text + $NPX_ARGS = $NPX_OG_COMMAND.Substring($MyInvocation.InvocationName.Length).Trim() + } + + $NODE_EXE = $NODE_EXE.Replace("``", "````") + $NPX_CLI_JS = $NPX_CLI_JS.Replace("``", "````") + + # Support pipeline input + if ($MyInvocation.ExpectingInput) { + $input = (@($input) -join "`n").Replace("``", "````") + + Invoke-Expression "Write-Output `"$input`" | & `"$NODE_EXE`" `"$NPX_CLI_JS`" $NPX_ARGS" + } else { + Invoke-Expression "& `"$NODE_EXE`" `"$NPX_CLI_JS`" $NPX_ARGS" + } +} else { # used "-File" argument + # Support pipeline input + if ($MyInvocation.ExpectingInput) { + $input | & $NODE_EXE $NPX_CLI_JS $args + } else { + & $NODE_EXE $NPX_CLI_JS $args + } } exit $LASTEXITCODE diff --git a/deps/npm/docs/content/commands/npm-adduser.md b/deps/npm/docs/content/commands/npm-adduser.md index e19b3e3a3f85d9..a42ac6b863915e 100644 --- a/deps/npm/docs/content/commands/npm-adduser.md +++ b/deps/npm/docs/content/commands/npm-adduser.md @@ -20,6 +20,8 @@ Create a new user in the specified registry, and save the credentials to the `.npmrc` file. If no registry is specified, the default registry will be used (see [`registry`](/using-npm/registry)). +When you run `npm adduser`, the CLI automatically generates a legacy token of `publish` type. For more information, see [About legacy tokens](/about-access-tokens#about-legacy-tokens). + When using `legacy` for your `auth-type`, the username, password, and email are read in from prompts. diff --git a/deps/npm/docs/content/commands/npm-audit.md b/deps/npm/docs/content/commands/npm-audit.md index a7e0db7474315a..17af3a686cb456 100644 --- a/deps/npm/docs/content/commands/npm-audit.md +++ b/deps/npm/docs/content/commands/npm-audit.md @@ -402,9 +402,9 @@ but can be useful for debugging. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-ci.md b/deps/npm/docs/content/commands/npm-ci.md index d74922ff7e18bd..e9e00271684181 100644 --- a/deps/npm/docs/content/commands/npm-ci.md +++ b/deps/npm/docs/content/commands/npm-ci.md @@ -190,9 +190,9 @@ but can be useful for debugging. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-dedupe.md b/deps/npm/docs/content/commands/npm-dedupe.md index 1e8a4bc5d0262a..1ff142ec4f806f 100644 --- a/deps/npm/docs/content/commands/npm-dedupe.md +++ b/deps/npm/docs/content/commands/npm-dedupe.md @@ -190,9 +190,9 @@ the order in which omit/include are specified on the command-line. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-exec.md b/deps/npm/docs/content/commands/npm-exec.md index fa8d80cffc9713..7869befcdd1bf4 100644 --- a/deps/npm/docs/content/commands/npm-exec.md +++ b/deps/npm/docs/content/commands/npm-exec.md @@ -355,7 +355,7 @@ project. ### See Also -* [npm run-script](/commands/npm-run-script) +* [npm run](/commands/npm-run) * [npm scripts](/using-npm/scripts) * [npm test](/commands/npm-test) * [npm start](/commands/npm-start) diff --git a/deps/npm/docs/content/commands/npm-find-dupes.md b/deps/npm/docs/content/commands/npm-find-dupes.md index 6710760471824e..bf1a474033cc6d 100644 --- a/deps/npm/docs/content/commands/npm-find-dupes.md +++ b/deps/npm/docs/content/commands/npm-find-dupes.md @@ -130,9 +130,9 @@ the order in which omit/include are specified on the command-line. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-init.md b/deps/npm/docs/content/commands/npm-init.md index bbf0fd8518386f..9e0e6e0f42b913 100644 --- a/deps/npm/docs/content/commands/npm-init.md +++ b/deps/npm/docs/content/commands/npm-init.md @@ -92,6 +92,11 @@ Generate it without having it ask any questions: $ npm init -y ``` +Set the private flag to `true` in package.json: +```bash +$ npm init --init-private -y +``` + ### Workspaces support It's possible to create a new workspace within your project by using the @@ -216,6 +221,15 @@ number, if not already set in package.json. +#### `init-private` + +* Default: false +* Type: Boolean + +The value `npm init` should use by default for the package's private flag. + + + #### `yes` * Default: null diff --git a/deps/npm/docs/content/commands/npm-install-ci-test.md b/deps/npm/docs/content/commands/npm-install-ci-test.md index 1519ffa8e9a8a1..8b2f03e418a839 100644 --- a/deps/npm/docs/content/commands/npm-install-ci-test.md +++ b/deps/npm/docs/content/commands/npm-install-ci-test.md @@ -136,9 +136,9 @@ but can be useful for debugging. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-install-test.md b/deps/npm/docs/content/commands/npm-install-test.md index 3d97af00b262a7..f2696429002b0d 100644 --- a/deps/npm/docs/content/commands/npm-install-test.md +++ b/deps/npm/docs/content/commands/npm-install-test.md @@ -213,9 +213,9 @@ but can be useful for debugging. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-install.md b/deps/npm/docs/content/commands/npm-install.md index ec933394b1a726..5bedfaca078f70 100644 --- a/deps/npm/docs/content/commands/npm-install.md +++ b/deps/npm/docs/content/commands/npm-install.md @@ -601,9 +601,9 @@ but can be useful for debugging. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-link.md b/deps/npm/docs/content/commands/npm-link.md index 34b893e471afa1..b7677f06937bea 100644 --- a/deps/npm/docs/content/commands/npm-link.md +++ b/deps/npm/docs/content/commands/npm-link.md @@ -263,9 +263,9 @@ the order in which omit/include are specified on the command-line. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-login.md b/deps/npm/docs/content/commands/npm-login.md index 531dc71ae3926a..d9499f712cbc87 100644 --- a/deps/npm/docs/content/commands/npm-login.md +++ b/deps/npm/docs/content/commands/npm-login.md @@ -18,6 +18,8 @@ Verify a user in the specified registry, and save the credentials to the `.npmrc` file. If no registry is specified, the default registry will be used (see [`config`](/using-npm/config)). +When you run `npm login`, the CLI automatically generates a legacy token of `publish` type. For more information, see [About legacy tokens](/about-access-tokens#about-legacy-tokens). + When using `legacy` for your `auth-type`, the username and password, are read in from prompts. diff --git a/deps/npm/docs/content/commands/npm-ls.md b/deps/npm/docs/content/commands/npm-ls.md index 4d7c952c061c8c..6ec5fe373b5c6f 100644 --- a/deps/npm/docs/content/commands/npm-ls.md +++ b/deps/npm/docs/content/commands/npm-ls.md @@ -27,7 +27,7 @@ packages will *also* show the paths to the specified packages. For example, running `npm ls promzard` in npm's source tree will show: ```bash -npm@11.3.0 /path/to/npm +npm@11.4.0 /path/to/npm └─┬ init-package-json@0.0.4 └── promzard@0.1.5 ``` diff --git a/deps/npm/docs/content/commands/npm-outdated.md b/deps/npm/docs/content/commands/npm-outdated.md index b1a1c62688e650..857a4c6753fec3 100644 --- a/deps/npm/docs/content/commands/npm-outdated.md +++ b/deps/npm/docs/content/commands/npm-outdated.md @@ -39,6 +39,7 @@ In the output: included in `package.json` are always marked `dependencies`. * `homepage` (when using `--long` / `-l`) is the `homepage` value contained in the package's packument +* `depended by location` (when using `--long` / `-l`) shows location of the package that depends on the displayed dependency * Red means there's a newer version matching your semver requirements, so you should update now. * Yellow indicates that there's a newer version _above_ your semver diff --git a/deps/npm/docs/content/commands/npm-pack.md b/deps/npm/docs/content/commands/npm-pack.md index 2d3e3453d36886..6488180543a20d 100644 --- a/deps/npm/docs/content/commands/npm-pack.md +++ b/deps/npm/docs/content/commands/npm-pack.md @@ -111,9 +111,9 @@ This value is not exported to the environment for child processes. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-prune.md b/deps/npm/docs/content/commands/npm-prune.md index 3a5894cb734a53..0b0922fe8d0980 100644 --- a/deps/npm/docs/content/commands/npm-prune.md +++ b/deps/npm/docs/content/commands/npm-prune.md @@ -120,9 +120,9 @@ but can be useful for debugging. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-rebuild.md b/deps/npm/docs/content/commands/npm-rebuild.md index d22a7a5f9d3e90..ff88f613f415ff 100644 --- a/deps/npm/docs/content/commands/npm-rebuild.md +++ b/deps/npm/docs/content/commands/npm-rebuild.md @@ -93,9 +93,9 @@ but can be useful for debugging. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-restart.md b/deps/npm/docs/content/commands/npm-restart.md index 545315c742fd02..7c0957f2852c13 100644 --- a/deps/npm/docs/content/commands/npm-restart.md +++ b/deps/npm/docs/content/commands/npm-restart.md @@ -12,7 +12,7 @@ npm restart [-- ] ### Description -This restarts a project. It is equivalent to running `npm run-script +This restarts a project. It is equivalent to running `npm run restart`. If the current project has a `"restart"` script specified in @@ -44,9 +44,9 @@ If it does _not_ have a `"restart"` script specified, but it does have If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. @@ -62,7 +62,7 @@ init ` commands. ### See Also -* [npm run-script](/commands/npm-run-script) +* [npm run](/commands/npm-run) * [npm scripts](/using-npm/scripts) * [npm test](/commands/npm-test) * [npm start](/commands/npm-start) diff --git a/deps/npm/docs/content/commands/npm-run-script.md b/deps/npm/docs/content/commands/npm-run.md similarity index 93% rename from deps/npm/docs/content/commands/npm-run-script.md rename to deps/npm/docs/content/commands/npm-run.md index 56fcdb70411da6..90a0c633ff9d8a 100644 --- a/deps/npm/docs/content/commands/npm-run-script.md +++ b/deps/npm/docs/content/commands/npm-run.md @@ -1,5 +1,5 @@ --- -title: npm-run-script +title: npm-run section: 1 description: Run arbitrary package scripts --- @@ -7,9 +7,9 @@ description: Run arbitrary package scripts ### Synopsis ```bash -npm run-script [-- ] +npm run [-- ] -aliases: run, rum, urn +aliases: run-script, rum, urn ``` ### Description @@ -195,10 +195,10 @@ This value is not exported to the environment for child processes. * Default: false * Type: Boolean -If true, npm will not exit with an error code when `run-script` is invoked -for a script that isn't defined in the `scripts` section of `package.json`. -This option can be used when it's desirable to optionally run a script when -it's present and fail if the script fails. This is useful, for example, when +If true, npm will not exit with an error code when `run` is invoked for a +script that isn't defined in the `scripts` section of `package.json`. This +option can be used when it's desirable to optionally run a script when it's +present and fail if the script fails. This is useful, for example, when running scripts that may only apply for some builds in an otherwise generic CI setup. @@ -212,9 +212,9 @@ This value is not exported to the environment for child processes. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-shrinkwrap.md b/deps/npm/docs/content/commands/npm-shrinkwrap.md index 6786229469d2ce..de05c32d9c5c86 100644 --- a/deps/npm/docs/content/commands/npm-shrinkwrap.md +++ b/deps/npm/docs/content/commands/npm-shrinkwrap.md @@ -24,7 +24,7 @@ design and purpose of package locks in npm, see ### See Also * [npm install](/commands/npm-install) -* [npm run-script](/commands/npm-run-script) +* [npm run](/commands/npm-run) * [npm scripts](/using-npm/scripts) * [package.json](/configuring-npm/package-json) * [package-lock.json](/configuring-npm/package-lock-json) diff --git a/deps/npm/docs/content/commands/npm-start.md b/deps/npm/docs/content/commands/npm-start.md index cf9392c605c33f..dc1ab617c66e51 100644 --- a/deps/npm/docs/content/commands/npm-start.md +++ b/deps/npm/docs/content/commands/npm-start.md @@ -23,7 +23,7 @@ the file specified in a package's `"main"` attribute when evoking with `node .` As of [`npm@2.0.0`](https://blog.npmjs.org/post/98131109725/npm-2-0-0), you can -use custom arguments when executing scripts. Refer to [`npm run-script`](/commands/npm-run-script) for more details. +use custom arguments when executing scripts. Refer to [`npm run`](/commands/npm-run) for more details. ### Example @@ -55,9 +55,9 @@ npm start If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. @@ -73,7 +73,7 @@ init ` commands. ### See Also -* [npm run-script](/commands/npm-run-script) +* [npm run](/commands/npm-run) * [npm scripts](/using-npm/scripts) * [npm test](/commands/npm-test) * [npm restart](/commands/npm-restart) diff --git a/deps/npm/docs/content/commands/npm-stop.md b/deps/npm/docs/content/commands/npm-stop.md index 6075b4363c2fa7..ee8974c18a4b09 100644 --- a/deps/npm/docs/content/commands/npm-stop.md +++ b/deps/npm/docs/content/commands/npm-stop.md @@ -48,9 +48,9 @@ npm stop If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. @@ -66,7 +66,7 @@ init ` commands. ### See Also -* [npm run-script](/commands/npm-run-script) +* [npm run](/commands/npm-run) * [npm scripts](/using-npm/scripts) * [npm test](/commands/npm-test) * [npm start](/commands/npm-start) diff --git a/deps/npm/docs/content/commands/npm-test.md b/deps/npm/docs/content/commands/npm-test.md index 72a7822b59fc3c..f72a817f8ede84 100644 --- a/deps/npm/docs/content/commands/npm-test.md +++ b/deps/npm/docs/content/commands/npm-test.md @@ -45,9 +45,9 @@ npm test If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. @@ -63,7 +63,7 @@ init ` commands. ### See Also -* [npm run-script](/commands/npm-run-script) +* [npm run](/commands/npm-run) * [npm scripts](/using-npm/scripts) * [npm start](/commands/npm-start) * [npm restart](/commands/npm-restart) diff --git a/deps/npm/docs/content/commands/npm-update.md b/deps/npm/docs/content/commands/npm-update.md index 25272f8f13ba02..d1775a8955bdb0 100644 --- a/deps/npm/docs/content/commands/npm-update.md +++ b/deps/npm/docs/content/commands/npm-update.md @@ -314,9 +314,9 @@ but can be useful for debugging. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. diff --git a/deps/npm/docs/content/commands/npm-version.md b/deps/npm/docs/content/commands/npm-version.md index bc31b4a12a7324..c543f90d2cf2e9 100644 --- a/deps/npm/docs/content/commands/npm-version.md +++ b/deps/npm/docs/content/commands/npm-version.md @@ -229,7 +229,7 @@ deletes the `build/temp` directory. ### See Also * [npm init](/commands/npm-init) -* [npm run-script](/commands/npm-run-script) +* [npm run](/commands/npm-run) * [npm scripts](/using-npm/scripts) * [package.json](/configuring-npm/package-json) * [config](/using-npm/config) diff --git a/deps/npm/docs/content/commands/npm.md b/deps/npm/docs/content/commands/npm.md index 0b78d4f4e5aabb..2f44e1a4b53a54 100644 --- a/deps/npm/docs/content/commands/npm.md +++ b/deps/npm/docs/content/commands/npm.md @@ -14,7 +14,7 @@ Note: This command is unaware of workspaces. ### Version -11.3.0 +11.4.0 ### Description diff --git a/deps/npm/docs/content/commands/npx.md b/deps/npm/docs/content/commands/npx.md index e596baa5da4793..02a208503d2625 100644 --- a/deps/npm/docs/content/commands/npx.md +++ b/deps/npm/docs/content/commands/npx.md @@ -158,7 +158,7 @@ This resulted in some shifts in its functionality: ### See Also -* [npm run-script](/commands/npm-run-script) +* [npm run](/commands/npm-run) * [npm scripts](/using-npm/scripts) * [npm test](/commands/npm-test) * [npm start](/commands/npm-start) diff --git a/deps/npm/docs/content/configuring-npm/package-json.md b/deps/npm/docs/content/configuring-npm/package-json.md index 418ba7a8e66c64..5dac28fa61b1c0 100644 --- a/deps/npm/docs/content/configuring-npm/package-json.md +++ b/deps/npm/docs/content/configuring-npm/package-json.md @@ -378,7 +378,7 @@ file in the `bin` field, so it is available to run by `name` or `name.cmd` (on Windows PowerShell). When this package is installed as a dependency in another package, the file will be linked where it will be available to that package either directly by `npm exec` or by name in other scripts when invoking them -via `npm run-script`. +via `npm run`. For example, myapp could have this: @@ -951,7 +951,7 @@ resolution. Published packages may dictate their resolutions by pinning dependencies or using an [`npm-shrinkwrap.json`](/configuring-npm/npm-shrinkwrap-json) file. -To make sure the package `foo` is always installed as version `1.0.0` no matter +To make sure the package `@npm/foo` is always installed as version `1.0.0` no matter what version your dependencies rely on: ```json diff --git a/deps/npm/docs/content/using-npm/config.md b/deps/npm/docs/content/using-npm/config.md index 9d089f081825d6..b4307351efeda0 100644 --- a/deps/npm/docs/content/using-npm/config.md +++ b/deps/npm/docs/content/using-npm/config.md @@ -698,10 +698,10 @@ library. * Default: false * Type: Boolean -If true, npm will not exit with an error code when `run-script` is invoked -for a script that isn't defined in the `scripts` section of `package.json`. -This option can be used when it's desirable to optionally run a script when -it's present and fail if the script fails. This is useful, for example, when +If true, npm will not exit with an error code when `run` is invoked for a +script that isn't defined in the `scripts` section of `package.json`. This +option can be used when it's desirable to optionally run a script when it's +present and fail if the script fails. This is useful, for example, when running scripts that may only apply for some builds in an otherwise generic CI setup. @@ -715,9 +715,9 @@ This value is not exported to the environment for child processes. If true, npm does not run scripts specified in package.json files. Note that commands explicitly intended to run a particular script, such as -`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run-script` -will still run their intended script if `ignore-scripts` is set, but they -will *not* run any pre- or post-scripts. +`npm start`, `npm stop`, `npm restart`, `npm test`, and `npm run` will still +run their intended script if `ignore-scripts` is set, but they will *not* +run any pre- or post-scripts. @@ -809,6 +809,15 @@ more information, or [npm init](/commands/npm-init). +#### `init-private` + +* Default: false +* Type: Boolean + +The value `npm init` should use by default for the package's private flag. + + + #### `init-type` * Default: "commonjs" @@ -1355,7 +1364,7 @@ Ignored if `--save-peer` is set, since peerDependencies cannot be bundled. Save installed packages to a package.json file as `devDependencies`. - +This config can not be used with: `save-optional`, `save-peer`, `save-prod` #### `save-exact` @@ -1374,7 +1383,7 @@ rather than using npm's default semver range operator. Save installed packages to a package.json file as `optionalDependencies`. - +This config can not be used with: `save-dev`, `save-peer`, `save-prod` #### `save-peer` @@ -1383,7 +1392,7 @@ Save installed packages to a package.json file as `optionalDependencies`. Save installed packages to a package.json file as `peerDependencies` - +This config can not be used with: `save-dev`, `save-optional`, `save-prod` #### `save-prefix` @@ -1412,7 +1421,7 @@ you want to move it to be a non-optional production dependency. This is the default behavior if `--save` is true, and neither `--save-dev` or `--save-optional` are true. - +This config can not be used with: `save-dev`, `save-optional`, `save-peer` #### `sbom-format` diff --git a/deps/npm/docs/content/using-npm/developers.md b/deps/npm/docs/content/using-npm/developers.md index b97ca038b4a4ba..0d1096203fc36c 100644 --- a/deps/npm/docs/content/using-npm/developers.md +++ b/deps/npm/docs/content/using-npm/developers.md @@ -139,7 +139,6 @@ The following paths and files are never ignored, so adding them to * `package.json` * `README` (and its variants) -* `CHANGELOG` (and its variants) * `LICENSE` / `LICENCE` If, given the structure of your project, you find `.npmignore` to be a diff --git a/deps/npm/docs/content/using-npm/scripts.md b/deps/npm/docs/content/using-npm/scripts.md index 3945c0e75abdc8..5cd2ce7ec7497c 100644 --- a/deps/npm/docs/content/using-npm/scripts.md +++ b/deps/npm/docs/content/using-npm/scripts.md @@ -9,7 +9,7 @@ description: How npm handles the "scripts" field The `"scripts"` property of your `package.json` file supports a number of built-in scripts and their preset life cycle events as well as arbitrary scripts. These all can be executed by running -`npm run-script ` or `npm run ` for short. *Pre* and *post* +`npm run ` or `npm run ` for short. *Pre* and *post* commands with matching names will be run for those as well (e.g. `premyscript`, `myscript`, `postmyscript`). Scripts from dependencies can be run with `npm explore -- npm run `. @@ -46,6 +46,7 @@ situations. These scripts happen in addition to the `pre`, `post`, and `npm pack` * Runs on local `npm install` without any arguments * Runs AFTER `prepublish`, but BEFORE `prepublishOnly` +* Runs for a package if it's being installed as a link through `npm install ` * NOTE: If a package being installed through git contains a `prepare` script, its `dependencies` and `devDependencies` will be installed, and @@ -179,7 +180,7 @@ If there is a `restart` script defined, these events are run, otherwise * `restart` * `postrestart` -#### [`npm run `](/commands/npm-run-script) +#### [`npm run `](/commands/npm-run) * `pre` * `` @@ -357,7 +358,7 @@ file. ### See Also -* [npm run-script](/commands/npm-run-script) +* [npm run](/commands/npm-run) * [package.json](/configuring-npm/package-json) * [npm developers](/using-npm/developers) * [npm install](/commands/npm-install) diff --git a/deps/npm/docs/content/using-npm/workspaces.md b/deps/npm/docs/content/using-npm/workspaces.md index cb545c0b46bf12..34819b801e5fbc 100644 --- a/deps/npm/docs/content/using-npm/workspaces.md +++ b/deps/npm/docs/content/using-npm/workspaces.md @@ -221,6 +221,6 @@ npm run test --workspaces --if-present * [npm install](/commands/npm-install) * [npm publish](/commands/npm-publish) -* [npm run-script](/commands/npm-run-script) +* [npm run](/commands/npm-run) * [config](/using-npm/config) diff --git a/deps/npm/docs/output/commands/npm-access.html b/deps/npm/docs/output/commands/npm-access.html index c31f56b4747b72..879fa129b7f615 100644 --- a/deps/npm/docs/output/commands/npm-access.html +++ b/deps/npm/docs/output/commands/npm-access.html @@ -141,9 +141,9 @@
-

+

npm-access - @11.3.0 + @11.4.0

Set access level on published packages
@@ -256,7 +256,7 @@

See Also